Skip to content
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

Not able to report span to Zipkin server from node.js application with /api/v1/spans #10

Open
debmalya opened this issue Mar 28, 2018 · 0 comments

Comments

@debmalya
Copy link

debmalya commented Mar 28, 2018

Tried in following two ways, did not work. I am not sure whether there is any error on the way I called it. Still now not able to send span to Zipkin server.

var Zipkin = require('zipkin-simple')
var traceData
  1. with http-simple transport in following way
 var zipkinTracerSimple = new Zipkin({
  debug: true,
  host: "localhost",
  port: "9411",
  path: "/api/v1/spans",
  sampling: 1.0,
  transport: "http-simple"
}) 

 traceData = zipkinTracerSimple.sendServerSend(traceData, {
	'service': 'assign_guest_name'
  }) 

Result:

http-simple.js : http://localhost:9411/api/v1/spans

Server returned an error: 400
<Buffer 43 61 6e 6e 6f 74 20 64 65 63 6f 64 65 20 73 70 61 6e 73>

if converted to string it becomes 'Cannot decode spans'.

  1. with http transport
var zipkinTracerSimple = new Zipkin({
  debug: true,
  host: "localhost",
  port: "9411",
  path: "/api/v1/spans",
  sampling: 1.0,
  transport: "http"
}) 

traceData = zipkinTracerSimple.sendServerSend(traceData, {
	'service': 'assign_guest_name'
 }) 

Result:
http-batch.js : http://localhost:9411/api/v1/spans
Server returned an error: 400
<Buffer 43 61 6e 6e 6f 74 20 64 65 63 6f 64 65 20 73 70 61 6e 73>

Zipkin version I am tried with is zipkin-server-2.5.1-SNAPSHOT-exec.jar

Spans are reported to Zipkin when I changed the parth from ""/api/v1/spans" to ""/api/v2/spans" .
zipkin

@debmalya debmalya changed the title Not able to report span to Zipkin server from node.js application Not able to report span to Zipkin server from node.js application with /api/v1/spans Mar 28, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant