ark::main
Enums
- UploadType
An enumeration of potential artifact types, so we know where to upload these objects.
Typedefs
Defined in “ark/main/main_offboard.hh”:
- using ArgumentsParsedCallback = std::function< void(pipeline::Pipeline &, const core::ArgumentParseResult &)>
A callback function for letting you know that arguments have been parsed, including the result of that parse.
Variables
Defined in “ark/main/catalog.hh”:
- struct ark::main::GeneratedAttachment __attribute__
Classes
-
ark::main::ExecutorInterruptedException
Thrown when a main onboard/offboard task receives a CTRL+C signal. -
ark::main::LogOpenedCallback
A dynamic callback, invoking (at compile time) an appropriate callback based on the callback signature. This allows you to alternatively retrieve a manifest, config package, or a log reader depending on your lambda.Note that if you request a config package and none is available, an empty config package is provided instead.
-
ark::main::GeneratedArtifact
A structure representing an upload-artifact. -
ark::main::GeneratedAttachment
Contains information on a link that needs to be assigned to the catalog. -
ark::main::MainOffboardConfiguration
Configuration for the main functions (the entrance point). -
ark::main::MainOnboardConfiguration
Configuration for the main functions (the entrance point).
Functions
Declared in “ark/main/catalog.hh”:
- void assign_external_attachment(const core::Url & catalog_url, const core::Guid & artifact_id, const std::vector< GeneratedAttachment > & attachments)
Takes the given set of attachments and registers them against the catalog at the given URL, for the specified artifact identifier.
Declared in “ark/main/details_offboard.hh”:
-
core::ArgumentParser get_onboard_argument_parser(const MainOnboardConfiguration & config)
Returns the argument parser that we will use to parse command line arguments within main(), for the onboard stack, based on the configuration. -
core::ArgumentParser get_offboard_argument_parser(const MainOffboardConfiguration & config)
Returns the argument parser that we will use to parse command line arguments within main(), for the offboard stack, based on the configuration. -
logging::LogReaderStageConfiguration get_log_reader_stage_configuration(const MainOffboardConfiguration & config, const std::optional< std::string > & log_url)
Returns a log reader stage configuration that will be attached to the pipeline. -
image::VideoEncodingStageConfig get_video_encoder_stage_configuration(const core::ArgumentParseResult & results)
Given the argument parser results, returns a encoder stage configuration that will be attached to the pipeline. -
image::ThumbnailGenerationStageConfig get_thumbnail_generation_stage_configuration(const core::ArgumentParseResult & results)
Given the argument parser results, returns a thumbnail generator configuration that will be attached to the pipeline. Uses the video output path to generate a filename for the thumbnails. -
void execute_logging_callbacks(pipeline::Pipeline & pipeline, const MainOffboardConfiguration & config, const std::string & log_url)
Invoked against the specified configurations to execute (or not execute) the log opened callbacks.
Declared in “ark/main/dot_output.hh”:
- void emit_standard_dotfile(pipeline::Pipeline && pipeline)
Emits a standard dotfile to standard output, and nothing else. Effectively calls the pipeline code to generate a dotfile. Some channels/stages that main knows about are ignored to improve overall clarity.
Declared in “ark/main/main_offboard.hh”:
-
int execute_realtime_pipeline(int argc, const char ** argv, pipeline::Pipeline && pipeline, const MainOffboardConfiguration & config)
This function wraps common functionality, allowing you to instantiate a standard pipeline-like program from the command line. It provides standard command line interfaces (and argument parsing), along with installing hooks and allowing execution of the pipeline.Returns a value that can be used as the exit code from main(). Zero indicates success, anything else indicates failure.
-
int execute_simclock_pipeline(int argc, const char ** argv, pipeline::Pipeline && pipeline, const MainOffboardConfiguration & config)
This function wraps common functionality, allowing you to instantiate a standard pipeline-like program from the command line. It provides standard command line interfaces (and argument parsing), along with installing hooks and allowing execution of the pipeline.Returns a value that can be used as the exit code from main(). Zero indicates success, anything else indicates failure.
Declared in “ark/main/main_onboard.hh”:
-
int execute_onboard_pipeline(int argc, const char ** argv, pipeline::Pipeline && pipeline, const MainOnboardConfiguration & config)
This function wraps common functionality, allowing you to instantiate a standard pipeline-like program from the command line. It provides standard command line interfaces (and argument parsing), along with installing hooks and allowing execution of the pipeline.Returns a value that can be used as the exit code from main(). Zero indicates success, anything else indicates failure.
Declared in “ark/main/test_initialization.hh”:
-
void test_pipeline_initialization(pipeline::Pipeline && pipeline, const std::function< void(const pipeline::Pipeline &)> & validation_function)
Tests that the given pipeline can be initialized. Throws if there is any error during the initialization process. -
void test_pipeline_connections(pipeline::Pipeline && pipeline)
Tests that the given pipeline has all of its connections established. Throws if there is a connection that is missing.
Declared in “ark/main/upload.hh”:
-
void upload_artifacts_to_bucket(const core::Url & catalog_url, const core::Guid & target_artifact_id, const std::vector< GeneratedArtifact > & artifacts)
Uploads the given paths to the specified bucket. Preserves the filename (copying the filename as-is into the desired location). -
void upload_artifacts_to_bucket(const core::Url & catalog_url, const std::string & catalog_token, const core::Guid & target_artifact_id, const std::vector< GeneratedArtifact > & artifacts)
Uploads the given paths to the specified bucket. Preserves the filename (copying the filename as-is into the desired location). This API is intended for testing, where we need to pass in additional information to use local endpoints.