Hi All,
I am creating a java service that will return the service name from which it is called, compatible with log4j logging. It basically replaces the ‘:’ with a ‘.’.
[highlight=java]
String loggerName = null;
NSService myService = (NSService) Service.getCallingService();
loggerName = myService.getNSName().getFullName();
loggerName.replaceAll(“:”,“.”);
// pipeline out
IDataCursor pipelineCursor = pipeline.getCursor();
IDataUtil.put(pipelineCursor, “loggerName”, loggerName);
pipelineCursor.destroy();
[/highlight]
I don’t want to invoke the pub.string:replace service in here. There is a policy against using existing java services in new java services here.
This is the error I get.
Method replaceAll(java.lang.String, java.lang.String) not found in class java.lang.String. loggerName.replaceAll(“:”,“.”);
Help!!
Thanks in advance,
Zafar.
^
#Integration-Server-and-ESB#webMethods#Flow-and-Java-services