=== Hocon Configuration Format

The Hocon Configuration Format extends the Vert.x Configuration Retriever and provides the
support for the HOCON(https://github.com/typesafehub/config/blob/master/HOCON.md) format.

It supports includes, json, properties, macros...

==== Using the Hocon Configuration Format

To use the Hocon Configuration Format, add the following dependency to the
_dependencies_ section of your build descriptor:

* Maven (in your `pom.xml`):

[source,xml,subs="+attributes"]
----
<dependency>
 <groupId>io.vertx</groupId>
 <artifactId>vertx-config-hocon</artifactId>
 <version>${maven.version}</version>
</dependency>
<dependency>
 <groupId>io.vertx</groupId>
 <artifactId>vertx-config</artifactId>
 <version>${maven.version}</version>
</dependency>
----

* Gradle (in your `build.gradle` file):

[source,groovy,subs="+attributes"]
----
compile 'io.vertx:vertx-config:${maven.version}'
compile 'io.vertx:vertx-config-hocon:${maven.version}'
----

==== Configuring the store to use HOCON

Once added to your classpath or dependencies, you need to configure the
`link:../../scaladocs/io/vertx/scala/config/ConfigRetriever.html[ConfigRetriever]` to use this format:

[source, scala]
----
var store = ConfigStoreOptions()
  .setType("file")
  .setFormat("hocon")
  .setConfig(new io.vertx.core.json.JsonObject().put("path", "my-config.conf"))


var retriever = ConfigRetriever.create(vertx, ConfigRetrieverOptions()
  .setStores(Set(store))
)

----

You just need to set `format` to `hocon`.