GCE stackdriver trace http method missing

177 views
Skip to first unread message

Matías Blasi

unread,
Jan 2, 2018, 9:39:46 PM1/2/18
to gce-discussion
Hi all,

I don't see the http method and the analysis report of my traces in the view:





I'm creating the spans in this way:

import "go.opencensus.io/trace/adaptor/stackdriver"

exporter, err := stackdriver.NewExporter(stackdriver.Options{ProjectID: *project})
if err != nil {
	log.Println(err)
} else {
	trace.RegisterExporter(exporter)
}


and later, in the handler:

ctx = trace.StartSpan(ctx, "your choice of name")
defer trace.EndSpan(ctx)


What am I missing?

Regards,
Matía

Dinesh (Google Platform Support)

unread,
Jan 3, 2018, 8:05:18 PM1/3/18
to gce-discussion

Hello Matias,


I need the following information from your side to proceed further:-


  1. Can you please confirm if you were able to submit “create analysis report” successfully? If not, what is the error message you are getting while submitting it?

  2. Can you please retry to submit “create analysis report” via cloud console? You can choose HTTP method and HTTP status from available manu options. Please let me know if you get any error message?


Additionally, you can find more information about creating an analysis report in this document[1].


[1]: https://cloud.google.com/trace/docs/trace-overview

Matías Blasi

unread,
Jan 3, 2018, 10:16:37 PM1/3/18
to gce-discussion
Hi Dinesh, thank you for your reply.

The thing is with the traces list view, not with the analysis report creation. If I try to create a report, it says that I don't have enough requests (100 is the min) to create it.
Anyway, the traces list view, desn't show me the HTTP method of the requests, and I can't filter the requests, for example "GET requests with status 2xx".

Best regards,
Matías.

Dinesh (Google Platform Support)

unread,
Jan 4, 2018, 5:49:57 PM1/4/18
to gce-discussion

You don’t see analysis report from the trace list view because analysis report has not been created yet. As the error message suggests, the user should be having more than 100 requests to create analysis report.  Going forward, I will suggest raising a PIT ticket at google public issue tracker platform[1] for your issue along with bug-related details.


[1]: https://issuetracker.google.com


Matías Blasi

unread,
Jan 4, 2018, 7:50:35 PM1/4/18
to gce-discussion
I understand the issue with the analysis report, my last question is about the "HTTP Method" column, in the same report, that is also empty.

Regards,
Matías.

Dinesh (Google Platform Support)

unread,
Jan 5, 2018, 7:29:29 PM1/5/18
to gce-discussion

The screenshot you shared in your first post is not complete. Can you please share the full screenshot of trace list page? Actually, I am getting different fields in my trace list gui then the shown in cloud documentation and I want to compare those with your screenshot.


Moreover, are you sure that candidate.add URI captured in your trace has standard HTTP request (GET/DELETE/POST/PUT)?Please click any request URI (candidate.add) to view trace details[1].


[1]: https://cloud.google.com/trace/docs/viewing-details


Matías Blasi

unread,
Jan 5, 2018, 9:19:27 PM1/5/18
to gce-discussion
I think we are closer to the issue...

When I click on the candidate.add link I just get it in the timeline below, but I can't go to the 'trace-details' page...

Here is my full screenshot:

Perhaps, it is because the way I am creating the "trace"... candidate.add represents the http handler of a POST request:


r := gin.Default()
r.GET("/_ah/health", Health)
r.POST("/candidate", AddCandidate)
...
server := &http.Server{
  Addr: ":8080",
  Handler: r,
  ReadTimeout: 5 * time.Second,
  WriteTimeout: 10 * time.Second,
}

g.Go(func() error {
  return server.ListenAndServe()
})
....

func AddCandidate(c *gin.Context) {
  ctx := trace.StartSpan(c, "candidate.add")
  defer trace.EndSpan(ctx)
  var candidate Candidate
  ....

I cant figure out why it is not seen as a POST request...

Regards,
Matías.

Dinesh (Google Platform Support)

unread,
Jan 8, 2018, 6:51:07 PM1/8/18
to gce-discussion

Thanks for sharing the complete screen share. I find your trace detail page is bit different and does not have same fields and information regarding HTTP method as suggested in the documentation. I suspect the system is not analyzing your POST request as a standard HTTP request. I will suggest raising this as a customer issue or bug in google public issue tracker platform[1] with complete logs, screenshot and HAR file[2].



[1]: https://issuetracker.google.com

Reply all
Reply to author
Forward
0 new messages