Spring Boot 2.0.2 參考指南(通用的應用程序屬性 ②)中文文檔

通用的應用程序屬性 ②

sendgrid(SendGridAutoConfiguration

spring.sendgrid.api-key= # SendGrid API key
spring.sendgrid.proxy.host= # SendGrid 代理主機
spring.sendgrid.proxy.port= # SendGrid 代理端口

嵌入式服務器配置(ServerProperties

# ----------------------------------------
# WEB 屬性
# ----------------------------------------

server.address= # 服務器應該綁定到的網絡地址
server.compression.enabled=false # 是否啓用響應壓縮
server.compression.excluded-user-agents= # 從壓縮中排除的user-agent列表
server.compression.mime-types=text/html,text/xml,text/plain,text/css,text/javascript,application/javascript # 應該壓縮的以逗號分隔的MIME類型列表
server.compression.min-response-size=2048 # 執行壓縮所需的最小"Content-Length"值
server.connection-timeout= # 鏈接器在關閉鏈接以前等待另外一個HTTP請求的時間,當沒有設置時,使用鏈接器特定於容器的默認值,使用-1值表示不超時(即不限超時)
server.error.include-exception=false # 包括「exception」屬性
server.error.include-stacktrace=never # 什麼時候包含「stacktrace」屬性
server.error.path=/error # error controller的路徑
server.error.whitelabel.enabled=true # 是否啓用瀏覽器中顯示的默認error頁面,以防出現服務器error
server.http2.enabled=false # 若是當前環境支持,是否啓用HTTP/2支持
server.jetty.acceptors= # 使用的接收線程數
server.jetty.accesslog.append=false # 添加到日誌
server.jetty.accesslog.date-format=dd/MMM/yyyy:HH:mm:ss Z # 請求日誌的時間戳格式
server.jetty.accesslog.enabled=false # 啓用訪問日誌
server.jetty.accesslog.extended-format=false # 啓用擴展的NCSA格式
server.jetty.accesslog.file-date-format= # 日期格式放置在日誌文件名中
server.jetty.accesslog.filename= # 日誌文件名,若是沒有指定,日誌重定向到「System.err」
server.jetty.accesslog.locale= # 請求日誌的語言環境
server.jetty.accesslog.log-cookies=false # 啓用請求cookie的日誌記錄
server.jetty.accesslog.log-latency=false # 容許記錄請求處理時間
server.jetty.accesslog.log-server=false # 啓用對請求主機名的日誌記錄
server.jetty.accesslog.retention-period=31 # 在滾動日誌前幾天將被刪除
server.jetty.accesslog.time-zone=GMT # 請求日誌的時區
server.jetty.max-http-post-size=0 # HTTP post或put內容的最大大小(以字節爲單位)
server.jetty.selectors= # 要使用的選擇器線程數
server.max-http-header-size=0 # HTTP消息頭的最大大小(以字節爲單位)
server.port=8080 # 服務器HTTP端口
server.server-header= # 用於服務器響應header的值(若是爲空,則不發送header)
server.use-forward-headers= # 是否應該將X-Forwarded-* header應用於HttpRequest
server.servlet.context-parameters.*= # Servlet上下文初始化參數
server.servlet.context-path= # 應用程序的上下文路徑
server.servlet.application-display-name=application # 顯示應用程序的名稱
server.servlet.jsp.class-name=org.apache.jasper.servlet.JspServlet # JSP servlet的類名
server.servlet.jsp.init-parameters.*= # 用於配置JSP servlet的Init參數
server.servlet.jsp.registered=true # 是否註冊了JSP servlet
server.servlet.path=/ # 主dispatcher servlet的路徑
server.servlet.session.cookie.comment= # 對session cookie的註釋
server.servlet.session.cookie.domain= # session cookie的域
server.servlet.session.cookie.http-only= # 「HttpOnly」標記session cookie
server.servlet.session.cookie.max-age= # session cookie的最大時間,若是沒有指定持續時間後綴,則將使用秒
server.servlet.session.cookie.name= # Session cookie的名稱
server.servlet.session.cookie.path= # Session cookie的路徑
server.servlet.session.cookie.secure= # Session cookie的「安全」標誌
server.servlet.session.persistent=false # 是否在從新啓動之間持久化session數據
server.servlet.session.store-dir= # 用於存儲session數據的目錄
server.servlet.session.timeout= # session超時,若是沒有指定持續時間後綴,則將使用秒
server.servlet.session.tracking-modes= # session跟蹤模式(如下一種或多種模式:「cookie」、「url」、「ssl」)
server.ssl.ciphers= # 支持SSL密碼
server.ssl.client-auth= # 是否想要客戶端身份驗證(「want」)或須要(「need」),須要一個信任存儲區
server.ssl.enabled= # 啓用SSL支持
server.ssl.enabled-protocols= # 啓用SSL協議
server.ssl.key-alias= # 標識密鑰存儲庫中的密鑰的別名
server.ssl.key-password= # 用於訪問密鑰存儲庫中的密鑰的密碼
server.ssl.key-store= # 包含SSL證書(一般是jks文件)的密鑰存儲庫的路徑
server.ssl.key-store-password= # 用於訪問密鑰存儲庫的密碼
server.ssl.key-store-provider= # 密鑰存儲庫的提供程序
server.ssl.key-store-type= # 密鑰存儲庫的類型
server.ssl.protocol=TLS # 使用SSL協議
server.ssl.trust-store= # 託管SSL證書的信任存儲區
server.ssl.trust-store-password= # 用於訪問信任存儲區的密碼
server.ssl.trust-store-provider= # 信任存儲區的提供程序
server.ssl.trust-store-type= # 信任存儲區的類型
server.tomcat.accept-count=0 # Maximum queue length for incoming connection requests when all possible request processing threads are in use.
server.tomcat.accesslog.buffered=true # Whether to buffer output such that it is flushed only periodically.
server.tomcat.accesslog.directory=logs # Directory in which log files are created. Can be absolute or relative to the Tomcat base dir.
server.tomcat.accesslog.enabled=false # Enable access log.
server.tomcat.accesslog.file-date-format=.yyyy-MM-dd # Date format to place in the log file name.
server.tomcat.accesslog.pattern=common # Format pattern for access logs.
server.tomcat.accesslog.prefix=access_log # Log file name prefix.
server.tomcat.accesslog.rename-on-rotate=false # Whether to defer inclusion of the date stamp in the file name until rotate time.
server.tomcat.accesslog.request-attributes-enabled=false # Set request attributes for the IP address, Hostname, protocol, and port used for the request.
server.tomcat.accesslog.rotate=true # Whether to enable access log rotation.
server.tomcat.accesslog.suffix=.log # Log file name suffix.
server.tomcat.additional-tld-skip-patterns= # Comma-separated list of additional patterns that match jars to ignore for TLD scanning.
server.tomcat.background-processor-delay=30s # Delay between the invocation of backgroundProcess methods. If a duration suffix is not specified, seconds will be used.
server.tomcat.basedir= # Tomcat base directory. If not specified, a temporary directory is used.
server.tomcat.internal-proxies=10\\.\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}|\\
        192\\.168\\.\\d{1,3}\\.\\d{1,3}|\\
        169\\.254\\.\\d{1,3}\\.\\d{1,3}|\\
        127\\.\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}|\\
        172\\.1[6-9]{1}\\.\\d{1,3}\\.\\d{1,3}|\\
        172\\.2[0-9]{1}\\.\\d{1,3}\\.\\d{1,3}|\\
        172\\.3[0-1]{1}\\.\\d{1,3}\\.\\d{1,3} # Regular expression matching trusted IP addresses.
