|
C++ YT Wrapper
C++ library for working with YT clusters
|
Interface representing an operation. More...
#include <operation.h>
Public Member Functions | |
| virtual const TOperationId & | GetId () const =0 |
| Get operation id. | |
| virtual TString | GetWebInterfaceUrl () const =0 |
| Get URL of the operation in YT Web UI. | |
| virtual TString | GetStatus () const =0 |
| Get last error for not started operations. Get state on YT cluster for started operations. | |
| virtual ::NThreading::TFuture< void > | GetPreparedFuture ()=0 |
| Get preparation future. | |
| virtual void | Start ()=0 |
| Start operation synchronously. | |
| virtual bool | IsStarted () const =0 |
| Is the operation started. | |
| virtual ::NThreading::TFuture< void > | GetStartedFuture ()=0 |
| Get start future. | |
| virtual ::NThreading::TFuture< void > | Watch ()=0 |
| Start watching operation. | |
| virtual TVector< TFailedJobInfo > | GetFailedJobInfo (const TGetFailedJobInfoOptions &options=TGetFailedJobInfoOptions())=0 |
| Get information about failed jobs. | |
| virtual EOperationBriefState | GetBriefState ()=0 |
| Get operation brief state. | |
| virtual TMaybe< TYtError > | GetError ()=0 |
| Get error (if operation has failed). | |
| virtual TJobStatistics | GetJobStatistics ()=0 |
| Get job statistics. | |
| virtual TMaybe< TOperationBriefProgress > | GetBriefProgress ()=0 |
| virtual TMaybe< THashMap< TString, TYtError > > | GetAlerts ()=0 |
| Get operation alerts. | |
| virtual void | AbortOperation ()=0 |
| Abort operation. | |
| virtual void | CompleteOperation ()=0 |
| Complete operation. | |
| virtual void | SuspendOperation (const TSuspendOperationOptions &options=TSuspendOperationOptions())=0 |
| Suspend operation. | |
| virtual void | ResumeOperation (const TResumeOperationOptions &options=TResumeOperationOptions())=0 |
| Resume previously suspended operation. | |
| virtual TOperationAttributes | GetAttributes (const TGetOperationOptions &options=TGetOperationOptions())=0 |
| Get operation attributes. | |
| virtual void | UpdateParameters (const TUpdateOperationParametersOptions &options=TUpdateOperationParametersOptions())=0 |
| Update operation runtime parameters. | |
| virtual TJobAttributes | GetJob (const TJobId &jobId, const TGetJobOptions &options=TGetJobOptions())=0 |
| Get job attributes. | |
| virtual TListJobsResult | ListJobs (const TListJobsOptions &options=TListJobsOptions())=0 |
Interface representing an operation.
|
pure virtual |
Abort operation.
Operation will be finished immediately. All results of completed/running jobs will be lost.
|
pure virtual |
Complete operation.
Operation will be finished immediately. All results of completed jobs will appear in output tables. All results of running (not completed) jobs will be lost.
|
pure virtual |
Get operation attributes.
|
pure virtual |
Get operation progress.
|
pure virtual |
Get error (if operation has failed).
|
pure virtual |
Get information about failed jobs.
Can be called for operation in any stage. Though user should keep in mind that this method always fetches info from cypress and doesn't work when operation is archived. Successfully completed operations can be archived quite quickly (in about ~30 seconds).
|
pure virtual |
Get job attributes.
|
pure virtual |
Get preparation future.
|
pure virtual |
Get start future.
|
pure virtual |
Get last error for not started operations. Get state on YT cluster for started operations.
For not started operations last error is an error that's being retried during operation preparation/start (e.g. lock files, start operation request).
|
pure virtual |
Is the operation started.
Returns true if the operation is started on the cluster
|
pure virtual |
List jobs satisfying given filters (see NYT::TListJobsOptions).
|
pure virtual |
Resume previously suspended operation.
|
pure virtual |
Start operation synchronously.
If operation is not prepared yet, Start() will block waiting for preparation finish. Be ready to catch exception if operation preparation or start failed.
|
pure virtual |
Suspend operation.
Jobs will not be aborted by default, c.f. NYT::TSuspendOperationOptions.
|
pure virtual |
Update operation runtime parameters.
|
pure virtual |
Start watching operation.
If operation is completed successfully the returned future contains void value. If operation is completed with error future contains NYT::TOperationFailedError. In rare cases when error occurred while waiting (e.g. YT become unavailable) future might contain other exception.