LOGGER doesn't work in spring boot with Microsoft Azure

169 Views Asked by At

I have developed a spring boot application in Microsoft azure with @ServiceBusTrigger. But in this logger is not working as expected.

I am using below function for this:

 @FunctionName("irn-generate")
public void serviceBusProcess(  @ServiceBusQueueTrigger(name = "msg", queueName = "queueName", connection = "connectionstring") String message,
  ExecutionContext context) {
    try {

        LOGGER.info("in logger string:{}",message.toString());
        context.getLogger().info(message);
    } catch (Exception e) {
        // TODO Auto-generated catch block

    }

}

Here ,I am able to get log using context but how can I achieve this outside this function. Can anyone help me to get out of this?

0

There are 0 best solutions below