Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/bnookala/opentracing-sample
https://github.com/bnookala/opentracing-sample
Last synced: about 2 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/bnookala/opentracing-sample
- Owner: bnookala
- Created: 2019-01-28T23:54:45.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2019-01-31T22:37:28.000Z (almost 6 years ago)
- Last Synced: 2024-10-26T00:29:15.758Z (about 2 months ago)
- Language: JavaScript
- Homepage:
- Size: 7.81 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
## OpenTracing Sample
This is a simple node application that produces opentracing traces, consumed by a jaeger instance running in your cluster.
### Deploying the sample
Pre-requisite: a jaeger instance deployed via fabrikate:
1. Download the `fab` tool [here](http://github.com/Microsoft/fabrikate/releases), and place it on your PATH.
2. Clone https://github.com/bnookala/fabrikate-jaeger via git: `git clone https://github.com/bnookala/fabrikate-jaeger`
3. Move into the fabrikate directory: `cd fabrikate-jaeger`
4. Download the fabrikate stack's dependencies: `fab install`
5. Generate the "production" config: `fab generate prod`
6. Apply the production config to your cluster: `kubectl apply -f ./generated/prod/ --recursive`In the opentracing-sample dirctory, run:
```
kubectl apply -f deployment.yaml
```### Testing the sample
Run
```
APP=`kubectl get po -n jaeger --selector=app=ot -o jsonpath='{.items[0].metadata.name}'` && kubectl port-forward $APP 3000:3000 -n jaeger
```In a seperate terminal in the same directory:
Run `./hit_sample.sh`
This will send 10 sample requests to your application at `http://localhost:3000`
You can then stop the `port-forward` process from the first terminal window.
### Verifying traces from the sample application
Run
```
QUERY=`kubectl get po -n jaeger --selector=app=jaeger,component=query -n jaeger -o jsonpath='{.items[0].metadata.name}'` && kubectl port-forward $QUERY 16686:16686 -n jaeger
```Then browse to http://localhost:16686, to interact with the dashboard. If set up properly, you should see traces from the "say-hello" service.