parameters: Arbitrary key-value parameters that you want to include into the body of each SNS notification. This might be useful, if for example, you need to pass in additional metadata for a particular Ray job, such as the job ID.
Example:
# Cloud-provider specific configuration.
provider:
type: aws
...
# If specified, publishes head node cluster setup events to an SNS topic.
# Additional message parameters specified here will be included in every SNS notification.
cluster_notifications:
sns_topic_arn: "arn:aws:sns:us-west-2a:012345678901:01234567-89ab-cdef-0123-456789abcdef"
parameters:
jobId: exampleRayJobId
createdTimestamp: 123456789
...
Related issue number
Checks
[x] I'm working against the latest source on the experimental branch.
[x] I've run scripts/format.sh to lint the changes in this PR.
[ ] I've included any doc changes needed.
[x] I've made sure the tests are passing. Note that there might be a few flaky tests.
Testing Strategy
[ ] Unit tests
[ ] Release tests
[ ] This PR is not tested :(
License
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
Why are these changes needed?
This PR adds a SNS event callback for each Ray cluster setup event. Tested with
ray up
,ray exec
.TODO: need to add unit tests
To configure, the
cluster_notifications
should be added as a field underprovider
(with typeaws
)cluster_notifications
takes the following arguments:sns_topic_arn
: ARN for the Amazon SNS topic.parameters
: Arbitrary key-value parameters that you want to include into the body of each SNS notification. This might be useful, if for example, you need to pass in additional metadata for a particular Ray job, such as the job ID.Example:
Related issue number
Checks
scripts/format.sh
to lint the changes in this PR.License
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.