-
Notifications
You must be signed in to change notification settings - Fork 463
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
Provide tls block for tls options in amqp(), http(), riemann() dest. drivers #1715
Provide tls block for tls options in amqp(), http(), riemann() dest. drivers #1715
Conversation
* Config example: destination d_amqp { amqp( host("127.0.0.1") port(5672) username("test") password("test") tls( ca_file("ca-file") key_file("key-file") ) ); }; Signed-off-by: Andras Mitzki <mitzkia@gmail.com> Signed-off-by: Máté Farkas <mate.farkas@balabit.com>
* Example config destination d_http { http( url("http://127.0.0.1:8080") tls( ca_file("ca-file") key_file("key-file") ) ); }; Signed-off-by: Andras Mitzki <mitzkia@gmail.com>
* Example config destination d_riemann { riemann( server("127.0.0.1") port(5672) tls( ca_file("ca") key_file("key") ) ); }; Signed-off-by: Andras Mitzki <mitzkia@gmail.com>
b8dbbe9
to
2303e15
Compare
Build SUCCESS, the tests were executed on test branch: master and test suite: functions |
1 similar comment
Build SUCCESS, the tests were executed on test branch: master and test suite: functions |
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.
Would it be possible to mark the original configuration options as deprecated in 3.13 ?
Possible a warning during startup.
Thanks, I am ok with the deprecation of original usages. I will create a new patch for that. |
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.
I really like the change, thank you. I've made one note which could make the riemann grammar simpler, but that's not a show-stopper.
modules/riemann/riemann-grammar.ym
Outdated
{ | ||
CHECK_ERROR(riemann_dd_set_connection_type(last_driver, $3), @3, | ||
"Unknown Riemann connection type: %s", $3); | ||
free($3); | ||
} | ||
| KW_TYPE '(' LL_STRING riemann_type_options ')' | ||
| KW_TYPE '(' LL_STRING riemann_tls_options ')' | ||
{ |
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.
btw, there's a rule called "string" that maps either LL_IDENTIFIER or LL_STRING, so the two rules above can be collapsed into a single one.
…STRING Signed-off-by: Andras Mitzki <mitzkia@gmail.com>
Build SUCCESS, the tests were executed on test branch: master and test suite: functions |
@Kokan as I saw we can only add KWS_OBSOLETE flag to directly options (not to "option groups").
With this method I think we can not "mark" the original usage as obsolete. |
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.
It would have been nice to mark groups, but the PR is good regardless of this. Possible in the documentation could be marked as obsolete.
Three destination drivers: amqp(), http(), riemann() allows to use tls options inside the driver configuration.
This patch-set provides to use these tls options also in a general tls() block as it is used in network type drivers.
The patch-set did not brake the original usage for actual drivers.
Example new type of configuration for tls options in riemann destination: