Fancy configuration

Fancy configuration

Record about popular framework some common configuration

lomback profile

<? Xml Version = "1.0" encoding = "UTF-8" ?> < The Configuration > <! - define the log file storage location, using an absolute path -> < Property name = "LOG_HOME" value = "f: / logs " /> ! <- Console output settings -> < the appender name =" the CONSOLE " class =" ch.qos.logback.core.ConsoleAppender " > < Encoder > <-! format output:% d represents the date,% thread indicates that the thread name,% - 5level: level 5 show left character width% msg: log messages,% n newline -> < pattern >

    
    
    
    
        
 
            the MM-YYYY D {%-dd HH: mm: ss.SSS} [Thread%]% {36} Logger -5level% -%% n-MSG </ pattern > 
            < charset > UTF8 </ charset > 
        </ Encoder > 
    < / the appender > <-! accordance log files are generated per day -> < the appender name = "the fILE" class = "ch.qos.logback.core.rolling.RollingFileAppender" > < rollingPolicy class = "ch.qos.logback. core.rolling.TimeBasedRollingPolicy " > <-! filename of the log file output -> <fileNamePattern>
    
    
        
            
            LOG_HOME /chenchaoliang.%d {} {$-YYYY} .log the MM-dd </ fileNamePattern > 
        </ rollingPolicy > 
        < Encoder > 
            < pattern > % {D the MM-dd-YYYY HH: mm: ss.SSS} [% Thread]% {36} Logger -5level% -%% n-MSG </ pattern > 
        </ Encoder > 
    </ the appender > <-! asynchronous output -> < the appender name = "ASYNC" class = "ch.qos .logback.classic.AsyncAppender " > <-! is not lost log default, if 80% of the queue is full, it will TRACT, DEBUG, INFO-level log discarded. -> <discardingThreshold
    
    
        
        > 0 </ discardingThreshold > 
        <-! Change the default depth of the queue, this value can affect the performance of the default value is 256. -> 
        < QueueSize > 512 </ QueueSize > 
        <-! Add additional the appender, at most Add a -> 
        < the appender REF- REF = "the FILE" /> 
    </ the appender > < Logger name = "org.apache.ibatis.cache.decorators.LoggingCache" Level = "the DEBUG" the additivity = "to false" > < REF-the appender REF = "the CONSOLE"/></logger
    
        
    >
    <logger name="org.springframework.boot" level="DEBUG"/>
    <root level="info">
        <!--<appender-ref ref="ASYNC"/>-->
        <appender-ref ref="FILE"/>
        <appender-ref ref="CONSOLE"/>
    </root>
</configuration>

Spring Data JPA Project General configuration

the Spring: 
  the DataSource: 
    Driver-class-name: com.mysql.jdbc.Driver 
    url: jdbc: MySQL: // localhost: 3306 / = the Test serverTimezone UTC? 
    username: root 
    password: root 
  JPA: 
    Database: MySQL 
    Show-SQL: to true          // whether to show sql statement 
    Hibernate: 
      DDL-Auto: update       // each time you run the program does not automatically create a new table, there does not clear the data table is updated

hibernate.ddl-car =

  • create: Each time you run the program, no tables will create a new table, the table has deleted all the data, to ensure that no data is a table

  • create-drop: no tables to create tables, each end of the program will delete table

  • update: The above description has been done

  • validate: Run the program verification data database field types are the same, being given a different

  • none: No style, neatly ordinary

..

Guess you like

Origin www.cnblogs.com/msi-chen/p/11618845.html