server.tomcat.max-connections=0 # Maximum number of connections that the server accepts and processes at any given time.
server.tomcat.max-http-header-size=0 # Maximum size, in bytes, of the HTTP message header.
server.tomcat.max-http-post-size=0 # Maximum size, in bytes, of the HTTP post content.
server.tomcat.max-threads=0 # Maximum number of worker threads.
server.tomcat.min-spare-threads=0 # Minimum number of worker threads.
server.tomcat.port-header=X-Forwarded-Port # Name of the HTTP header used to override the original port value.
server.tomcat.protocol-header= # Header that holds the incoming protocol, usually named "X-Forwarded-Proto".
server.tomcat.protocol-header-https-value=https # Value of the protocol header indicating whether the incoming request uses SSL.
server.tomcat.redirect-context-root= # Whether requests to the context root should be redirected by appending a / to the path.
server.tomcat.remote-ip-header= # Name of the HTTP header from which the remote IP is extracted. For instance, `X-FORWARDED-FOR`.
server.tomcat.resource.cache-ttl= # Time-to-live of the static resource cache.
server.tomcat.uri-encoding=UTF-8 # Character encoding to use to decode the URI.
server.tomcat.use-relative-redirects= # Whether HTTP 1.1 and later location headers generated by a call to sendRedirect will use relative or absolute redirects.
server.undertow.accesslog.dir= # Undertow access log directory.
server.undertow.accesslog.enabled=false # Whether to enable the access log.
server.undertow.accesslog.pattern=common # Format pattern for access logs.
server.undertow.accesslog.prefix=access_log. # Log file name prefix.
server.undertow.accesslog.rotate=true # Whether to enable access log rotation.
server.undertow.accesslog.suffix=log # Log file name suffix.
server.undertow.buffer-size= # Size of each buffer, in bytes.
server.undertow.direct-buffers= # Whether to allocate buffers outside the Java heap.
server.undertow.io-threads= # Number of I/O threads to create for the worker.
server.undertow.eager-filter-init=true # Whether servlet filters should be initialized on startup.
server.undertow.max-http-post-size=0 # Maximum size, in bytes, of the HTTP post content.
server.undertow.worker-threads= # Number of worker threads.

