I have been doubting for a long time whether or not to have a logger in methods (usually helper methods) like the one below.Whether we can print it in the method or print the response where the method is called.public String getAddNewUserUrl(){    String url      =   null;    String mode     =   null;    try    {        log.info(Inside getAddNewUserUrl ); // Can u use logs like this.        mode        =   new ModeUtil().getMode();        if(local.equalsIgnoreCase(mode) || staging.equalsIgnoreCase(mode))        {            url     =   ResourceBundle.getBundle(ApplicationResources).getString(staging.url);        }        else        {            url     =   ResourceBundle.getBundle(ApplicationResources).getString(staging.url);          }        log.info(The url is  :  + url);  // Can u use logs like this    }    catch(Exception e)    {        e.printStackTrace();        log.info(Exception in the method getMode ::+e.getMessage());    }    return url;
Is it fine to use logs in the Helper Methods?
java;java ee;logging
Logs are supposed to be put in every part of your application to provide meaningful information to developer/tester/debuggers or any other stake holder.Just be careful to put appropriate logging level in your helper classes/utilities especially if you going to distribute it as jar.