modzyClient.submitJobFile
Submit a job using files as inputs
modzyClient.submitJobFile(String modelId, String versionId, List<InputStream> streamSource)
Submits a job based on an InputStream source. It includes files or any other readable stream.
Parameters
Parameter | Type | Description | Example |
---|---|---|---|
|
| Model identifier provided by Modzy. |
|
|
| The model’s version number. It follows the semantic versioning format. |
|
|
| A list of inputs to process |
|
Returns
com.modzy.sdk.model.Job
object with the job status obtained from the server
Examples
List<InputStream> inputs = new ArrayList<>();
inputs.add( new FileInputStream("/tmp/some-file") );
Job job = modzyClient.submitJobFile("ed542963de", "1.0.1", inputs);
More specific customization options are provided by the method [modzyClient.getJobClient.submitJob
]{doc:javamodzyclientsubmitjob}
JobInput<InputStream> jobInput = new JobInputStream();
Map<String,InputStream> mapSource = new HashMap<>();
mapSource.put("input.txt", new FileInputStream( "/usr/inputs/some_file.txt" ));
jobInput.addSource("my-input", mapSource);
Job job = modzyClient.submitJob("ed542963de", "1.0.1", jobInput, false);
Updated 9 months ago
Did this page help you?