-
Notifications
You must be signed in to change notification settings - Fork 81
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
Supports OpenSearch V2 through ES_* environment variables #229
Conversation
Signed-off-by: Andriy Redko <[email protected]>
hmm having to maintain both OS_ and ES_ seems either confusing (here and not the server) or maintenance causing (to have to do both). Is there no way we can heuristically check if the server is OS or not? e.g. via a rest call to the version endpoint? |
I think we could but we need 2 set of dependencie (spark_elasticsearch and spark_opensearch) which are sadly conflicting :(( |
I mean technically this is annoying yes but we dont necessarily need to pass this problem further. In the main function detect which of the two drivers to use. opensearch was supposed to be a small amount of effort esp with so few maintainers. it is becoming quite large. we need to reduce what we can as there havent been a large amount of requests for it. |
Oh I see, we could yeah, following the same approach with / endpoint checking , will try to figure out how we could plug it into the zipkin-dependencies without copy / pasting code. |
thanks, yep. we had to do something similar when ES changed the index formatting (speculatively try both) |
…he right job instance Signed-off-by: Andriy Redko <[email protected]>
import org.slf4j.Logger; | ||
import org.slf4j.LoggerFactory; | ||
|
||
final class ZipkinElasticsearchStorage { |
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.
@codefromthecrypt what do you think about this way of OS/ES storage detection? (tests are on me, just haven't had time to finish them)
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 exactly as I was hoping!
# It extends the default configuration from docker-compose.yml to run the | ||
# zipkin-opensearch2 container instead of the zipkin-mysql container. | ||
|
||
version: '2.4' |
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.
note: probably want to update the README so people can see this is there, also
Signed-off-by: Andriy Redko <[email protected]>
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.
good work
.password("bar") | ||
.hosts(es.url("").toString()); | ||
|
||
// temporarily hack-in self-signed until https://github.com/openzipkin/zipkin/issues/1683 |
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.
👌
opensearch/src/test/java/zipkin2/storage/elasticsearch/OpensearchContainer.java
Outdated
Show resolved
Hide resolved
import org.slf4j.Logger; | ||
import org.slf4j.LoggerFactory; | ||
|
||
final class ZipkinElasticsearchStorage { |
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 exactly as I was hoping!
Signed-off-by: Andriy Redko <[email protected]>
opensearch/src/test/java/zipkin2/storage/elasticsearch/OpensearchContainer.java
Outdated
Show resolved
Hide resolved
Signed-off-by: Andriy Redko <[email protected]>
I will follow-up with a version bump PR. thanks, @reta! |
$ git push origin release-3.2.0 |
Add Zipkin Dependencies support of for OpenSearch storage (see please openzipkin/zipkin#3765). Tested with Zipkin 3.4.0-SNAPSHOT locally: