Class GuiceStatsTracker


  • public class GuiceStatsTracker
    extends java.lang.Object
    Guice logs internal stats with java util logger (ContinuousStopwatch). In order to intercept these messages, append custom handler to this logger, but just for injector creation time.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.util.List<java.lang.String> getMessages()  
      void injectLogsInterceptor()
      Cut off guice logger from parent handlers and add individual handler to intercept log messages.
      void resetStatsLogger()
      After injector creation reset logger back to parent handler.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • GuiceStatsTracker

        public GuiceStatsTracker()
    • Method Detail

      • injectLogsInterceptor

        public void injectLogsInterceptor()
        Cut off guice logger from parent handlers and add individual handler to intercept log messages.
      • resetStatsLogger

        public void resetStatsLogger()
        After injector creation reset logger back to parent handler.
      • getMessages

        public java.util.List<java.lang.String> getMessages()
        Returns:
        guice injector creation stat messages with non zero time