Document how to make a custom standalone collector
See original GitHub issueThis involves some spring magic and isn’t particularly obvious on how to do it. I did it earlier today, but I’ll have to look at it tomorrow to remember what exactly is needed. Here’s what I remember so far:
POM modifications:
- Lots of copy/paste from zipkin-server POM
- Need to add the correct zipkin autoconfigure dependencies to your POM (so for example, if you’re writing to cassandra, add zipkin-autoconfigure-storage-cassandra… or just add all of them)
- Add spring boot configuration parser to POM
- Add sprint boot starter to POM
Creating the collector:
- Lots of copy/paste from the kafka collector
- Two pieces: configuration and stream collector, it’s fairly straightforward copy/pasting
- Need to add a spring autoconfigure thing to your resources
Creating a main function to run:
- Create a main class, see the main zipkin-server class
- This class should have the sampler
@Bean
in it
- This class should have the sampler
- If you want to use environment variables to configure the app like everything else in zipkin, then you need to copy/paste a bunch of stuff from zipkin-server.yml, and add that to your own app’s resources
Finally, make sure that you don’t mess up the annotation compilation, otherwise you’ll get really weird errors and it won’t work.
At some point, it might be useful to make a sample project with all of these.
Execution is however one would normally execute a spring boot application.
Issue Analytics
- State:
- Created 7 years ago
- Comments:9 (1 by maintainers)
Top Results From Across the Web
How to Edit and Create Standalone Custom Followers - AIO ...
A comprehensive guide to get started on making standalone followers (with images ... How to create standalone followers (Google Docs link):
Read more >Getting Started | OpenTelemetry
Pull a docker image and run the collector in a container. Replace 0.67.0 with the version of the Collector you wish to run....
Read more >Networking with standalone containers - Docker Documentation
Use user-defined bridge networks shows how to create and use your own custom bridge networks, to connect containers running on the same Docker...
Read more >Cloud Firestore Data model - Firebase
The names of documents within a collection are unique. You can provide your own keys, such as user IDs, or you can let...
Read more >Overview of sites and site collections in SharePoint Server
The host-named site collections allow you to assign custom names to each site collection that you create in a web application.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
copied from #1488
Update: figured out how to get modularity working. It is a little constrained, but it works now.
Here’s how.
Step 1: Add spring boot plugin to your autoconfig module, adding a “module” jar
The classifier name “module” is arbitrary, but I think it works. Take extreme care to not duplicate jars already in zipkin-server’s exec jar. Here’s an example configuration for the SQS collector:
This will make a file like…
autoconfigure/collector-sqs/target/zipkin-autoconfigure-collector-sqs-0.0.4-SNAPSHOT-module.jar
Step 2: Extract this module jar when composing a server layer
I cannot get the PropertiesLauncher configuration to accept the module-jar directly. However, the following does work.
PropertiesLauncher
withloader.path
set to include that directoryExample:
Note: the module jar is self-contained… when doing your devopsian things, feel free to just curl it from jcenter, like we do for the server jar.
this works fine now. both in aws and azure. we just need to polish instructions