pub struct MapSpec { /* private fields */ }Expand description
A map operation.
use ytsaurus_client::MapSpec;
let spec = MapSpec::new("./cat", ["//tmp/in"], ["//tmp/out"])
.with_local_file("//tmp/cat")
.with_memory_limit(512 * 1024 * 1024);Implementations§
Source§impl MapSpec
impl MapSpec
Sourcepub fn new<I, O>(command: impl Into<String>, inputs: I, outputs: O) -> Self
pub fn new<I, O>(command: impl Into<String>, inputs: I, outputs: O) -> Self
A map running command over inputs, writing outputs.
Sourcepub fn with_local_file(self, path: impl Into<String>) -> Self
pub fn with_local_file(self, path: impl Into<String>) -> Self
Adds a Cypress file the job needs — normally the worker binary.
Sourcepub fn with_memory_limit(self, bytes: i64) -> Self
pub fn with_memory_limit(self, bytes: i64) -> Self
Sets the mapper’s memory limit, in bytes.
Sourcepub fn with_env(self, key: impl Into<String>, value: impl Into<String>) -> Self
pub fn with_env(self, key: impl Into<String>, value: impl Into<String>) -> Self
Sets an environment variable for the job, e.g. RUST_BACKTRACE.
Sourcepub fn with_input_table_index(self) -> Self
pub fn with_input_table_index(self) -> Self
Asks for the input table index to be delivered with each row.
Without this, Row::table_index is always 0.
Sourcepub fn with_job_count(self, count: i64) -> Self
pub fn with_job_count(self, count: i64) -> Self
Requests a specific job count.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for MapSpec
impl RefUnwindSafe for MapSpec
impl Send for MapSpec
impl Sync for MapSpec
impl Unpin for MapSpec
impl UnsafeUnpin for MapSpec
impl UnwindSafe for MapSpec
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more