Use the same operationName for all play requests
This commit is contained in:
parent
d594d6e8db
commit
2d92ed2bed
|
@ -0,0 +1 @@
|
|||
logs/
|
|
@ -58,7 +58,7 @@ class Play26Test extends AgentTestRunner {
|
|||
root.traceId == 123
|
||||
root.parentId == 456
|
||||
root.serviceName == "unnamed-java-app"
|
||||
root.operationName == "/helloplay/:from"
|
||||
root.operationName == "play.request"
|
||||
root.resourceName == "GET /helloplay/:from"
|
||||
!root.context().getErrorFlag()
|
||||
root.context().tags["http.status_code"] == 200
|
||||
|
@ -85,7 +85,7 @@ class Play26Test extends AgentTestRunner {
|
|||
response.code() == 500
|
||||
|
||||
root.serviceName == "unnamed-java-app"
|
||||
root.operationName == "/make-error"
|
||||
root.operationName == "play.request"
|
||||
root.resourceName == "GET /make-error"
|
||||
root.context().getErrorFlag()
|
||||
root.context().tags["http.status_code"] == 500
|
||||
|
@ -116,7 +116,7 @@ class Play26Test extends AgentTestRunner {
|
|||
root.context().tags["error.type"] == RuntimeException.getName()
|
||||
|
||||
root.serviceName == "unnamed-java-app"
|
||||
root.operationName == "/exception"
|
||||
root.operationName == "play.request"
|
||||
root.resourceName == "GET /exception"
|
||||
root.context().tags["http.status_code"] == 500
|
||||
root.context().tags["http.url"] == "/exception"
|
||||
|
|
|
@ -116,7 +116,6 @@ public final class PlayInstrumentation extends Instrumenter.Configurable {
|
|||
if (!pathOption.isEmpty()) {
|
||||
final String path = (String) pathOption.get();
|
||||
scope.span().setTag(Tags.HTTP_URL.getKey(), path);
|
||||
scope.span().setOperationName(path);
|
||||
scope.span().setTag(DDTags.RESOURCE_NAME, req.method() + " " + path);
|
||||
}
|
||||
|
||||
|
|
|
@ -58,7 +58,7 @@ class Play24Test extends AgentTestRunner {
|
|||
root.traceId == 123
|
||||
root.parentId == 456
|
||||
root.serviceName == "unnamed-java-app"
|
||||
root.operationName == "/helloplay/:from"
|
||||
root.operationName == "play.request"
|
||||
root.resourceName == "GET /helloplay/:from"
|
||||
!root.context().getErrorFlag()
|
||||
root.context().tags["http.status_code"] == 200
|
||||
|
@ -85,7 +85,7 @@ class Play24Test extends AgentTestRunner {
|
|||
response.code() == 500
|
||||
|
||||
root.serviceName == "unnamed-java-app"
|
||||
root.operationName == "/make-error"
|
||||
root.operationName == "play.request"
|
||||
root.resourceName == "GET /make-error"
|
||||
root.context().getErrorFlag()
|
||||
root.context().tags["http.status_code"] == 500
|
||||
|
@ -116,7 +116,7 @@ class Play24Test extends AgentTestRunner {
|
|||
root.context().tags["error.type"] == RuntimeException.getName()
|
||||
|
||||
root.serviceName == "unnamed-java-app"
|
||||
root.operationName == "/exception"
|
||||
root.operationName == "play.request"
|
||||
root.resourceName == "GET /exception"
|
||||
root.context().tags["http.status_code"] == 500
|
||||
root.context().tags["http.url"] == "/exception"
|
||||
|
|
Loading…
Reference in New Issue