Creating Automation Using Events
Create automation based on state changes for Data Science resources using the Event service types, rules, and actions.
These Data Science resources emit events, and explain how to set up event notifications:
- Project Event Types
- Notebook Session Event Types
- Model Event Types
- Model Deployment Event Types
- Job and Job Run Event Types
- Pipeline and Pipeline Run Event Types
Project Event Types
These are the event types that projects emit:
Friendly Name | Event Type |
---|---|
Create Project |
|
Delete Project Begin |
|
Delete Project End |
|
Update Project |
|
Project Example
This is a reference event for projects:
{
"eventType": "com.oraclecloud.datascience.createproject",
"cloudEventsVersion": "0.1",
"eventTypeVersion": "2.0",
"source": "datascience",
"eventTime": "2019-11-22T01:43:35.246Z",
"eventID": "<unique_ID>
",
"contentType": "application/json",
"data": {
"compartmentId": "ocid1.compartment.oc1..<unique_ID>
",
"compartmentName": "example_compartment",
"resourceName": "example_project",
"resourceId": "ocid1.datascienceproject.oc1.iad.<unique_ID>
",
"availabilityDomain": "<availability_domain>
",
"freeFormTags": {
"Department": "Finance"
},
"definedTags": {
"Operations": {
"CostCenter": "42"
}
}
},
"extensions": {
"compartmentId": "ocid1.compartment.oc1..<unique_ID>
"
}
}
Notebook Session Event Types
These are the event types that notebook sessions emit:
Friendly Name | Event Type |
---|---|
Activate Notebook Session Begin |
|
Activate Notebook Session End |
|
Create Notebook Session Begin |
|
Create Notebook Session End |
|
Deactivate Notebook Session Begin |
|
Deactivate Notebook Session End |
|
Delete Notebook Session Begin |
|
Delete Notebook Session End |
|
Update Notebook Session |
|
Notebook Session Example
This is a reference event for notebook sessions:
{
"eventType": "com.oraclecloud.datascience.updatenotebooksession",
"cloudEventsVersion": "0.1",
"eventTypeVersion": "2.0",
"source": "datascience",
"eventTime": "2019-11-22T01:43:35.246Z",
"eventID": "<unique_ID>
",
"contentType": "application/json",
"data": {
"compartmentId": "ocid1.compartment.oc1..<unique_ID>
",
"compartmentName": "example_compartment",
"resourceName": "example_notebook_session",
"resourceId": "ocid1.datasciencenotebooksession.oc1.iad.<unique_ID>
",
"availabilityDomain": "<availability_domain>
",
"freeFormTags": {
"Department": "Finance"
},
"definedTags": {
"Operations": {
"CostCenter": "42"
}
}
},
"extensions": {
"compartmentId": "ocid1.compartment.oc1..<unique_ID>
"
}
}
Model Event Types
These are the event types that models emit:
Friendly Name | Event Type |
---|---|
Activate Model |
|
Create Model |
|
Deactivate Model |
|
Delete Model |
|
Update Model |
|
Model Example
This is a reference event for models:
{
"eventType": "com.oraclecloud.datascience.deletemodel",
"cloudEventsVersion": "0.1",
"eventTypeVersion": "2.0",
"source": "datascience",
"eventTime": "2019-11-22T01:43:35.246Z",
"eventID": "<unique_ID>
",
"contentType": "application/json",
"data": {
"compartmentId": "ocid1.compartment.oc1..<unique_ID>
",
"compartmentName": "example_compartment",
"resourceName": "example_model",
"resourceId": "ocid1.datasciencemodel.oc1.iad.<unique_ID>
",
"availabilityDomain": "<availability_domain>
",
"freeFormTags": {
"Department": "Finance"
},
"definedTags": {
"Operations": {
"CostCenter": "42"
}
}
},
"extensions": {
"compartmentId": "ocid1.compartment.oc1..<unique_ID>
"
}
}
Model Deployment Event Types
These are the event types that model deployments emit:
Friendly Name | Event Type |
---|---|
Activate Model Deployment |
|
Create Model Deployment |
|
Deactivate Model Deployment |
|
Delete Model Deployment |
|
Update Model Deployment |
|
Model Deployment Example
This is a reference event for model deployments:
"exampleEvent": {
"eventType": "com.oraclecloud.datascience.createmodeldeployment.begin",
"cloudEventsVersion": "0.1",
"eventTypeVersion": "2.0",
"source": "datascience",
"eventTime": "2021-03-03T01:43:35.246Z",
"eventID": "unique_ID",
"contentType": "application/json",
"data": {
"compartmentId": "ocid1.compartment.oc1..unique_ID",
"compartmentName": "example_compartment",
"resourceName": "example_model_deployment",
"resourceId": "ocid1.datasciencemodeldeployment.oc1.iad.unique_ID",
"availabilityDomain": "availability_domain",
"freeFormTags": {
"Department": "Finance"
},
"definedTags": {
"Operations": {
"CostCenter": "42"
}
}
},
Job and Job Run Event Types
These are the event types that job and job runs emit:
Friendly Name | Event Type |
---|---|
Job — Create |
|
Job — Delete begin |
|
Job — Delete end |
|
Job — Update |
|
Job Run — Cancel begin |
|
Job Run — Cancel end |
|
Job Run — Create begin |
|
Job Run — Create end |
|
Job Run — Delete |
|
Job Run — Failed |
|
Job Run — Succeeded |
|
Job Run — Timeout |
|
Job Run — Update |
|
Pipeline and Pipeline Run Event Types
These are the event types that pipeline and pipeline runs emit:
Friendly Name | Event Type |
---|---|
Pipeline - Create |
|
Pipeline - Delete begin |
|
Pipeline - Delete end |
|
Pipeline - Update |
|
Pipeline Run - Cancel begin |
|
Pipeline Run - Cancel end |
|
Pipeline Run - Create begin |
|
Pipeline Run - Create end |
|
Pipeline Run - Delete |
|
Pipeline Run - Failed |
|
Pipeline Run - Succeeded |
|
Pipeline Run - Timeout |
|
Pipeline Run - Update |
|
References for Using the Events Service
You can define rules that trigger a specific action when an event occurs. For example, you can set up the Notifications service to send you a Slack message when an artifact uploads to a specific repository.
For more information, see: