-
Notifications
You must be signed in to change notification settings - Fork 490
http()
: templated url("")
#4663
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
Signed-off-by: Attila Szakacs <attila.szakacs@axoflow.com>
e961adc
to
65e3713
Compare
We've discussed the security implications of this PR privately, I think a few points need to be addressed before merging it. |
Signed-off-by: Attila Szakacs <attila.szakacs@axoflow.com>
c668be7
to
e74033b
Compare
Build FAILURE |
Signed-off-by: Attila Szakacs <attila.szakacs@axoflow.com>
6af92d5
to
44db2eb
Compare
Signed-off-by: Attila Szakacs <attila.szakacs@axoflow.com>
44db2eb
to
059030c
Compare
I'll review this tomorrow! Thanks |
I think this is still missing one step that we discussed with Bazsi: we should parse the beginning of the URL and we should not allow macros coming from message in the schema or the domain part of the URI (not even in escaped form). Note that the SCL use-case of the parameterized URL is different than the runtime unsafe templating feature. We agreed that we don't want to support templated schemas or domains at first, and even if we eventually wanted to do such things, we would mark it as unsafe with a special syntax. Can you explain why "flushing on worker key change" is forced in this PR, please? (I originally thought this functionality depends solely on the needs of the actual destination.) LGTM otherwise |
Signed-off-by: Attila Szakacs <attila.szakacs@axoflow.com>
059030c
to
ea3d7c5
Compare
Regarding the http driver, I think the option is only useful for templated urls, and have no effect otherwise. I wanted to make it easier to set templates in urls, so I set it to yes by default for the http driver.
Done, see |
Build FAILURE |
Signed-off-by: Attila Szakacs <attila.szakacs@axoflow.com>
ea3d7c5
to
7625175
Compare
Build FAILURE |
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.
Thank you very much!
Signed-off-by: Attila Szakacs <attila.szakacs@axoflow.com>
7625175
to
eddb937
Compare
Signed-off-by: Attila Szakacs <attila.szakacs@axoflow.com>
eddb937
to
85ef024
Compare
Build FAILURE |
1 similar comment
Build FAILURE |
This prepares easier transition to templated urls. Signed-off-by: Attila Szakacs <attila.szakacs@axoflow.com>
Currently the http-worker is only using the literal functionality. Implementing support there will be done in the following commits. Signed-off-by: Attila Szakacs <attila.szakacs@axoflow.com>
Signed-off-by: Attila Szakacs <attila.szakacs@axoflow.com>
If we are batching, the first message of the batch will be used for the template evaluation. Signed-off-by: Attila Szakacs <attila.szakacs@axoflow.com>
I believe the only use case of using worker-partition-key() in the http() driver is when we are configuring a templated url(""). In that scenario we should be flushing on worker key change. Signed-off-by: Attila Szakacs <attila.szakacs@axoflow.com>
Signed-off-by: Balazs Scheidler <balazs.scheidler@axoflow.com>
Signed-off-by: Balazs Scheidler <balazs.scheidler@axoflow.com>
Signed-off-by: Attila Szakacs <attila.szakacs@axoflow.com>
Escaping does not have an effect on literal strings, so we can still consider them literals. Signed-off-by: Attila Szakacs <attila.szakacs@axoflow.com>
For safety reasons we do not let the user setting templates to these parts: * scheme * host * port * user * password Signed-off-by: Attila Szakacs <attila.szakacs@axoflow.com>
Signed-off-by: Attila Szakacs <attila.szakacs@axoflow.com>
Signed-off-by: Attila Szakacs <attila.szakacs@axoflow.com>
f24724f
to
526518a
Compare
Signed-off-by: Attila Szakacs <attila.szakacs@axoflow.com>
Signed-off-by: Attila Szakacs <attila.szakacs@axoflow.com>
526518a
to
67f0cd8
Compare
Thanks for the review! I have updated the PR and I hope it works now :/ |
036c105
to
344c541
Compare
Finally, it seems like it works :) 9e5a957 was needed for cmake. |
Build FAILURE |
Signed-off-by: Attila Szakacs <attila.szakacs@axoflow.com>
344c541
to
9e5a957
Compare
Thank you. I'll merge it in 10 minutes, I'll just try it once again :) |
( |
This PR does not implement generating metrics dynamically based on the resolution of the url, but we should do so in the future.
Signed-off-by: Attila Szakacs attila.szakacs@axoflow.com