humanmade / aws-xray

HM Platform AWS X-Ray Integration
23 stars 4 forks source link

Keep socket open throughout request #50

Open rmccue opened 4 years ago

rmccue commented 4 years ago

In send_trace_to_daemon we're constantly opening and closing socket connections to the X-Ray daemon. We would likely be able to gain a bunch of performance by instead opening a connection at the start of the request, and only closing it again at the end of the request.

rmccue commented 4 years ago

@joehoyle can you think of any reason not to do this?

joehoyle commented 4 years ago

Mm yeah I don't think there was any reason for that.