-
Notifications
You must be signed in to change notification settings - Fork 1.2k
JetStream: add accountID param for when an account's name and id differ #6611
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
Conversation
What happens if you specify both, but both with a different value? The JetStream scaler also needs some refactoring (#5797). Is that something you can and want to do? No problem if you can't or don't want to. One advantage of the refactoring is the support for multinames, which I think you want to achieve here. Here is an example of how multinames is applied. |
As implemented, it defers to only use the ID in the filtering, since internally NATs uses the ID (From the slack message screenshot in #6415. We can also see this in NATS source where the name is sometimes the I am not entirely sold that the solution of #6415 is the right approach, since it only modifies how we filter the response from the Which a component of this is as a result of NATs docs using their terms incorrect. In the source for I would be interested in refactoring, but would want to get this fixed first unless refactoring would help in that (since it sounds like the part being refactored is only how the config is initialized). Still not entirely sure on what the fix for this should be. |
What caught my eye was this piece of code:
Which means that if The point about refactoring would mean that someone could specify |
That solution from the refactor sounds like it would be a cleaner fix than what I have now. I'll see what I can do. To clarify the refactor is to have the config parsing done using the declarative struct tags akin to d5d0b10? Then in doing that using a multiname for |
Yeah, it is cleaner. But it might cost you a bit more work to implement your use case (because the refactoring is added). |
Signed-off-by: ohhfishal <ohhfishal@gmail.com>
Signed-off-by: ohhfishal <ohhfishal@gmail.com>
Signed-off-by: ohhfishal <ohhfishal@gmail.com>
Signed-off-by: ohhfishal <ohhfishal@gmail.com>
Signed-off-by: ohhfishal <ohhfishal@gmail.com>
Signed-off-by: ohhfishal <ohhfishal@gmail.com>
Signed-off-by: ohhfishal <ohhfishal@gmail.com>
Signed-off-by: ohhfishal <ohhfishal@gmail.com>
/run-e2e jetstream |
Signed-off-by: Jorge Turrado Ferrero <Jorge_turrado@hotmail.es>
/run-e2e jetstream |
…er (kedacore#6611) * JetStream: add accountID param Signed-off-by: ohhfishal <ohhfishal@gmail.com> * docs: initial changelog Signed-off-by: ohhfishal <ohhfishal@gmail.com> * fix: initial refactor and add ID Signed-off-by: ohhfishal <ohhfishal@gmail.com> * docs: add PR link Signed-off-by: ohhfishal <ohhfishal@gmail.com> * chore: go fmt Signed-off-by: ohhfishal <ohhfishal@gmail.com> * chore: tidy of pre-commit failure Signed-off-by: ohhfishal <ohhfishal@gmail.com> * fix: update tests Signed-off-by: ohhfishal <ohhfishal@gmail.com> * fix: make account and accountID individually optional, but one required Signed-off-by: ohhfishal <ohhfishal@gmail.com> --------- Signed-off-by: ohhfishal <ohhfishal@gmail.com> Signed-off-by: Jorge Turrado Ferrero <Jorge_turrado@hotmail.es> Co-authored-by: Jorge Turrado Ferrero <Jorge_turrado@hotmail.es>
…er (kedacore#6611) * JetStream: add accountID param Signed-off-by: ohhfishal <ohhfishal@gmail.com> * docs: initial changelog Signed-off-by: ohhfishal <ohhfishal@gmail.com> * fix: initial refactor and add ID Signed-off-by: ohhfishal <ohhfishal@gmail.com> * docs: add PR link Signed-off-by: ohhfishal <ohhfishal@gmail.com> * chore: go fmt Signed-off-by: ohhfishal <ohhfishal@gmail.com> * chore: tidy of pre-commit failure Signed-off-by: ohhfishal <ohhfishal@gmail.com> * fix: update tests Signed-off-by: ohhfishal <ohhfishal@gmail.com> * fix: make account and accountID individually optional, but one required Signed-off-by: ohhfishal <ohhfishal@gmail.com> --------- Signed-off-by: ohhfishal <ohhfishal@gmail.com> Signed-off-by: Jorge Turrado Ferrero <Jorge_turrado@hotmail.es> Co-authored-by: Jorge Turrado Ferrero <Jorge_turrado@hotmail.es>
…er (kedacore#6611) * JetStream: add accountID param Signed-off-by: ohhfishal <ohhfishal@gmail.com> * docs: initial changelog Signed-off-by: ohhfishal <ohhfishal@gmail.com> * fix: initial refactor and add ID Signed-off-by: ohhfishal <ohhfishal@gmail.com> * docs: add PR link Signed-off-by: ohhfishal <ohhfishal@gmail.com> * chore: go fmt Signed-off-by: ohhfishal <ohhfishal@gmail.com> * chore: tidy of pre-commit failure Signed-off-by: ohhfishal <ohhfishal@gmail.com> * fix: update tests Signed-off-by: ohhfishal <ohhfishal@gmail.com> * fix: make account and accountID individually optional, but one required Signed-off-by: ohhfishal <ohhfishal@gmail.com> --------- Signed-off-by: ohhfishal <ohhfishal@gmail.com> Signed-off-by: Jorge Turrado Ferrero <Jorge_turrado@hotmail.es> Co-authored-by: Jorge Turrado Ferrero <Jorge_turrado@hotmail.es> Signed-off-by: mittalvaibhav1 <mittalvaibhavandroid@gmail.com>
…er (kedacore#6611) * JetStream: add accountID param Signed-off-by: ohhfishal <ohhfishal@gmail.com> * docs: initial changelog Signed-off-by: ohhfishal <ohhfishal@gmail.com> * fix: initial refactor and add ID Signed-off-by: ohhfishal <ohhfishal@gmail.com> * docs: add PR link Signed-off-by: ohhfishal <ohhfishal@gmail.com> * chore: go fmt Signed-off-by: ohhfishal <ohhfishal@gmail.com> * chore: tidy of pre-commit failure Signed-off-by: ohhfishal <ohhfishal@gmail.com> * fix: update tests Signed-off-by: ohhfishal <ohhfishal@gmail.com> * fix: make account and accountID individually optional, but one required Signed-off-by: ohhfishal <ohhfishal@gmail.com> --------- Signed-off-by: ohhfishal <ohhfishal@gmail.com> Signed-off-by: Jorge Turrado Ferrero <Jorge_turrado@hotmail.es> Co-authored-by: Jorge Turrado Ferrero <Jorge_turrado@hotmail.es>
…er (kedacore#6611) * JetStream: add accountID param Signed-off-by: ohhfishal <ohhfishal@gmail.com> * docs: initial changelog Signed-off-by: ohhfishal <ohhfishal@gmail.com> * fix: initial refactor and add ID Signed-off-by: ohhfishal <ohhfishal@gmail.com> * docs: add PR link Signed-off-by: ohhfishal <ohhfishal@gmail.com> * chore: go fmt Signed-off-by: ohhfishal <ohhfishal@gmail.com> * chore: tidy of pre-commit failure Signed-off-by: ohhfishal <ohhfishal@gmail.com> * fix: update tests Signed-off-by: ohhfishal <ohhfishal@gmail.com> * fix: make account and accountID individually optional, but one required Signed-off-by: ohhfishal <ohhfishal@gmail.com> --------- Signed-off-by: ohhfishal <ohhfishal@gmail.com> Signed-off-by: Jorge Turrado Ferrero <Jorge_turrado@hotmail.es> Co-authored-by: Jorge Turrado Ferrero <Jorge_turrado@hotmail.es>
Running into the same issue mentioned in pull 6415. Handles the case where an account name and id differ in a way that maintains backwards-compatibility since it is a trigger.
Checklist
Fixes #
Relates to #
PR#1551
PR#6415