-
Notifications
You must be signed in to change notification settings - Fork 14
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
update in_cluster
for BYOHelper
#1532
Conversation
This isn't ready yet. We need a few
|
name: "leader".to_string(), | ||
api_url: Self::in_cluster_aggregator_api_url(&leader_namespace).to_string(), | ||
dap_url: Self::in_cluster_aggregator_dap_url(&leader_namespace).to_string(), | ||
bearer_token: leader_aggregator_api_auth_token, |
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.
This request needs to go to POST /aggregators
to pair it as a global aggregator and not bound to account
. Also, we need to add is_first_party: true
to the request.
This is still blocked on the listed |
7b86394
to
67ebbde
Compare
Update: all the necessary changes have landed in |
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.
LGTM, just have some comment cleanups.
// From outside the cluster, the aggregators are reached at a dynamically allocated port on | ||
// localhost. When the aggregators talk to each other, they do so in the cluster's network, | ||
// so they need the in-cluster DNS name of the other aggregator, and they can use well-known | ||
// service port numbers. The leader uses its view of its own endpoint URL to construct | ||
// collection job URIs, so we will only patch each aggregator's view of its peer's endpoint. |
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.
Since we no longer directly construct new task request bodies from Task
objects, and instead send in-cluster URLs when setting up each aggregator in divviup-api, the end of this comment isn't applicable anymore.
// From outside the cluster, the aggregators are reached at a dynamically allocated port on | |
// localhost. When the aggregators talk to each other, they do so in the cluster's network, | |
// so they need the in-cluster DNS name of the other aggregator, and they can use well-known | |
// service port numbers. The leader uses its view of its own endpoint URL to construct | |
// collection job URIs, so we will only patch each aggregator's view of its peer's endpoint. | |
// From outside the cluster, the aggregators are reached at a dynamically allocated port on | |
// localhost. When the aggregators talk to each other, they do so in the cluster's network, | |
// so they need the in-cluster DNS name of the other aggregator, and they can use well-known | |
// service port numbers. |
// - pair a global aggregator implictly marks it as "first-party" in divviup-api, which is | ||
// necessary for the task we later provision to pass a validity check. |
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.
nit: typo
// - pair a global aggregator implictly marks it as "first-party" in divviup-api, which is | |
// necessary for the task we later provision to pass a validity check. | |
// - pairing a global aggregator implictly marks it as "first-party" in divviup-api, which | |
// is necessary for the task we later provision to pass a validity check. |
// Update the task with the ID and collector auth token from divviup-api, and aggregator | ||
// endpoints with the in-cluster URLs. |
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.
This is partly outdated, as the endpoints aren't updated here anymore. submit_measurements_and_verify_aggregate()
already overrides the host and port of aggregator endpoints to be 127.0.0.1 and whatever the local forwarded port is.
// Update the task with the ID and collector auth token from divviup-api, and aggregator | |
// endpoints with the in-cluster URLs. | |
// Update the task with the ID and collector auth token from divviup-api. |
a7756cc
to
a867838
Compare
Updates the
in_cluster
test harness code to use the divviup-api API resource for managing aggregators and the automated task provisioning flow (#1486).Resolves #1528