package org.wildfly.swarm.examples.jaxrs.cdi;

import javax.enterprise.context.ApplicationScoped;
import javax.inject.Inject;
import javax.ws.rs.GET;
import javax.ws.rs.Path;
import javax.ws.rs.Produces;
import javax.ws.rs.core.MediaType;

import org.wildfly.swarm.cdi.ConfigValue;

/**
 * @author Heiko Braun
 */
@ApplicationScoped
@Path("/app")
public class Controller {

    @Inject
    @ConfigValue("some.string.property")
    String stringProperty;

    @Inject
    @ConfigValue("some.integer.property")
    Integer intProperty;

    @Inject
    @ConfigValue("some.boolean.property")
    Boolean boolProperty;

    @GET
    @Path("/propertyString")
    @Produces(MediaType.TEXT_PLAIN)
    public String getStringProperty() {
        if(null==stringProperty) throw new RuntimeException("config property not initialised");
        return stringProperty;
    }

    @GET
    @Path("/propertyInteger")
    @Produces(MediaType.TEXT_PLAIN)
    public String getIntegerProperty() {
        if(null==intProperty) throw new RuntimeException("config property not initialised");
        return String.valueOf(intProperty);
    }

    @GET
    @Path("/propertyBoolean")
    @Produces(MediaType.TEXT_PLAIN)
    public String getBoolProperty() {
        if(null==boolProperty) throw new RuntimeException("config property not initialised");
        return String.valueOf(boolProperty);
    }
}

@@ -262,18 +262,45 @@
 arm.
-cdi.Config
+spi.runtime.annotations.Configuration
 Valu
@@ -409,32 +409,39 @@
 ject%0A    @Config
+uration
 Value(%22some.stri
@@ -497,32 +497,39 @@
 ject%0A    @Config
+uration
 Value(%22some.inte
@@ -592,16 +592,23 @@
  @Config
+uration
 Value(%22s
@@ -781,23 +781,26 @@
       if
+ 
 (null
+ 
 ==
+ 
 stringPr
@@ -1034,23 +1034,26 @@
       if
+ 
 (null
+ 
 ==
+ 
 intPrope
@@ -1298,15 +1298,18 @@
   if
+ 
 (null
+ 
 ==
+ 
 bool

Modify example as @ConfigurationValue package is now different