You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tamaya.apache.org by st...@apache.org on 2014/12/27 14:57:52 UTC

[08/34] incubator-tamaya git commit: first step: move all sources to a 'dormant' directory

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/core/src/test/java/org/apache/tamaya/samples/annotations/ConfiguredTest.java
----------------------------------------------------------------------
diff --git a/dormant/core/src/test/java/org/apache/tamaya/samples/annotations/ConfiguredTest.java b/dormant/core/src/test/java/org/apache/tamaya/samples/annotations/ConfiguredTest.java
new file mode 100644
index 0000000..112f479
--- /dev/null
+++ b/dormant/core/src/test/java/org/apache/tamaya/samples/annotations/ConfiguredTest.java
@@ -0,0 +1,65 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you 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.
+ */
+package org.apache.tamaya.samples.annotations;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assume.assumeTrue;
+
+import org.apache.tamaya.Configuration;
+import org.junit.Test;
+
+/**
+ * Created by Anatole on 08.09.2014.
+ */
+public class ConfiguredTest {
+    private static final String OS = System.getProperty("os.name").toLowerCase();
+
+    @Test
+    public void testTemplateOnAllSystems(){
+        ConfigTemplate template = Configuration.createTemplate(ConfigTemplate.class);
+        assertNotNull(template);
+        assertEquals(2233, template.int2());
+        assertEquals(Integer.valueOf(5), template.int1());
+        assertNotNull(System.getProperty("java.version"), template.javaVersion2());
+    }
+
+    @Test
+    public void testTemplateWithEnvironmentVariableOnWindows(){
+        assumeTrue(OS.contains("win"));
+        ConfigTemplate template = Configuration.createTemplate(ConfigTemplate.class);
+        assertNotNull(template.computerName());
+    }
+
+    @Test
+    public void testTemplateWithEnvironmentVariableOnMac(){
+        assumeTrue(OS.contains("mac"));
+        ConfigTemplate template = Configuration.createTemplate(ConfigTemplate.class);
+        assertNotNull(template.homeDir());
+    }
+
+    @Test
+    public void testTemplateWithEnvironmentVariableOnUnixoidSystem(){
+        assumeTrue(OS.contains("nix") || OS.contains("nux") || OS.indexOf("aix") > 0);
+
+        ConfigTemplate template = Configuration.createTemplate(ConfigTemplate.class);
+        assertNotNull(template.homeDir());
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/core/src/test/java/org/apache/tamaya/samples/devops/DeploymentProvider.java
----------------------------------------------------------------------
diff --git a/dormant/core/src/test/java/org/apache/tamaya/samples/devops/DeploymentProvider.java b/dormant/core/src/test/java/org/apache/tamaya/samples/devops/DeploymentProvider.java
new file mode 100644
index 0000000..18e6705
--- /dev/null
+++ b/dormant/core/src/test/java/org/apache/tamaya/samples/devops/DeploymentProvider.java
@@ -0,0 +1,43 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you 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.
+ */
+package org.apache.tamaya.samples.devops;
+
+
+public class DeploymentProvider {
+
+	public static void main(String[] args) {
+		// ConfigurationServiceSpi service = JavaConfig.getConfigService();
+		// // Main configuration done by ServiceLoader based services and
+		// // custom implemented system or environment properties, mechanisms
+		// System.out.println(service.getCurrentContext());
+		// // Access default configuration for current environment
+		// DefaultEnvironment myTarget = new DefaultEnvironment();
+		// myTarget.setAttribute("domain", "com.test.mydom:domain1:1.0.1");
+		// myTarget.setAttribute("application", "com.test.mydom:app1:1.0.1");
+		// myTarget.setAttribute("env", "localTest");
+		// myTarget.setStage(Stage.UnitTest);
+		// Configuration deploymentConfig =
+		// service.getConfiguration("deployment", myTarget);
+		// String startupName = deploymentConfig
+		// .getProperty("deploy.startupName", "N/A");
+		// int intProp = deploymentConfig.getInteger(
+		// "deploy.mainContainer.size");
+		// // ...
+	}
+}

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/core/src/test/java/org/apache/tamaya/simple/SimplePropertiesAndCLISample.java
----------------------------------------------------------------------
diff --git a/dormant/core/src/test/java/org/apache/tamaya/simple/SimplePropertiesAndCLISample.java b/dormant/core/src/test/java/org/apache/tamaya/simple/SimplePropertiesAndCLISample.java
new file mode 100644
index 0000000..e0351b2
--- /dev/null
+++ b/dormant/core/src/test/java/org/apache/tamaya/simple/SimplePropertiesAndCLISample.java
@@ -0,0 +1,69 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you 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.
+ */
+package org.apache.tamaya.simple;
+
+import java.util.HashMap;
+import java.util.Map;
+
+import org.apache.tamaya.Configuration;
+import org.apache.tamaya.core.ConfigurationFunctions;
+import org.apache.tamaya.core.properties.PropertySourceBuilder;
+import org.junit.Test;
+
+/**
+ * Created by Anatole on 24.02.14.
+ */
+public class SimplePropertiesAndCLISample {
+
+    @Test
+    public void testSystemPropertyResolution() {
+        System.out.println(Configuration.evaluateValue("${sys:java.version}"));
+    }
+
+    @Test
+    public void testProgrammatixPropertySet() {
+        System.out.println(PropertySourceBuilder.of("test").addPaths("test", "classpath:test.properties").build());
+    }
+
+    @Test
+    public void testProgrammaticConfig() {
+//        ConfigurationFormat format = ConfigurationFormats.getPropertiesFormat();
+        Map<String, String> cfgMap = new HashMap<>();
+        cfgMap.put("param1", "value1");
+        cfgMap.put("a", "Adrian"); // overrides Anatole
+        Configuration config = Configuration.from(PropertySourceBuilder.of("myTestConfig").addPaths(
+                "classpath:test.properties").addPaths("classpath:cfg/test.xml")
+                .addArgs(new String[]{"-arg1", "--fullarg", "fullValue", "-myflag"}).addMap(cfgMap)
+                .build());
+        System.out.println(config.query(ConfigurationFunctions.getAreas()));
+        System.out.println("---");
+        System.out.println(config.query(ConfigurationFunctions.getAreas(s -> s.startsWith("another"))));
+        System.out.println("---");
+        System.out.println(config.query(ConfigurationFunctions.getTransitiveAreas()));
+        System.out.println("---");
+        System.out.println(config.query(ConfigurationFunctions.getTransitiveAreas(s -> s.startsWith("another"))));
+        System.out.println("---");
+        System.out.println(config);
+        System.out.print("--- b=");
+        System.out.println(config.get("b"));
+//        System.out.println("--- only a,b,c)");
+//        System.out.println(PropertySourceBuilder.of(config).filter((f) -> f.equals("a") || f.equals("b") || f.equals("c")).build());
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/core/src/test/java/org/apache/tamaya/ucs/UC1ReadProperties.java
----------------------------------------------------------------------
diff --git a/dormant/core/src/test/java/org/apache/tamaya/ucs/UC1ReadProperties.java b/dormant/core/src/test/java/org/apache/tamaya/ucs/UC1ReadProperties.java
new file mode 100644
index 0000000..e7f2049
--- /dev/null
+++ b/dormant/core/src/test/java/org/apache/tamaya/ucs/UC1ReadProperties.java
@@ -0,0 +1,220 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you 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 current 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.
+ */
+package org.apache.tamaya.ucs;
+
+import static junit.framework.TestCase.assertTrue;
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertFalse;
+import static org.junit.Assert.assertNotNull;
+
+import java.util.Map;
+import java.util.stream.Collectors;
+
+import org.apache.tamaya.Configuration;
+import org.apache.tamaya.PropertySource;
+import org.apache.tamaya.core.ConfigurationFunctions;
+import org.apache.tamaya.core.properties.AggregationPolicy;
+import org.apache.tamaya.core.properties.PropertySourceBuilder;
+import org.junit.Test;
+
+/**
+ * Configuration is organized as key/keys pairs. This basically can be modeled as {@code Map<String,String>}
+ * Configuration should be as simple as possible. A {@code Map<String,String>} instance has methods that may not
+ * be used in many use cases and/or are not easy to implement. Currently the following functionality
+ * must be supported:
+ * <ul>
+ * <li>access a keys by key (+get+)</li>
+ * <li>check if a keys is present (+containsKey+)</li>
+ * <li>get a set current all defined keys (+keySet+)</li>
+ * <li>a property provider must be convertible to a +Map+, by calling +getProperties()+</li>
+ * <li>a property provider must get access to its meta information.</li>
+ * </ul>
+ * Additionally there are other requirement important for ease current use:
+ * <ul>
+ * <li>The API must never return null.</li>
+ * <li>The API should support undefined values.</li>
+ * <li>The API must support passing default values, to be returned if a keys is undefined.</li>
+ * <li>The API must allow to throw exceptions, when a keys is undefined.
+ * Customized exceptions hereby should be supported.</li>
+ * <li>Properties can be stored in the classpath, on a file.</li>
+ * <li>Properties can be stored as properties, xml-properties or as ini-files.</li>
+ * <li>Properties can also be provided as properties, or as a Map<String,String></li>
+ * </ul>
+ */
+public class UC1ReadProperties {
+
+    @Test
+    public void example() {
+        Configuration config = Configuration.from(PropertySourceBuilder.of("test")
+                .addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build());
+//        String name = config.get("name").orElse("Anatole");
+//        BigDecimal bigNum = config.get("num.BD", BigDecimal.class).orElseThrow(() -> new IllegalStateException("Sorry"));
+//        double anotherNum = config.getDouble("num.Double").getAsDouble();
+//        long longNum = config.getLong("num.Long").orElse(288900L);
+
+        // or more simpler use area function
+        Configuration areaConfig2 = config.with(ConfigurationFunctions.selectArea("num"));
+        System.out.println(areaConfig2);
+
+        // iterator over an area, using streams only
+        Map<String, String> areaMap = config.getProperties().entrySet().stream()
+                .filter((e) -> e.getKey().startsWith("num."))
+                .collect(Collectors.toMap((e) -> e.getKey().substring("num.".length()), Map.Entry::getValue));
+        Configuration areaConfig = Configuration.from(PropertySourceBuilder.of("Test").addMap(areaMap).build());
+        System.out.println(areaConfig);
+    }
+
+    @Test
+    public void getConfigurationTest() {
+        PropertySource provider = PropertySourceBuilder.of("Test").addPaths("classpath:barFoo.properties").build();
+        Configuration config = Configuration.from(provider);
+        assertNotNull(config);
+        assertTrue(config.isEmpty());
+        assertTrue(config.getProperties().isEmpty());
+    }
+
+    @Test
+    public void readBadPropertiesTest() {
+        PropertySource provider = PropertySourceBuilder.of("Test").addPaths("classpath:barFoo.properties").build();
+        assertNotNull(provider);
+        assertTrue(provider.isEmpty());
+        assertTrue(provider.getProperties().isEmpty());
+    }
+
+    @Test
+    public void readPropertiesTest() {
+        PropertySource provider = PropertySourceBuilder.of("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build();
+        assertNotNull(provider);
+        assertEquals(provider.get("a").get(), "aValue");
+        assertEquals(provider.get("b").get(), "bValue");
+        assertEquals(provider.get("c").get(), "cValue");
+        assertEquals(provider.get("a.b.c").get(), "abcValue");
+        assertEquals(provider.get("a.b.a").get(), "abaValue");
+        assertEquals(provider.get("a.b.b").get(), "abbValue");
+        assertEquals(provider.get("a.b").get(), "abValue");
+        assertEquals(provider.get("a.a.a").get(), "aaaValue");
+        assertEquals(provider.get("b.b.b").get(), "bbbValue");
+        assertEquals(provider.get("c.c.c").get(), "cccValue");
+        assertEquals(provider.get("numInt").get(), "9999");
+        assertEquals(provider.get("num.Int").get(), "123");
+        assertEquals(provider.get("num.Byte").get(), "100");
+        assertEquals(provider.get("boolean").get(), "true");
+        assertEquals(provider.get("num.BD").get(), "2376523725372653.287362836283628362863");
+        assertEquals(provider.get("num.Double").get(), "21334.43254");
+        assertTrue(!provider.get("blabla").isPresent());
+        assertTrue(provider.get("num.BD").isPresent());
+    }
+
+    @Test
+    public void readXmlPropertiesTest() {
+        PropertySource provider = PropertySourceBuilder.of("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.xml").build();
+        assertNotNull(provider);
+        assertEquals(provider.get("a-xml").get(), "aFromXml");
+        assertEquals(provider.get("b-xml").get(), "bFromXml");
+        assertEquals(provider.get("a.b.c-xml").get(), "abcFromXml");
+    }
+
+    @Test
+    public void readIniPropertiesTest() {
+        PropertySource provider = PropertySourceBuilder.of("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.ini").build();
+        assertNotNull(provider);
+        assertEquals(provider.get("a.b.c").get(), "abcValue-fromIni");
+        assertEquals(provider.get("a.b.b").get(), "abbValue-fromIni");
+        assertEquals(provider.get("a.b.a").get(), "abaValue-fromIni");
+        assertEquals(provider.get("mixed.a.b").get(), "abValue");
+        assertFalse(provider.get("mixed.foo").isPresent());
+        assertTrue(provider.get("num.BD").isPresent());
+    }
+
+    @Test
+    public void readAllPropertiesTest() {
+        PropertySource provider = PropertySourceBuilder.of("Test").withAggregationPolicy(AggregationPolicy.IGNORE_DUPLICATES)
+                .addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.*").build();
+        assertNotNull(provider);
+        // fromMap ini file
+        assertEquals(provider.get("a.b.c").get(), "abcValue-fromIni");
+        assertEquals(provider.get("a.b.b").get(), "abbValue-fromIni");
+        assertEquals(provider.get("a.b.a").get(), "abaValue-fromIni");
+        // fromMap properties
+        assertTrue(provider.get("num.BD").isPresent());
+        // fromMap xml properties
+        assertEquals(provider.get("a-xml").get(), "aFromXml");
+        assertEquals(provider.get("b-xml").get(), "bFromXml");
+    }
+
+    @Test
+    public void checkForAValue() {
+        PropertySource provider = PropertySourceBuilder.of("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build();
+        assertFalse(provider.get("blabla").isPresent());
+        assertTrue(provider.get("num.BD").isPresent());
+        assertFalse(provider.get("blabla").isPresent());
+        assertTrue(provider.get("num.BD").isPresent());
+    }
+
+    @Test
+    public void checkKeys() {
+        PropertySource provider = PropertySourceBuilder.of("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build();
+        assertEquals(provider.getProperties().size(), 16);
+        assertTrue(provider.getProperties().keySet().contains("boolean"));
+        assertFalse(provider.getProperties().keySet().contains("blabla"));
+    }
+
+    @Test
+    public void checkToMap() {
+        PropertySource provider = PropertySourceBuilder.of("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build();
+        Map<String, String> map = provider.getProperties();
+        assertNotNull(map);
+        assertEquals(map.size(), 16);
+        assertEquals(provider.getProperties().keySet(), map.keySet());
+        assertTrue(map.keySet().contains("boolean"));
+        assertFalse(map.keySet().contains("blabla"));
+    }
+
+    @Test
+    public void checkMetaInfo() {
+        PropertySource provider = PropertySourceBuilder.of("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build();
+        assertNotNull(provider.getName());
+    }
+
+    @Test
+    public void checkNeverNull() {
+        PropertySource provider = PropertySourceBuilder.of("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build();
+        assertNotNull(provider.get("blabla"));
+        assertNotNull(provider.get("a.b.c"));
+    }
+
+    @Test
+    public void checkUndefined() {
+        PropertySource provider = PropertySourceBuilder.of("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build();
+        assertFalse(provider.get("blabla").isPresent());
+        assertTrue(provider.get("a.b.c").isPresent());
+    }
+
+    @Test
+    public void checkPassDefaultValues() {
+        PropertySource provider = PropertySourceBuilder.of("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build();
+        assertEquals("myDefaultValue", provider.get("blabla").orElse("myDefaultValue"));
+    }
+
+    @Test(expected = IllegalStateException.class)
+    public void checkThrowCustomException() {
+        PropertySource provider = PropertySourceBuilder.of("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build();
+        provider.get("blabla").orElseThrow(() -> new IllegalStateException("checkThrowCustomException"));
+    }
+}

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/core/src/test/java/org/apache/tamaya/ucs/UC2CombineProperties.java
----------------------------------------------------------------------
diff --git a/dormant/core/src/test/java/org/apache/tamaya/ucs/UC2CombineProperties.java b/dormant/core/src/test/java/org/apache/tamaya/ucs/UC2CombineProperties.java
new file mode 100644
index 0000000..60ab6ea
--- /dev/null
+++ b/dormant/core/src/test/java/org/apache/tamaya/ucs/UC2CombineProperties.java
@@ -0,0 +1,70 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you 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 current 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.
+ */
+package org.apache.tamaya.ucs;
+
+import org.apache.tamaya.ConfigException;
+import org.apache.tamaya.PropertySource;
+import org.apache.tamaya.core.properties.AggregationPolicy;
+import org.apache.tamaya.core.properties.PropertySourceBuilder;
+import org.junit.Test;
+
+/**
+ * Configuration is organized as key/keys pairs. This basically can be modeled as {@code Map<String,String>}
+ * Configuration should be as simple as possible. Advanced use cases can often easily implemented by combining
+ * multiple property maps and applying hereby some combination policy. This test class demonstrates the different
+ * options Tamaya is providing and the according mechanisms.
+ */
+public class UC2CombineProperties {
+
+    /**
+     * The most common use cases is aggregating two property config to new provider, hereby {@link org.apache.tamaya.core.properties.AggregationPolicy}
+     * defines the current variants supported.
+     */
+    @Test
+    public void simpleAggregationTests() {
+        PropertySource props1 = PropertySourceBuilder.of().addPaths("classpath:ucs/UC2CombineProperties/props1.properties").build();
+        PropertySource props2 = PropertySourceBuilder.of().addPaths("classpath:ucs/UC2CombineProperties/props2.properties").build();
+        PropertySource unionOverriding = PropertySourceBuilder.of(props1).withAggregationPolicy(AggregationPolicy.OVERRIDE).addProviders(props2).build();
+        System.out.println("unionOverriding: " + unionOverriding);
+        PropertySource unionIgnoringDuplicates = PropertySourceBuilder.of(props1).withAggregationPolicy(AggregationPolicy.IGNORE_DUPLICATES).addProviders(props2).build();
+        System.out.println("unionIgnoringDuplicates: " + unionIgnoringDuplicates);
+        PropertySource unionCombined = PropertySourceBuilder.of(props1).withAggregationPolicy(AggregationPolicy.COMBINE).addProviders(props2).build();
+        System.out.println("unionCombined: " + unionCombined);
+        try{
+            PropertySourceBuilder.of(props1).withAggregationPolicy(AggregationPolicy.EXCEPTION).addProviders(props2).build();
+        }
+        catch(ConfigException e){
+            // expected!
+        }
+    }
+
+    /**
+     * For advanced use cases aggregation .
+     */
+    @Test
+    public void dynamicAggregationTests() {
+        PropertySource props1 = PropertySourceBuilder.of().addPaths("classpath:ucs/UC2CombineProperties/props1.properties").build();
+        PropertySource props2 = PropertySourceBuilder.of().addPaths("classpath:ucs/UC2CombineProperties/props2.properties").build();
+        PropertySource props = PropertySourceBuilder.of().withAggregationPolicy((k, v1, v2) -> (v1 != null ? v1 : "") + '[' + v2 + "]").withName("dynamicAggregationTests")
+                .aggregate(props1, props2).build();
+        System.out.println(props);
+    }
+
+
+}

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/core/src/test/java/org/apache/tamaya/ucs/deltaspike/ConfigFiltering.java
----------------------------------------------------------------------
diff --git a/dormant/core/src/test/java/org/apache/tamaya/ucs/deltaspike/ConfigFiltering.java b/dormant/core/src/test/java/org/apache/tamaya/ucs/deltaspike/ConfigFiltering.java
new file mode 100644
index 0000000..3269b3c
--- /dev/null
+++ b/dormant/core/src/test/java/org/apache/tamaya/ucs/deltaspike/ConfigFiltering.java
@@ -0,0 +1,60 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you 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 current 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.
+ */
+package org.apache.tamaya.ucs.deltaspike;
+
+import org.apache.tamaya.Configuration;
+import org.apache.tamaya.core.properties.PropertySourceBuilder;
+
+import java.net.URL;
+
+/**
+ * This is one of possible multiple comparisons of Tamaya functionality with Deltapike.
+ * <pre>
+ * A company uses REST endpoints and need to talk to those.
+ * So we need to configure a few things:
+ * 1.) the endpoint URL
+ * 2.) the username which should be used to connect (e.g. over https, BASIC auth, whatever)
+ * 3.) the passphrase which should be used to connect.
+ *
+ * The security credentials (passphrase) should not get stored in plaintext but encrypted using PKI. It should of course also not get logged out in clear text but shall get masked if logging out the configured values is enabled.
+ *
+ * In DeltaSpike I'd just register a ConfigFilter to do the password decoding on the fly.
+ * </pre>
+ */
+public class ConfigFiltering {
+
+    public void scenario1UseAdapter(){
+        URL endPoint = Configuration.current().get("endPointURL", URL.class).get();
+        String uid = Configuration.current().get("endPointURL.user").get();
+//        String pwd = Configuration.current().getAdapted("endPointURL.password", v -> MyPKI.decrypt(v));
+    }
+
+    public void scenario1AddFilterOnSPI(){
+        URL endPoint = Configuration.current().get("endPointURL", URL.class).get();
+        String uid = Configuration.current().get("endPointURL.user").get();
+        String pwd = Configuration.current().get("endPointURL.password").get();
+
+        // In the SPI
+        PropertySourceBuilder.of().addPaths("...").filterValues((k,v) -> k.equals("endPointURL.password")?MyPKI.decrypt(v):v).build();
+    }
+
+    private static class MyPKI{
+        public static String decrypt(String val){return val;};
+    }
+}

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/core/src/test/resources/META-INF/beans.xml
----------------------------------------------------------------------
diff --git a/dormant/core/src/test/resources/META-INF/beans.xml b/dormant/core/src/test/resources/META-INF/beans.xml
new file mode 100644
index 0000000..1d5c20b
--- /dev/null
+++ b/dormant/core/src/test/resources/META-INF/beans.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you 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 current 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.
+-->
+
+<beans xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+       xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://jboss.org/schema/cdi/beans_1_0.xsd">
+
+</beans>
+

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/core/src/test/resources/META-INF/config.properties
----------------------------------------------------------------------
diff --git a/dormant/core/src/test/resources/META-INF/config.properties b/dormant/core/src/test/resources/META-INF/config.properties
new file mode 100644
index 0000000..d7b8927
--- /dev/null
+++ b/dormant/core/src/test/resources/META-INF/config.properties
@@ -0,0 +1,19 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you 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 current 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.
+#
+org.apache.tamaya.environmentOrder=root,system,ear,application
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/core/src/test/resources/META-INF/config/example.ini
----------------------------------------------------------------------
diff --git a/dormant/core/src/test/resources/META-INF/config/example.ini b/dormant/core/src/test/resources/META-INF/config/example.ini
new file mode 100644
index 0000000..95a2b7c
--- /dev/null
+++ b/dormant/core/src/test/resources/META-INF/config/example.ini
@@ -0,0 +1,31 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you 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.
+#
+[persons.anatole]
+prename=Anatole
+name=Tresch
+address=Technoparkstrasse 10
+zip=8070
+location=Zürich
+
+[persons.peter]
+prename=Peter
+name=Fischbach
+address=Hand Platz
+zip=4556
+location=Unterland

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/core/src/test/resources/META-INF/config/example.properties
----------------------------------------------------------------------
diff --git a/dormant/core/src/test/resources/META-INF/config/example.properties b/dormant/core/src/test/resources/META-INF/config/example.properties
new file mode 100644
index 0000000..93d70f9
--- /dev/null
+++ b/dormant/core/src/test/resources/META-INF/config/example.properties
@@ -0,0 +1,31 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you 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 current 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.
+#
+persons=joe,anne
+
+persons.joe.prename=Joe
+persons.joe.name=Foo
+persons.joe.address=15, MyBar Street
+persons.joe.zip=80000
+persons.joe.location=Nowhere
+
+persons.anne.prename=Annemarie
+persons.anne.name=Bar
+persons.anne.address=James Strasse 16a
+persons.anne.zip=1234
+persons.anne.location=Nowhere
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/core/src/test/resources/META-INF/config/example.xml
----------------------------------------------------------------------
diff --git a/dormant/core/src/test/resources/META-INF/config/example.xml b/dormant/core/src/test/resources/META-INF/config/example.xml
new file mode 100644
index 0000000..e3c050a
--- /dev/null
+++ b/dormant/core/src/test/resources/META-INF/config/example.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+#
+# Copyright 2014 Anatole Tresch and other (see authors).
+#
+# you may not use this file except in compliance with the License.
+# You may obtain a copy current 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.
+#
+-->
+<!DOCTYPE properties SYSTEM "http://java.sun.com/dtd/properties.dtd">
+<properties version="1.0">
+    <entry key="persons.gorilla.prename">Bubu</entry>
+    <entry key="persons.gorilla.name">-</entry>
+    <entry key="persons.gorilla.address">Zurich Zoo</entry>
+    <entry key="persons.gorilla.zip">8111</entry>
+    <entry key="persons.gorilla.location">Zurich</entry>
+</properties>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/core/src/test/resources/META-INF/configuration/example.ini
----------------------------------------------------------------------
diff --git a/dormant/core/src/test/resources/META-INF/configuration/example.ini b/dormant/core/src/test/resources/META-INF/configuration/example.ini
new file mode 100644
index 0000000..e2cc979
--- /dev/null
+++ b/dormant/core/src/test/resources/META-INF/configuration/example.ini
@@ -0,0 +1,18 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you 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 current 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.
+ignore=value

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/core/src/test/resources/META-INF/configuration/example.properties
----------------------------------------------------------------------
diff --git a/dormant/core/src/test/resources/META-INF/configuration/example.properties b/dormant/core/src/test/resources/META-INF/configuration/example.properties
new file mode 100644
index 0000000..ed6148f
--- /dev/null
+++ b/dormant/core/src/test/resources/META-INF/configuration/example.properties
@@ -0,0 +1,20 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you 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 current 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.
+country=Brazil
+nacionality=Brazilian
+love=poliana
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/core/src/test/resources/META-INF/configuration/example.xml
----------------------------------------------------------------------
diff --git a/dormant/core/src/test/resources/META-INF/configuration/example.xml b/dormant/core/src/test/resources/META-INF/configuration/example.xml
new file mode 100644
index 0000000..6a3694a
--- /dev/null
+++ b/dormant/core/src/test/resources/META-INF/configuration/example.xml
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+#
+# Copyright 2014 Anatole Tresch and other (see authors).
+#
+# you may not use this file except in compliance with the License.
+# You may obtain a copy current 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.
+#
+-->
+<!DOCTYPE properties SYSTEM "http://java.sun.com/dtd/properties.dtd">
+<properties version="1.0">
+    <entry key="twitter.otavio">otaviojava</entry>
+    <entry key="team">Bahia</entry>
+    <entry key="sport">Soccer</entry>
+</properties>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/core/src/test/resources/META-INF/env/application.properties
----------------------------------------------------------------------
diff --git a/dormant/core/src/test/resources/META-INF/env/application.properties b/dormant/core/src/test/resources/META-INF/env/application.properties
new file mode 100644
index 0000000..fa9c3a7
--- /dev/null
+++ b/dormant/core/src/test/resources/META-INF/env/application.properties
@@ -0,0 +1,19 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you 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 current 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.
+#
+environment.applicationId=MyApp1
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/core/src/test/resources/META-INF/env/ear.ini
----------------------------------------------------------------------
diff --git a/dormant/core/src/test/resources/META-INF/env/ear.ini b/dormant/core/src/test/resources/META-INF/env/ear.ini
new file mode 100644
index 0000000..eb72fd4
--- /dev/null
+++ b/dormant/core/src/test/resources/META-INF/env/ear.ini
@@ -0,0 +1,20 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you 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.
+#
+[environment]
+earId=myEar1
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/core/src/test/resources/META-INF/env/system.properties
----------------------------------------------------------------------
diff --git a/dormant/core/src/test/resources/META-INF/env/system.properties b/dormant/core/src/test/resources/META-INF/env/system.properties
new file mode 100644
index 0000000..c471a3c
--- /dev/null
+++ b/dormant/core/src/test/resources/META-INF/env/system.properties
@@ -0,0 +1,19 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you 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 current 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.
+#
+systemId=test
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/core/src/test/resources/META-INF/meta-model.properties
----------------------------------------------------------------------
diff --git a/dormant/core/src/test/resources/META-INF/meta-model.properties b/dormant/core/src/test/resources/META-INF/meta-model.properties
new file mode 100644
index 0000000..f3199f2
--- /dev/null
+++ b/dormant/core/src/test/resources/META-INF/meta-model.properties
@@ -0,0 +1,18 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you 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 current 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.
+#

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/core/src/test/resources/META-INF/services/org.apache.tamaya.core.spi.ConfigurationProviderSpi
----------------------------------------------------------------------
diff --git a/dormant/core/src/test/resources/META-INF/services/org.apache.tamaya.core.spi.ConfigurationProviderSpi b/dormant/core/src/test/resources/META-INF/services/org.apache.tamaya.core.spi.ConfigurationProviderSpi
new file mode 100644
index 0000000..c4ba801
--- /dev/null
+++ b/dormant/core/src/test/resources/META-INF/services/org.apache.tamaya.core.spi.ConfigurationProviderSpi
@@ -0,0 +1,19 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you 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 current 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.
+#
+org.apache.tamaya.internal.TestConfigProvider
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/core/src/test/resources/META-INF/services/org.apache.tamaya.core.spi.EnvironmentProvider
----------------------------------------------------------------------
diff --git a/dormant/core/src/test/resources/META-INF/services/org.apache.tamaya.core.spi.EnvironmentProvider b/dormant/core/src/test/resources/META-INF/services/org.apache.tamaya.core.spi.EnvironmentProvider
new file mode 100644
index 0000000..74382e7
--- /dev/null
+++ b/dormant/core/src/test/resources/META-INF/services/org.apache.tamaya.core.spi.EnvironmentProvider
@@ -0,0 +1,19 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you 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 current 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.
+#
+org.apache.tamaya.metamodel.environment.TestEnvironmentProvider
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/core/src/test/resources/cfg/autoloaded.xml
----------------------------------------------------------------------
diff --git a/dormant/core/src/test/resources/cfg/autoloaded.xml b/dormant/core/src/test/resources/cfg/autoloaded.xml
new file mode 100644
index 0000000..b64cb76
--- /dev/null
+++ b/dormant/core/src/test/resources/cfg/autoloaded.xml
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you 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 current 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.
+-->
+<!DOCTYPE properties SYSTEM "http://java.sun.com/dtd/properties.dtd">
+<properties version="1.0">
+	<entry key="testFromXml">testValue</entry>
+    <entry key="b">Bill</entry>
+    <entry key="a.compound.area.entry">myCompundAreaVlaueFromXml</entry>
+    <entry key="an.area.entry">myCompundAreaVlaueFromXml2</entry>
+    <!-- DirectMapping test -->
+    <entry key="org.apache.tamaya.samples.annotations.AutoConfiguredClass.value1">This \${JAVA_HOME} is cool!</entry>
+    <entry key="org.apache.tamaya.samples.annotations.AutoConfiguredClass.value2">Should not be set because @NoConfig !</entry>
+    <entry key="org.apache.tamaya.samples.annotations.AutoConfiguredClass.testProperty">a test property value</entry>
+    <entry key="org.apache.tamaya.samples.annotations.AutoConfiguredClass.runtimeVersion">my RT 1-0-0--build-1234</entry>
+    <entry key="org.apache.tamaya.samples.annotations.AutoConfiguredClass.int1">1</entry>
+    <entry key="org.apache.tamaya.samples.annotations.AutoConfiguredClass.int2">22</entry>
+</properties>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/core/src/test/resources/cfg/test.xml
----------------------------------------------------------------------
diff --git a/dormant/core/src/test/resources/cfg/test.xml b/dormant/core/src/test/resources/cfg/test.xml
new file mode 100644
index 0000000..b64cb76
--- /dev/null
+++ b/dormant/core/src/test/resources/cfg/test.xml
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you 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 current 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.
+-->
+<!DOCTYPE properties SYSTEM "http://java.sun.com/dtd/properties.dtd">
+<properties version="1.0">
+	<entry key="testFromXml">testValue</entry>
+    <entry key="b">Bill</entry>
+    <entry key="a.compound.area.entry">myCompundAreaVlaueFromXml</entry>
+    <entry key="an.area.entry">myCompundAreaVlaueFromXml2</entry>
+    <!-- DirectMapping test -->
+    <entry key="org.apache.tamaya.samples.annotations.AutoConfiguredClass.value1">This \${JAVA_HOME} is cool!</entry>
+    <entry key="org.apache.tamaya.samples.annotations.AutoConfiguredClass.value2">Should not be set because @NoConfig !</entry>
+    <entry key="org.apache.tamaya.samples.annotations.AutoConfiguredClass.testProperty">a test property value</entry>
+    <entry key="org.apache.tamaya.samples.annotations.AutoConfiguredClass.runtimeVersion">my RT 1-0-0--build-1234</entry>
+    <entry key="org.apache.tamaya.samples.annotations.AutoConfiguredClass.int1">1</entry>
+    <entry key="org.apache.tamaya.samples.annotations.AutoConfiguredClass.int2">22</entry>
+</properties>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/core/src/test/resources/test.properties
----------------------------------------------------------------------
diff --git a/dormant/core/src/test/resources/test.properties b/dormant/core/src/test/resources/test.properties
new file mode 100644
index 0000000..6798ad9
--- /dev/null
+++ b/dormant/core/src/test/resources/test.properties
@@ -0,0 +1,27 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you 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 current 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.
+#
+a=Anatole
+b=Bj�rn
+c=Charles
+d=Dani
+e=Eduard
+f=Fane
+g=Gil
+another.compound.area.entry=thisTimeFromProperties...
+another.area.entry=thisTimeFromProperties2...
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/core/src/test/resources/ucs/UC1ReadProperties/UC1ReadPropertiesTest.ini
----------------------------------------------------------------------
diff --git a/dormant/core/src/test/resources/ucs/UC1ReadProperties/UC1ReadPropertiesTest.ini b/dormant/core/src/test/resources/ucs/UC1ReadProperties/UC1ReadPropertiesTest.ini
new file mode 100644
index 0000000..6f4301b
--- /dev/null
+++ b/dormant/core/src/test/resources/ucs/UC1ReadProperties/UC1ReadPropertiesTest.ini
@@ -0,0 +1,41 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you 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 current 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.
+#
+[a.b]
+c=abcValue-fromIni
+a=abaValue-fromIni
+b=abbValue-fromIni
+
+[mixed]
+a.b=abValue
+a.a.a=aaaValue
+b.b.b=bbbValue
+c.c.c=cccValue
+
+[num]
+Int=123
+Byte=100
+BD=2376523725372653.287362836283628362863
+Double=21334.43254
+
+[other]
+boolean=true
+a=aValue
+b=bValue
+c=cValue
+numInt=9999s

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/core/src/test/resources/ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties
----------------------------------------------------------------------
diff --git a/dormant/core/src/test/resources/ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties b/dormant/core/src/test/resources/ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties
new file mode 100644
index 0000000..2b19362
--- /dev/null
+++ b/dormant/core/src/test/resources/ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties
@@ -0,0 +1,34 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you 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 current 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.
+#
+a=aValue
+b=bValue
+c=cValue
+a.b.c=abcValue
+a.b.a=abaValue
+a.b.b=abbValue
+a.b=abValue
+a.a.a=aaaValue
+b.b.b=bbbValue
+c.c.c=cccValue
+numInt=9999
+num.Int=123
+num.Byte=100
+boolean=true
+num.BD=2376523725372653.287362836283628362863
+num.Double=21334.43254

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/core/src/test/resources/ucs/UC1ReadProperties/UC1ReadPropertiesTest.xml
----------------------------------------------------------------------
diff --git a/dormant/core/src/test/resources/ucs/UC1ReadProperties/UC1ReadPropertiesTest.xml b/dormant/core/src/test/resources/ucs/UC1ReadProperties/UC1ReadPropertiesTest.xml
new file mode 100644
index 0000000..535134f
--- /dev/null
+++ b/dormant/core/src/test/resources/ucs/UC1ReadProperties/UC1ReadPropertiesTest.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you 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 current 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.
+-->
+<!DOCTYPE properties SYSTEM "http://java.sun.com/dtd/properties.dtd">
+<properties version="1.0">
+	<entry key="a-xml">aFromXml</entry>
+    <entry key="b-xml">bFromXml</entry>
+    <entry key="a.b.c-xml">abcFromXml</entry>
+</properties>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/core/src/test/resources/ucs/UC2CombineProperties/props1.properties
----------------------------------------------------------------------
diff --git a/dormant/core/src/test/resources/ucs/UC2CombineProperties/props1.properties b/dormant/core/src/test/resources/ucs/UC2CombineProperties/props1.properties
new file mode 100644
index 0000000..a7590ae
--- /dev/null
+++ b/dormant/core/src/test/resources/ucs/UC2CombineProperties/props1.properties
@@ -0,0 +1,24 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you 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 current 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.
+#
+a=a
+b=b
+c=c
+g=g
+h=h
+i=i

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/core/src/test/resources/ucs/UC2CombineProperties/props2.properties
----------------------------------------------------------------------
diff --git a/dormant/core/src/test/resources/ucs/UC2CombineProperties/props2.properties b/dormant/core/src/test/resources/ucs/UC2CombineProperties/props2.properties
new file mode 100644
index 0000000..692ced3
--- /dev/null
+++ b/dormant/core/src/test/resources/ucs/UC2CombineProperties/props2.properties
@@ -0,0 +1,24 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you 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 current 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.
+#
+a=A
+b=B
+c=C
+d=D
+e=E
+f=F

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/modules/integration/cdi/pom.xml
----------------------------------------------------------------------
diff --git a/dormant/modules/integration/cdi/pom.xml b/dormant/modules/integration/cdi/pom.xml
new file mode 100644
index 0000000..1909bcc
--- /dev/null
+++ b/dormant/modules/integration/cdi/pom.xml
@@ -0,0 +1,178 @@
+<!-- 
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you 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 current 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.
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+    <modelVersion>4.0.0</modelVersion>
+
+    <parent>
+        <groupId>org.apache.tamaya.integration</groupId>
+        <artifactId>tamaya-integration-all</artifactId>
+        <version>0.1-SNAPSHOT</version>
+        <relativePath>..</relativePath>
+    </parent>
+    <artifactId>tamaya-cdi</artifactId>
+    <name>Apache Tamaya Modules Integration - CDI</name>
+    <packaging>jar</packaging>
+
+    <properties>
+        <owb.version>1.5.0-SNAPSHOT</owb.version>
+        <weld.version>2.2.7.Final</weld.version>
+        <geronimo-jcdi-1.1-spec.version>1.0-SNAPSHOT</geronimo-jcdi-1.1-spec.version>
+        <geronimo-interceptor-1.2-spec.version>1.0-SNAPSHOT</geronimo-interceptor-1.2-spec.version>
+        <geronimo-atinject-1.0-spec.version>1.0</geronimo-atinject-1.0-spec.version>
+        <bval.version>0.5</bval.version>
+        <ds.version>1.1.0</ds.version>
+    </properties>
+
+    <build>
+        <plugins>
+            <plugin>
+                <groupId>org.jacoco</groupId>
+                <artifactId>jacoco-maven-plugin</artifactId>
+                <executions>
+                    <execution>
+                        <id>prepare-agent</id>
+                        <goals>
+                            <goal>prepare-agent</goal>
+                        </goals>
+                    </execution>
+                </executions>
+            </plugin>
+        </plugins>
+    </build>
+    <dependencies>
+        <dependency>
+            <groupId>junit</groupId>
+            <artifactId>junit</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.hamcrest</groupId>
+            <artifactId>hamcrest-library</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.hamcrest</groupId>
+            <artifactId>hamcrest-core</artifactId>
+            <scope>test</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>org.apache.tamaya</groupId>
+            <artifactId>tamaya-core</artifactId>
+            <version>${project.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.geronimo.specs</groupId>
+            <artifactId>geronimo-jcdi_1.1_spec</artifactId>
+            <version>${geronimo-jcdi-1.1-spec.version}</version>
+            <scope>provided</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.deltaspike.modules</groupId>
+            <artifactId>deltaspike-test-control-module-api</artifactId>
+            <version>${ds.version}</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.deltaspike.modules</groupId>
+            <artifactId>deltaspike-test-control-module-impl</artifactId>
+            <version>${ds.version}</version>
+            <scope>test</scope>
+        </dependency>
+    </dependencies>
+    <profiles>
+        <profile>
+            <id>OWB</id>
+            <activation>
+                <activeByDefault>true</activeByDefault>
+            </activation>
+            <dependencies>
+                <!-- OWB specific dependencies-->
+                <dependency>
+                    <groupId>org.apache.geronimo.specs</groupId>
+                    <artifactId>geronimo-atinject_1.0_spec</artifactId>
+                    <version>${geronimo-atinject-1.0-spec.version}</version>
+                </dependency>
+                <dependency>
+                    <groupId>org.apache.geronimo.specs</groupId>
+                    <artifactId>geronimo-interceptor_1.2_spec</artifactId>
+                    <version>${geronimo-interceptor-1.2-spec.version}</version>
+                    <scope>provided</scope>
+                </dependency>
+                <dependency>
+                    <groupId>org.apache.geronimo.specs</groupId>
+                    <artifactId>geronimo-annotation_1.2_spec</artifactId>
+                    <version>1.0.MR2-SNAPSHOT</version>
+                    <scope>provided</scope>
+                </dependency>
+                <dependency>
+                    <groupId>org.apache.geronimo.specs</groupId>
+                    <artifactId>geronimo-el_2.2_spec</artifactId>
+                    <version>1.0.2</version>
+                </dependency>
+
+                <dependency>
+                    <groupId>org.apache.openwebbeans</groupId>
+                    <artifactId>openwebbeans-impl</artifactId>
+                    <version>${owb.version}</version>
+                </dependency>
+                <dependency>
+                    <groupId>org.apache.openwebbeans</groupId>
+                    <artifactId>openwebbeans-spi</artifactId>
+                    <version>${owb.version}</version>
+                </dependency>
+                <dependency>
+                    <groupId>org.apache.openwebbeans</groupId>
+                    <artifactId>openwebbeans-resource</artifactId>
+                    <version>${owb.version}</version>
+                </dependency>
+
+                <dependency>
+                    <groupId>org.apache.bval</groupId>
+                    <artifactId>bval-jsr303</artifactId>
+                    <version>${bval.version}</version>
+                    <scope>test</scope>
+                </dependency>
+                <dependency>
+                    <groupId>org.apache.deltaspike.cdictrl</groupId>
+                    <artifactId>deltaspike-cdictrl-owb</artifactId>
+                    <version>${ds.version}</version>
+                    <scope>test</scope>
+                </dependency>
+            </dependencies>
+        </profile>
+        <profile>
+            <id>Weld</id>
+            <dependencies>
+                <dependency>
+                    <groupId>org.jboss.weld.se</groupId>
+                    <artifactId>weld-se</artifactId>
+                    <version>${weld.version}</version>
+                </dependency>
+                <dependency>
+                    <groupId>org.apache.deltaspike.cdictrl</groupId>
+                    <artifactId>deltaspike-cdictrl-weld</artifactId>
+                    <version>${ds.version}</version>
+                    <scope>test</scope>
+                </dependency>
+            </dependencies>
+        </profile>
+    </profiles>
+</project>

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/modules/integration/cdi/src/main/java/org/apache/tamaya/integration/cdi/ConfigurationExtension.java
----------------------------------------------------------------------
diff --git a/dormant/modules/integration/cdi/src/main/java/org/apache/tamaya/integration/cdi/ConfigurationExtension.java b/dormant/modules/integration/cdi/src/main/java/org/apache/tamaya/integration/cdi/ConfigurationExtension.java
new file mode 100644
index 0000000..4f66e51
--- /dev/null
+++ b/dormant/modules/integration/cdi/src/main/java/org/apache/tamaya/integration/cdi/ConfigurationExtension.java
@@ -0,0 +1,81 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you 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.
+ */
+package org.apache.tamaya.integration.cdi;
+
+import org.apache.tamaya.core.internal.inject.ConfigurationInjector;
+import org.apache.tamaya.core.internal.inject.ConfiguredType;
+
+import javax.enterprise.context.spi.CreationalContext;
+import javax.enterprise.event.Observes;
+import javax.enterprise.inject.Vetoed;
+import javax.enterprise.inject.spi.*;
+import java.util.*;
+
+/**
+ * CDI portable extension that integrates {@link org.apache.tamaya.core.internal.inject.ConfigurationInjector}
+ * with CDI by adding configuration features to CDI (config enable CDI beans).
+ */
+@Vetoed
+public final class ConfigurationExtension implements Extension {
+
+    public <T> void initializeConfiguredFields(final @Observes ProcessInjectionTarget<T> pit) {
+        final AnnotatedType<T> at = pit.getAnnotatedType();
+        if (!ConfiguredType.isConfigured(at.getJavaClass())) {
+            return;
+        }
+//        final ConfiguredType configuredType = ConfigurationInjector.registerType(at.getJavaClass());
+
+        final InjectionTarget<T> it = pit.getInjectionTarget();
+        InjectionTarget<T> wrapped = new InjectionTarget<T>() {
+            @Override
+            public void inject(T instance, CreationalContext<T> ctx) {
+                it.inject(instance, ctx);
+                ConfigurationInjector.configure(instance);
+            }
+
+            @Override
+            public void postConstruct(T instance) {
+                it.postConstruct(instance);
+            }
+
+            @Override
+            public void preDestroy(T instance) {
+                it.dispose(instance);
+            }
+
+            @Override
+            public void dispose(T instance) {
+                it.dispose(instance);
+            }
+
+            @Override
+            public Set<InjectionPoint> getInjectionPoints() {
+                return it.getInjectionPoints();
+            }
+
+            @Override
+            public T produce(CreationalContext<T> ctx) {
+                return it.produce(ctx);
+            }
+        };
+        pit.setInjectionTarget(wrapped);
+    }
+
+
+}

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/modules/integration/cdi/src/main/resources/META-INF/beans.xml
----------------------------------------------------------------------
diff --git a/dormant/modules/integration/cdi/src/main/resources/META-INF/beans.xml b/dormant/modules/integration/cdi/src/main/resources/META-INF/beans.xml
new file mode 100644
index 0000000..adee378
--- /dev/null
+++ b/dormant/modules/integration/cdi/src/main/resources/META-INF/beans.xml
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you 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 current 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.
+-->
+<beans xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+       xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://jboss.org/schema/cdi/beans_1_0.xsd">
+
+</beans>
+

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/modules/integration/cdi/src/main/resources/META-INF/services/javax.enterprise.inject.spi.Extension
----------------------------------------------------------------------
diff --git a/dormant/modules/integration/cdi/src/main/resources/META-INF/services/javax.enterprise.inject.spi.Extension b/dormant/modules/integration/cdi/src/main/resources/META-INF/services/javax.enterprise.inject.spi.Extension
new file mode 100644
index 0000000..2249aca
--- /dev/null
+++ b/dormant/modules/integration/cdi/src/main/resources/META-INF/services/javax.enterprise.inject.spi.Extension
@@ -0,0 +1,19 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you 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 current 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.
+#
+org.apache.tamaya.integration.cdi.ConfigurationExtension

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/modules/integration/cdi/src/test/java/org/apache/tamaya/integration/cdi/ConfiguredClass.java
----------------------------------------------------------------------
diff --git a/dormant/modules/integration/cdi/src/test/java/org/apache/tamaya/integration/cdi/ConfiguredClass.java b/dormant/modules/integration/cdi/src/test/java/org/apache/tamaya/integration/cdi/ConfiguredClass.java
new file mode 100644
index 0000000..ea47dd6
--- /dev/null
+++ b/dormant/modules/integration/cdi/src/test/java/org/apache/tamaya/integration/cdi/ConfiguredClass.java
@@ -0,0 +1,133 @@
+/*
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you 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 current 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.
+ *
+ */
+package org.apache.tamaya.integration.cdi;
+
+import java.beans.PropertyChangeEvent;
+import java.math.BigDecimal;
+
+import javax.inject.Singleton;
+
+import org.apache.tamaya.annotation.ConfiguredProperty;
+import org.apache.tamaya.annotation.DefaultValue;
+import org.apache.tamaya.annotation.ObservesConfigChange;
+
+/**
+ * Created by Anatole on 08.09.2014.
+ */
+@Singleton
+public class ConfiguredClass{
+
+//    @WithConfig("test")
+    @ConfiguredProperty
+    private String testProperty;
+
+    @ConfiguredProperty(keys = "a.b.c.key1")
+    @ConfiguredProperty(keys = "a.b.c.key2")
+    @ConfiguredProperty(keys = "a.b.c.key3")
+    @DefaultValue("The current \\${JAVA_HOME} env property is ${env:JAVA_HOME}.")
+    String value1;
+
+//    @WithConfig("test")
+    @ConfiguredProperty(keys = "foo")
+    @ConfiguredProperty(keys = "a.b.c.key2")
+    private String value2;
+
+    @ConfiguredProperty
+    @DefaultValue("N/A")
+    private String runtimeVersion;
+
+    @ConfiguredProperty
+    @DefaultValue("${sys:java.version}")
+    private String javaVersion2;
+
+    @ConfiguredProperty
+    @DefaultValue("5")
+    private Integer int1;
+
+//    @WithConfig("test")
+    @ConfiguredProperty
+    private int int2;
+
+//    @WithConfig("test")
+    @ConfiguredProperty
+    private boolean booleanT;
+
+//    @WithConfig("test")
+    @ConfiguredProperty(keys = "BD")
+    private BigDecimal bigNumber;
+
+//    @WithConfig("test")
+    @ConfiguredProperty(keys = "double1")
+    private double doubleValue;
+
+    @ObservesConfigChange
+    public void changeListener1(PropertyChangeEvent configChange){
+        // will be called
+    }
+
+    public String getTestProperty() {
+        return testProperty;
+    }
+
+    public String getValue1() {
+        return value1;
+    }
+
+    public String getValue2() {
+        return value2;
+    }
+
+    public String getRuntimeVersion() {
+        return runtimeVersion;
+    }
+
+    public String getJavaVersion2() {
+        return javaVersion2;
+    }
+
+    public Integer getInt1() {
+        return int1;
+    }
+
+    public int getInt2() {
+        return int2;
+    }
+
+    public boolean isBooleanT() {
+        return booleanT;
+    }
+
+    public BigDecimal getBigNumber() {
+        return bigNumber;
+    }
+
+    public double getDoubleValue() {
+        return doubleValue;
+    }
+
+    @Override
+	public String toString(){
+        return super.toString() + ": testProperty="+testProperty+", value1="+value1+", value2="+value2
+                +", int1="+int1+", int2="+int2+", booleanT="+booleanT+", bigNumber="+bigNumber
+                +", runtimeVersion="+runtimeVersion+", javaVersion2="+javaVersion2;
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/modules/integration/cdi/src/test/java/org/apache/tamaya/integration/cdi/ConfiguredTest.java
----------------------------------------------------------------------
diff --git a/dormant/modules/integration/cdi/src/test/java/org/apache/tamaya/integration/cdi/ConfiguredTest.java b/dormant/modules/integration/cdi/src/test/java/org/apache/tamaya/integration/cdi/ConfiguredTest.java
new file mode 100644
index 0000000..376df10
--- /dev/null
+++ b/dormant/modules/integration/cdi/src/test/java/org/apache/tamaya/integration/cdi/ConfiguredTest.java
@@ -0,0 +1,52 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you 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 current 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.
+ *
+ */
+
+package org.apache.tamaya.integration.cdi;
+
+import org.apache.deltaspike.testcontrol.api.junit.CdiTestRunner;
+import org.hamcrest.MatcherAssert;
+import org.junit.Ignore;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+
+import javax.enterprise.inject.spi.CDI;
+
+import static org.hamcrest.core.Is.is;
+
+/**
+ * Created by Anatole on 08.09.2014.
+ */
+@RunWith(CdiTestRunner.class)
+public class ConfiguredTest{
+
+    @Ignore
+    @Test
+    public void testInjection(){
+        ConfiguredClass item = CDI.current().select(ConfiguredClass.class).get();
+        System.out.println("********************************************");
+        System.out.println(item);
+        System.out.println("********************************************");
+
+        double actual = 1234.5678;
+
+        MatcherAssert.assertThat(item.getDoubleValue(), is(actual));
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/modules/integration/cdi/src/test/java/org/apache/tamaya/integration/cdi/TestConfigProvider.java
----------------------------------------------------------------------
diff --git a/dormant/modules/integration/cdi/src/test/java/org/apache/tamaya/integration/cdi/TestConfigProvider.java b/dormant/modules/integration/cdi/src/test/java/org/apache/tamaya/integration/cdi/TestConfigProvider.java
new file mode 100644
index 0000000..a0de005
--- /dev/null
+++ b/dormant/modules/integration/cdi/src/test/java/org/apache/tamaya/integration/cdi/TestConfigProvider.java
@@ -0,0 +1,69 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you 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 current 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.
+ */
+package org.apache.tamaya.integration.cdi;
+
+import org.apache.tamaya.Configuration;
+import org.apache.tamaya.core.properties.PropertySourceBuilder;
+import org.apache.tamaya.core.spi.ConfigurationProviderSpi;
+
+import java.util.HashMap;
+import java.util.Map;
+
+/**
+ * Created by Anatole on 29.09.2014.
+ */
+public class TestConfigProvider implements ConfigurationProviderSpi
+{
+
+    private Configuration testConfig;
+
+    public TestConfigProvider(){
+        final Map<String,String> config = new HashMap<>();
+        config.put("a.b.c.key1", "keys current a.b.c.key1");
+        config.put("a.b.c.key2", "keys current a.b.c.key2");
+        config.put("a.b.key3", "keys current a.b.key3");
+        config.put("a.b.key4", "keys current a.b.key4");
+        config.put("a.key5", "keys current a.key5");
+        config.put("a.key6", "keys current a.key6");
+        config.put("int1", "123456");
+        config.put("int2", "111222");
+        config.put("testProperty", "testPropertyValue!");
+        config.put("booleanT", "true");
+        config.put("double1", "1234.5678");
+        config.put("BD", "123456789123456789123456789123456789.123456789123456789123456789123456789");
+        config.put("testProperty", "keys current testProperty");
+        config.put("runtimeVersion", "${java.version}");
+        testConfig = PropertySourceBuilder.of("test").addMap(config).build().toConfiguration();
+    }
+
+    @Override
+    public String getConfigName(){
+        return "test";
+    }
+
+    @Override
+    public Configuration getConfiguration(){
+        return testConfig;
+    }
+
+    @Override
+    public void reload() {
+
+    }
+}

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/d9964c64/dormant/modules/integration/cdi/src/test/resources/META-INF/beans.xml
----------------------------------------------------------------------
diff --git a/dormant/modules/integration/cdi/src/test/resources/META-INF/beans.xml b/dormant/modules/integration/cdi/src/test/resources/META-INF/beans.xml
new file mode 100644
index 0000000..adee378
--- /dev/null
+++ b/dormant/modules/integration/cdi/src/test/resources/META-INF/beans.xml
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you 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 current 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.
+-->
+<beans xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+       xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://jboss.org/schema/cdi/beans_1_0.xsd">
+
+</beans>
+