Review doc

Replace server.tomcat.compression example as Boot does no longer define
that property
This commit is contained in:
Stephane Nicoll 2015-07-15 17:56:58 +02:00
parent f75333dce2
commit a9737c016c
1 changed files with 29 additions and 25 deletions

View File

@ -29,10 +29,10 @@ categorized under "hints":
"sourceType": "org.springframework.boot.autoconfigure.web.ServerProperties" "sourceType": "org.springframework.boot.autoconfigure.web.ServerProperties"
}, },
{ {
"name": "server.tomcat", "name": "spring.jpa.hibernate",
"type": "org.springframework.boot.autoconfigure.web.ServerProperties$Tomcat", "type": "org.springframework.boot.autoconfigure.orm.jpa.JpaProperties$Hibernate",
"sourceType": "org.springframework.boot.autoconfigure.web.ServerProperties", "sourceType": "org.springframework.boot.autoconfigure.orm.jpa.JpaProperties",
"sourceMethod": "getTomcat()" "sourceMethod": "getHibernate()"
} }
... ...
],"properties": [ ],"properties": [
@ -48,33 +48,35 @@ categorized under "hints":
"defaultValue": "/" "defaultValue": "/"
}, },
{ {
"name": "server.tomcat.compression", "name": "spring.jpa.hibernate.ddl-auto",
"type": "java.lang.String", "type": "java.lang.String",
"description": "Controls response compression.", "description": "DDL mode. This is actually a shortcut for the \"hibernate.hbm2ddl.auto\" property.",
"sourceType": "org.springframework.boot.autoconfigure.web.ServerProperties$Tomcat", "sourceType": "org.springframework.boot.autoconfigure.orm.jpa.JpaProperties$Hibernate"
"defaultValue": "off"
} }
... ...
],"hints": [ ],"hints": [
{ {
"name": "server.tomcat.compression", "name": "spring.jpa.hibernate.ddl-auto",
"values": [ "values": [
{ {
"value": "off", "value": "none",
"description": "Disable compression." "description": "Disable DDL handling."
}, },
{ {
"value": "on", "value": "validate",
"description": "Enable compression of responses over 2048 byte." "description": "Validate the schema, make no changes to the database."
}, },
{ {
"value": "force", "value": "update",
"description": "Enable compression of all responses." "description": "Update the schema if necessary."
}, },
],
"providers": [
{ {
"name": "any" "value": "create",
"description": "Create the schema and destroy previous data."
},
{
"value": "create-drop",
"description": "Create and then destroy the schema at the end of the session."
} }
] ]
} }
@ -99,8 +101,9 @@ NOTE: It is not required that every "`property`" has a "`group`", some propertie
just exist in their own right. just exist in their own right.
Finally, "`hints`" are additional information used to assist the user in configuring a Finally, "`hints`" are additional information used to assist the user in configuring a
given property. When configuring the `server.tomcat.compression` property, a tool can given property. When configuring the `spring.jpa.hibernate.ddl-auto` property, a tool can
use it to offer some auto-completion help for the `off`, `on` and `force` values. use it to offer some auto-completion help for the `none`, `validate`, `update`, `create`
and `create-drop` values.
@ -309,8 +312,9 @@ property, you can provide additional meta-data that:
==== Value hint ==== Value hint
The `name` attribute of each hint refers to the `name` of a property. In the initial The `name` attribute of each hint refers to the `name` of a property. In the initial
example above, we provide 3 values for the `server.tomcat.compression` property: `on`, example above, we provide 5 values for the `spring.jpa.hibernate.ddl-auto` property:
`off` and `force`. `none`, `validate`, `update`, `create` and `create-drop`. Each value may have a
description as well.
If your property is of type `Map`, you can provide hints for both the keys and the If your property is of type `Map`, you can provide hints for both the keys and the
values (but not for the map itself). The special `.keys` and `.values` suffixes must values (but not for the map itself). The special `.keys` and `.values` suffixes must