freemarker(FreeMarkerProperties

# FREEMARKER (FreeMarkerProperties)
spring.freemarker.allow-request-override=false # Whether HttpServletRequest attributes are allowed to override (hide) controller generated model attributes of the same name.
spring.freemarker.allow-session-override=false # Whether HttpSession attributes are allowed to override (hide) controller generated model attributes of the same name.
spring.freemarker.cache=false # Whether to enable template caching.
spring.freemarker.charset=UTF-8 # Template encoding.
spring.freemarker.check-template-location=true # Whether to check that the templates location exists.
spring.freemarker.content-type=text/html # Content-Type value.
spring.freemarker.enabled=true # Whether to enable MVC view resolution for this technology.
spring.freemarker.expose-request-attributes=false # Whether all request attributes should be added to the model prior to merging with the template.
spring.freemarker.expose-session-attributes=false # Whether all HttpSession attributes should be added to the model prior to merging with the template.
spring.freemarker.expose-spring-macro-helpers=true # Whether to expose a RequestContext for use by Spring's macro library, under the name "springMacroRequestContext".
spring.freemarker.prefer-file-system-access=true # Whether to prefer file system access for template loading. File system access enables hot detection of template changes.
spring.freemarker.prefix= # Prefix that gets prepended to view names when building a URL.
spring.freemarker.request-context-attribute= # Name of the RequestContext attribute for all views.
spring.freemarker.settings.*= # Well-known FreeMarker keys which are passed to FreeMarker's Configuration.
spring.freemarker.suffix=.ftl # Suffix that gets appended to view names when building a URL.
spring.freemarker.template-loader-path=classpath:/templates/ # Comma-separated list of template paths.
spring.freemarker.view-names= # White list of view names that can be resolved.

groovy template(GroovyTemplateProperties

# GROOVY TEMPLATES (GroovyTemplateProperties)
spring.groovy.template.allow-request-override=false # Whether HttpServletRequest attributes are allowed to override (hide) controller generated model attributes of the same name.
spring.groovy.template.allow-session-override=false # Whether HttpSession attributes are allowed to override (hide) controller generated model attributes of the same name.
spring.groovy.template.cache=false # Whether to enable template caching.
spring.groovy.template.charset=UTF-8 # Template encoding.
spring.groovy.template.check-template-location=true # Whether to check that the templates location exists.
spring.groovy.template.configuration.*= # See GroovyMarkupConfigurer
spring.groovy.template.content-type=text/html # Content-Type value.
spring.groovy.template.enabled=true # Whether to enable MVC view resolution for this technology.
spring.groovy.template.expose-request-attributes=false # Whether all request attributes should be added to the model prior to merging with the template.
spring.groovy.template.expose-session-attributes=false # Whether all HttpSession attributes should be added to the model prior to merging with the template.
spring.groovy.template.expose-spring-macro-helpers=true # Whether to expose a RequestContext for use by Spring's macro library, under the name "springMacroRequestContext".
spring.groovy.template.prefix= # Prefix that gets prepended to view names when building a URL.
spring.groovy.template.request-context-attribute= # Name of the RequestContext attribute for all views.
spring.groovy.template.resource-loader-path=classpath:/templates/ # Template path.
spring.groovy.template.suffix=.tpl # Suffix that gets appended to view names when building a URL.
spring.groovy.template.view-names= # White list of view names that can be resolved.

spring hateoas(HateoasProperties

# SPRING HATEOAS (HateoasProperties)
spring.hateoas.use-hal-as-default-json-media-type=true # Whether application/hal+json responses should be sent to requests that accept application/json.

HTTP消息轉換

# HTTP message conversion
spring.http.converters.preferred-json-mapper= # Preferred JSON mapper to use for HTTP message conversion. By default, auto-detected according to the environment.

HTTP編碼

# HTTP message conversion
spring.http.converters.preferred-json-mapper= # Preferred JSON mapper to use for HTTP message conversion. By default, auto-detected according to the environment.
相關文章
相關標籤/搜索