How can I display the data from this icon outside? I want the data for this icon to show up on the right side of the function list, specifically in the service section. I have added a tab called "CustomerPage" there, and I really need the data to be displayed. Please help me. #10860
Closed
AllenArbiter
started this conversation in
General
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Phenomenon:
Question: How can I display the data from this icon outside? I want the data for this icon to show up on the right side of the function list, specifically in the service section. I have added a tab called "CustomerPage" there, and I really need the data to be displayed. Please help me. I have made efforts to learn OAL, but I still can't make the necessary changes. I have noticed that it now uses the following OAL syntax:I have customized a logical endpoint, and it appears correctly as shown below:
scss
Copy code
endpoint_cpm = from(Endpoint.*).cpm();
How can I modify this OAL? For example, if I have an endpoint serving "customFormPage" in the service "aws::aws64GA," please provide an example.
Service_aws_form_resp_time = from(How to specify?).filter(Specified endpoint).cpm()
The following code may be helpful for troubleshooting the problem:
This is the code for custom logical endpoints:
java
Copy code
public void beforeMethod(EnhancedInstance enhancedInstance, Method method, Object[] allArguments, Class<?>[] classes, MethodInterceptResult methodInterceptResult) throws Throwable {
Object params = allArguments[0];
}
public Object afterMethod(EnhancedInstance enhancedInstance, Method method, Object[] objects, Class<?>[] classes, Object ret) throws Throwable {
String retString = (String) ret;
AbstractSpan span = ContextManager.activeSpan();
// Tags.STATUS_CODE.set(span, "20000");
ContextManager.stopSpan();
Counter counter = MeterFactory.counter("my_meter_name").tag("tagKey", "tagValue").mode(CounterMode.INCREMENT).build();
int random = (int) (Math.random() * 100 + 1);
counter.increment(random);
return retString;
}
public void handleMethodException(EnhancedInstance enhancedInstance, Method method, Object[] objects, Class<?>[] classes, Throwable throwable) {
AbstractSpan activeSpan = ContextManager.activeSpan();
activeSpan.errorOccurred();
activeSpan.errorOccurred();
}
Beta Was this translation helpful? Give feedback.
All reactions