///////////////////////////////////////////////////////////////////////////////

    Copyright (c) 2018 Oracle and/or its affiliates. All rights reserved.

    Licensed under the Apache License, Version 2.0 (the "License");
    you may not use this file except in compliance with the License.
    You may obtain a copy of the License at

        http://www.apache.org/licenses/LICENSE-2.0

    Unless required by applicable law or agreed to in writing, software
    distributed under the License is distributed on an "AS IS" BASIS,
    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    See the License for the specific language governing permissions and
    limitations under the License.

///////////////////////////////////////////////////////////////////////////////

= Configuring the Application
:description: Helidon MicroProfile application configuration
:keywords: helidon, microprofile, micro-profile

Your application can use the MicroProfile Config or
 Helidon Config (or both). MicroProfile Config offers portability to other
 MicroProfile servers. Helidon Config supports a full tree structure, including repeating
 elements.

== Configuring the Application

You can inject values that the application can access from both MicroProfile Config and from
Helidon Config.

[source,java]
.JAX-RS - inject a single config property
----
@Inject
public MyResource(@ConfigProperty(name="app.name") String appName) {
    this.applicationName = appName;
}
----

You can also inject the whole configuration instance, 
either `io.helidon.config.Config` or
 `org.eclipse.microprofile.config.Config`.
[source,java]
.JAX-RS - inject config
----
@Inject
public MyResource(Config config) {
    this.config = config;
}
----
