Hi Anjana, No. Like you said we only set in the transport header. That transport header is set to the message context.
Regards, Gihan On Fri, Nov 29, 2013 at 8:37 AM, Anjana Fernando <[email protected]> wrote: > Hi Dinuha, > > Yeah, we can modify the message tracer to give options saying, publish to > BAM and/or log it, or not do anything at all, where it will just set the > activity id in a message context property. @Gihan, do we already set the > activity id as a separate message context property? .. And also, even at > the moment, from the message context, we can get the transport header and > read in the value. But having a dedicated message context property would be > good in the long run, when we need to support multiple transports, and we > will need a generic way to extract the activity id. > > Cheers, > Anjana. > > > On Thu, Nov 28, 2013 at 10:26 PM, Dinusha Senanayaka <[email protected]>wrote: > >> Hi BAM Team, >> >> Currently this handler [1] has written in a way that it always publishes >> events to BAM server. But for API-Manager, we need to have an option that >> this could be used without having a BAM server and activity_id can be used >> to co-relate the messages by reading the logs. >> >> We could easily change the logic in this handler to have an option of >> logging the details, if we don't need to publish events to a BAM server. >> Instead of log these details from the handler, is it possible us to add >> this activity_id into something like message context, so that we could use >> it later to log with the other details from gateway and key-manager servers >> ? >> >> We need to add this activity_Id into the logs print by gateway and >> key-manager servers as shown below, instead of adding it in a separate log >> line. >> >> [2013-11-28 22:18:21,038] DEBUG - APIManagerExtensionHandler Inbound API >> call from client to gateway: belonging to appName=DefaultApplication from >> userName=admin *activityId=xxx* with userAgent=curl/7.19.7 >> (x86_64-pc-linux-gnu) libcurl/7.19.7 OpenSSL/0.9.8k zlib/1.2.3.3libidn/1.15 >> for requestURI=/rdbms/1.0.0/customersInBoston at >> requestTime=Thu Nov 28 22:18:15 IST 2013 from clientIP=10.216.236.141 >> >> [2013-11-28 22:18:21,380] DEBUG - APIManagerExtensionHandler Outbound API >> call from gateway to client: belonging to appName=DefaultApplication from >> userName=admin *activityId=xxx* for >> requestURI=/rdbms/1.0.0/customersInBoston at requestTime=Thu Nov 28 >> 22:18:21 IST 2013 EndPointURL=null >> >> >> [1]. >> https://svn.wso2.org/repos/wso2/carbon/platform/branches/turing/components/data-agents/org.wso2.carbon.bam.message.tracer.handler/4.2.0/src/main/java/org/wso2/carbon/bam/message/tracer/handler/modules/ActivityInHandler.java >> >> Regards, >> Dinusha. >> >> -- >> Dinusha Dilrukshi >> Senior Software Engineer >> WSO2 Inc.: http://wso2.com/ >> Mobile: +94725255071 >> Blog: http://dinushasblog.blogspot.com/ >> > > > > -- > *Anjana Fernando* > Technical Lead > WSO2 Inc. | http://wso2.com > lean . enterprise . middleware > -- W.G. Gihan Anuruddha Senior Software Engineer | WSO2, Inc. M: +94772272595
_______________________________________________ Dev mailing list [email protected] http://wso2.org/cgi-bin/mailman/listinfo/dev
