-
-
Notifications
You must be signed in to change notification settings - Fork 62
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
ref(subscriptions): Decouple subscription logic from datasets [INGEST-627] #2258
ref(subscriptions): Decouple subscription logic from datasets [INGEST-627] #2258
Conversation
Codecov Report
@@ Coverage Diff @@
## cra-metrics/add-metrics-counters-entity-subscription #2258 +/- ##
========================================================================================
- Coverage 93.19% 93.18% -0.01%
========================================================================================
Files 552 552
Lines 25106 25150 +44
========================================================================================
+ Hits 23397 23437 +40
- Misses 1709 1713 +4
Continue to review full report at Codecov.
|
@@ -435,25 +438,49 @@ def handle_subscription_error(exception: InvalidSubscriptionError) -> Response: | |||
) | |||
|
|||
|
|||
@application.route("/<dataset:dataset>/<entity:entity>/subscriptions", methods=["POST"]) | |||
@application.route("/<dataset:dataset>/subscriptions", methods=["POST"]) |
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.
Are you planning to remove this one as a follow up? I think we should
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.
Yep that's the plan, I am planning to remove line 442 and 470 i.e. for creation and deletion as a follow up
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.
Sounds good, it could be useful to mark or comment these in code so it's clear what will happen to the old routes
@application.route( | ||
"/<dataset:dataset>/subscriptions/<int:partition>/<key>", methods=["DELETE"] | ||
) |
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.
Same here, let's deprecate this one once it is no longer being used?
Just some questions about which endpoints we'll be deprecating, otherwise LGTM |
c07e832
to
efab254
Compare
0873d16
to
3dc8290
Compare
efab254
to
26ac38c
Compare
701f26f
to
60a874f
Compare
3fa7c5f
to
fc58934
Compare
60a874f
to
1ca7c85
Compare
…-627] (#2244) * ref(subscriptions): Decouple subscription logic from datasets Decouples subscription creation and deletion logic from datasets to also consider entities since dataset to entity is not a 1-to-1 relation * Add test that ensures selected dataset is actually being used
1ca7c85
to
a01c23c
Compare
Replica of #2244
Re-opening because I accidentally merged it into the main branch