static

in invoker/core/src/main/java/com/google/cloud/functions/invoker/runner/Invoker.java [88:99]


  static {
    if (isGcf()) {
      // If we're running with Google Cloud Functions, we'll get better-looking logs
      // if we arrange for them to be formatted using StackDriver's "structured
      // logging" JSON format. Remove the JDK's standard logger and replace it with
      // the JSON one.
      for (Handler handler : rootLogger.getHandlers()) {
        rootLogger.removeHandler(handler);
      }
      rootLogger.addHandler(new JsonLogHandler(System.out, false));
    }
  }