tamaya-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From anat...@apache.org
Subject [2/5] incubator-tamaya git commit: TAMAYA-116: Fixed NPE and test issues (using Weld by default, instead of OWB).
Date Tue, 13 Oct 2015 01:11:44 GMT
TAMAYA-116: Fixed NPE and test issues (using Weld by default, instead of OWB).


Project: http://git-wip-us.apache.org/repos/asf/incubator-tamaya/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-tamaya/commit/88c99a10
Tree: http://git-wip-us.apache.org/repos/asf/incubator-tamaya/tree/88c99a10
Diff: http://git-wip-us.apache.org/repos/asf/incubator-tamaya/diff/88c99a10

Branch: refs/heads/master
Commit: 88c99a10686da96aff5d101a2c2d99c0fafc8269
Parents: 1e84361
Author: anatole <anatole@apache.org>
Authored: Tue Oct 13 01:23:42 2015 +0200
Committer: anatole <anatole@apache.org>
Committed: Tue Oct 13 01:23:42 2015 +0200

----------------------------------------------------------------------
 modules/integration/cdi/pom.xml                       | 14 +++++++++-----
 .../integration/cdi/ConfigurationExtension.java       |  4 +++-
 .../tamaya/integration/cdi/ConfigurationProducer.java |  4 +++-
 3 files changed, 15 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/88c99a10/modules/integration/cdi/pom.xml
----------------------------------------------------------------------
diff --git a/modules/integration/cdi/pom.xml b/modules/integration/cdi/pom.xml
index a5206d0..2ebcc6b 100644
--- a/modules/integration/cdi/pom.xml
+++ b/modules/integration/cdi/pom.xml
@@ -129,9 +129,9 @@ under the License.
     <profiles>
         <profile>
             <id>OWB</id>
-            <activation>
-                <activeByDefault>true</activeByDefault>
-            </activation>
+            <!-- there is an issue with this profile:
+                 java.lang.NoClassDefFoundError: org/apache/webbeans/event/EventMetadata
+            -->
             <dependencies>
                 <!-- OWB specific dependencies-->
                 <dependency>
@@ -143,13 +143,13 @@ under the License.
                     <groupId>org.apache.geronimo.specs</groupId>
                     <artifactId>geronimo-interceptor_1.2_spec</artifactId>
                     <version>${geronimo-interceptor-1.2-spec.version}</version>
-                    <scope>provided</scope>
+                    <scope>test</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>
+                    <scope>test</scope>
                 </dependency>
                 <dependency>
                     <groupId>org.apache.geronimo.specs</groupId>
@@ -189,11 +189,15 @@ under the License.
         </profile>
         <profile>
             <id>Weld</id>
+            <activation>
+                <activeByDefault>true</activeByDefault>
+            </activation>
             <dependencies>
                 <dependency>
                     <groupId>org.jboss.weld.se</groupId>
                     <artifactId>weld-se</artifactId>
                     <version>${weld.version}</version>
+                    <scope>test</scope>
                 </dependency>
                 <dependency>
                     <groupId>org.apache.deltaspike.cdictrl</groupId>

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/88c99a10/modules/integration/cdi/src/main/java/org/apache/tamaya/integration/cdi/ConfigurationExtension.java
----------------------------------------------------------------------
diff --git a/modules/integration/cdi/src/main/java/org/apache/tamaya/integration/cdi/ConfigurationExtension.java
b/modules/integration/cdi/src/main/java/org/apache/tamaya/integration/cdi/ConfigurationExtension.java
index 65e0433..b421cbc 100644
--- a/modules/integration/cdi/src/main/java/org/apache/tamaya/integration/cdi/ConfigurationExtension.java
+++ b/modules/integration/cdi/src/main/java/org/apache/tamaya/integration/cdi/ConfigurationExtension.java
@@ -141,7 +141,9 @@ public class ConfigurationExtension implements Extension {
                 final ConfigProperty annotation = injectionPoint.getAnnotated().getAnnotation(ConfigProperty.class);
                 final ConfigDefault defaultAnnot = injectionPoint.getAnnotated().getAnnotation(ConfigDefault.class);
                 final ConfigDefaultSections typeAnnot = injectionPoint.getAnnotated().getAnnotation(ConfigDefaultSections.class);
-                final List<String> keys = evaluateKeys(injectionPoint.getMember().getName(),
annotation.value(), typeAnnot.value());
+                final List<String> keys = evaluateKeys(injectionPoint.getMember().getName(),
+                        annotation!=null?annotation.value():null,
+                        typeAnnot!=null?typeAnnot.value():null);
 
                 final WithConfigOperator withOperatorAnnot = injectionPoint.getAnnotated().getAnnotation(WithConfigOperator.class);
                 if(withOperatorAnnot!=null){

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/88c99a10/modules/integration/cdi/src/main/java/org/apache/tamaya/integration/cdi/ConfigurationProducer.java
----------------------------------------------------------------------
diff --git a/modules/integration/cdi/src/main/java/org/apache/tamaya/integration/cdi/ConfigurationProducer.java
b/modules/integration/cdi/src/main/java/org/apache/tamaya/integration/cdi/ConfigurationProducer.java
index c537df3..9e18a3a 100644
--- a/modules/integration/cdi/src/main/java/org/apache/tamaya/integration/cdi/ConfigurationProducer.java
+++ b/modules/integration/cdi/src/main/java/org/apache/tamaya/integration/cdi/ConfigurationProducer.java
@@ -45,7 +45,9 @@ public class ConfigurationProducer {
         final ConfigProperty annotation = injectionPoint.getAnnotated().getAnnotation(ConfigProperty.class);
         final ConfigDefault defaultAnnot = injectionPoint.getAnnotated().getAnnotation(ConfigDefault.class);
         final ConfigDefaultSections typeAnnot = injectionPoint.getAnnotated().getAnnotation(ConfigDefaultSections.class);
-        final List<String> keys = ConfigurationExtension.evaluateKeys(injectionPoint.getMember().getName(),
annotation.value(), typeAnnot.value());
+        final List<String> keys = ConfigurationExtension.evaluateKeys(injectionPoint.getMember().getName(),
+                annotation!=null?annotation.value():null,
+                typeAnnot!=null?typeAnnot.value():null);
 
         final WithConfigOperator withOperatorAnnot = injectionPoint.getAnnotated().getAnnotation(WithConfigOperator.class);
         ConfigOperator operator = null;


Mime
View raw message