-
Notifications
You must be signed in to change notification settings - Fork 47
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support Service Discovery #74
Support Service Discovery #74
Conversation
This adds a new parameter called service_discovery to the ecs scheduler. Because the type of the serviceRegistries parameter for CreateService API is Array [1], the service_discovery parameter is defined as an array even though currently ECS doesn't allow a service to have more than 1 service registries. [1]: https://docs.aws.amazon.com/AmazonECS/latest/APIReference/API_CreateService.html#ECS-CreateService-request-serviceRegistries
0f04e9c
to
6693fd0
Compare
ECS API allows us to create a service with a service registry in a public DNS namespace, but tasks stop with "The Service Discovery instance could not be registered." error.
120eb13
to
e35b0f1
Compare
e35b0f1
to
45a9623
Compare
namespace_id = service.fetch('namespace_id') | ||
namespace = get_namespace(namespace_id) | ||
if !namespace | ||
raise "Service discovery namespace #{namespace_id} not found" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please raise Hako::Error for generic errors
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
dececdd 🔨
# @param [Hash] expected_service | ||
# @param [Aws::ServiceDiscovery::Types::ServiceSummary] actual_service | ||
# @return [void] | ||
def warn_unallowed_service_change(expected_service, actual_service) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
s/unallowed/disallowed/ ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
119eb7f 🔨
This adds a new parameter called service_discovery to the ecs scheduler.
Because the type of the serviceRegistries parameter for CreateService
API is Array 1, the service_discovery parameter is defined as an array
even though currently ECS doesn't allow a service to have more than 1
service registries.