Class MonitoringFileService


  • @Service
    public class MonitoringFileService
    extends java.lang.Object
    Author:
    Sokkheang
     
     @Component
     public class MonitoringFileServiceConfig extends MonitoringFileService {
      public MonitoringFileServiceConfig(@Value("${logging.file.path}") String directory, @Value("${logging.file.name:spring.log}") String fileName) throws IOException {
       super(directory, fileName);
      }
     }
     
     @RestController
     public class LogsController extends LiveLogsController {}
     
     
     application.properties
     logging.file.path=logs
     
     application.yml
     logging:
      file:
       path: logs
     
    • Constructor Summary

      Constructors 
      Constructor Description
      MonitoringFileService​(java.lang.String directory, java.lang.String fileName)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void listen​(java.util.function.Consumer<java.nio.file.Path> consumer)  
      • Methods inherited from class java.lang.Object

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

      • MonitoringFileService

        public MonitoringFileService​(@Value("${logging.file.path}")
                                     java.lang.String directory,
                                     @Value("${logging.file.name:spring.log}")
                                     java.lang.String fileName)
                              throws java.io.IOException
        Throws:
        java.io.IOException
    • Method Detail

      • listen

        public void listen​(java.util.function.Consumer<java.nio.file.Path> consumer)