Weld SVN: r4111 - core/trunk/osgi-bundle.
by weld-commits@lists.jboss.org
Author: pete.muir(a)jboss.org
Date: 2009-10-15 10:05:06 -0400 (Thu, 15 Oct 2009)
New Revision: 4111
Modified:
core/trunk/osgi-bundle/pom.xml
Log:
Fix OSGi pom
Modified: core/trunk/osgi-bundle/pom.xml
===================================================================
--- core/trunk/osgi-bundle/pom.xml 2009-10-15 13:52:09 UTC (rev 4110)
+++ core/trunk/osgi-bundle/pom.xml 2009-10-15 14:05:06 UTC (rev 4111)
@@ -57,25 +57,42 @@
<_include>-osgi.bundle</_include>
<Embed-Dependency>*; scope=compile; inline=true</Embed-Dependency>
- <_exportcontents>javax.decorator;
- javax.enterprise.*; version=${osgi.version},
- org.jboss.weld.context; org.jboss.weld.ejb;
- org.jboss.weld.bean; org.jboss.weld.bean.proxy;
- org.jboss.weld.*.api.*; org.jboss.weld.*.spi.*;
- org.jboss.weld.conversation; org.jboss.weld;
+
+ <_exportcontents>
+ javax.inject;
+ javax.enterprise.*;
+ version=${osgi.version},
+ org.jboss.weld.context;
+ org.jboss.weld.ejb;
+ org.jboss.weld.bean;
+ org.jboss.weld.bean.proxy;
+ org.jboss.weld.*.api.*;
+ org.jboss.weld.*.spi.*;
+ org.jboss.weld.conversation;
+ org.jboss.weld;
org.jboss.weld.bootstrap;
org.jboss.weld.introspector;
- org.jboss.weld.servlet; version=${osgi.version},
- org.jboss.weld.el; version=${osgi.version},
- org.jboss.weld.jsf; include:="WeldPhaseListener";
+ org.jboss.weld.servlet;
version=${osgi.version},
+ org.jboss.weld.el;
+ version=${osgi.version},
+ org.jboss.weld.jsf;
+ include:="WeldPhaseListener";
+ version=${osgi.version},
javassist.util.proxy;version="3.8.1.GA"
- </_exportcontents>
- <Import-Package>javax.annotation, javax.interceptor,
- *;resolution:=optional</Import-Package>
- <Private-Package>!javax.annotation.*,
- !javax.interceptor.*</Private-Package>
+ </_exportcontents>
+
+ <Import-Package>
+ javax.interceptor.*, *;
+ resolution:=optional
+ </Import-Package>
+
+ <Private-Package>
+ !javax.interceptor.*
+ </Private-Package>
+
</instructions>
+
<!--
Maven uses the output directory (target/classes)
rather than the final bundle, when compiling against
@@ -98,8 +115,8 @@
</plugin>
</plugins>
</build>
+
<dependencies>
-
<dependency>
<groupId>javax.enterprise</groupId>
<artifactId>cdi-api</artifactId>
@@ -112,12 +129,12 @@
<dependency>
<groupId>org.jboss.weld</groupId>
- <artifactId>weld-spi</artifactId>
+ <artifactId>weld-core</artifactId>
</dependency>
-
+
<dependency>
<groupId>org.jboss.weld</groupId>
- <artifactId>weld-core</artifactId>
+ <artifactId>weld-spi</artifactId>
</dependency>
<dependency>
@@ -140,7 +157,18 @@
<artifactId>javax.inject</artifactId>
</dependency>
+ <dependency>
+ <groupId>org.jboss.interceptor</groupId>
+ <artifactId>jboss-interceptor</artifactId>
+ </dependency>
+
+ <!-- Included due to bug in jboss-interceptor -->
+ <dependency>
+ <groupId>commons-logging</groupId>
+ <artifactId>commons-logging</artifactId>
+ <version>1.1.1</version>
+ </dependency>
+
</dependencies>
</project>
-
15 years
Weld SVN: r4110 - doc/trunk/reference.
by weld-commits@lists.jboss.org
Author: pete.muir(a)jboss.org
Date: 2009-10-15 09:52:09 -0400 (Thu, 15 Oct 2009)
New Revision: 4110
Modified:
doc/trunk/reference/
Log:
ignores
Property changes on: doc/trunk/reference
___________________________________________________________________
Name: svn:ignore
- target
.project
webbeans_reference.pdf
.settings
+ target
.project
webbeans_reference.pdf
.settings
weld_reference.pdf
15 years
Weld SVN: r4109 - core/trunk/jboss-as.
by weld-commits@lists.jboss.org
Author: pete.muir(a)jboss.org
Date: 2009-10-15 09:48:21 -0400 (Thu, 15 Oct 2009)
New Revision: 4109
Modified:
core/trunk/jboss-as/build.properties
Log:
ignores
Modified: core/trunk/jboss-as/build.properties
===================================================================
--- core/trunk/jboss-as/build.properties 2009-10-15 13:40:50 UTC (rev 4108)
+++ core/trunk/jboss-as/build.properties 2009-10-15 13:48:21 UTC (rev 4109)
@@ -1,6 +1,6 @@
# Container a number of properties associated with installing Weld into JBoss AS and running the TCK in JBoss AS
jboss.home=/Applications/jboss-5.2.0.Beta
-org.jboss.testharness.container.javaOpts=-Xms128m -Xmx384m -XX:MaxPermSize=192m -Dorg.jboss.resolver.warning=true -Dsun.rmi.dgc.client.gcInterval=3600000 -Dsun.rmi.dgc.server.gcInterval=3600000
+org.jboss.testharness.container.javaOpts=-Xms128m -Xmx512m -XX:MaxPermSize=192m -Dorg.jboss.resolver.warning=true -Dsun.rmi.dgc.client.gcInterval=3600000 -Dsun.rmi.dgc.server.gcInterval=3600000
# time to allow before attempting to restart JBoss AS
# org.jboss.testharness.container.shutdownDelay=15000
15 years
Weld SVN: r4108 - doc/trunk/reference.
by weld-commits@lists.jboss.org
Author: pete.muir(a)jboss.org
Date: 2009-10-15 09:40:50 -0400 (Thu, 15 Oct 2009)
New Revision: 4108
Modified:
doc/trunk/reference/pom.xml
Log:
Renames etc.
Modified: doc/trunk/reference/pom.xml
===================================================================
--- doc/trunk/reference/pom.xml 2009-10-15 13:39:52 UTC (rev 4107)
+++ doc/trunk/reference/pom.xml 2009-10-15 13:40:50 UTC (rev 4108)
@@ -1,13 +1,20 @@
-<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">
+<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>
- <groupId>org.jboss.webbeans.reference-guide</groupId>
- <artifactId>webbeans-reference-guide</artifactId>
+ <groupId>org.jboss.weld.reference-guide</groupId>
+ <artifactId>weld-reference-guide</artifactId>
<version>1.0.0-SNAPSHOT</version>
<packaging>jdocbook</packaging>
- <name>Web Beans Reference Guide</name>
+ <name>Weld Reference Guide</name>
+ <parent>
+ <groupId>org.jboss.weld</groupId>
+ <artifactId>weld-parent</artifactId>
+ <version>2</version>
+ </parent>
+
<pluginRepositories>
<pluginRepository>
<id>repository.jboss.org</id>
@@ -23,17 +30,12 @@
</repository>
</repositories>
- <properties>
- <mpjdocbook.version>2.1.1</mpjdocbook.version>
- </properties>
-
<build>
<defaultGoal>process-classes</defaultGoal>
<plugins>
<plugin>
<groupId>org.jboss.maven.plugins</groupId>
<artifactId>maven-jdocbook-plugin</artifactId>
- <version>${mpjdocbook.version}</version>
<extensions>true</extensions>
<dependencies>
<dependency>
@@ -68,15 +70,6 @@
<sourceDirectory>${pom.basedir}</sourceDirectory>
<sourceDocumentName>master.xml</sourceDocumentName>
<masterTranslation>en-US</masterTranslation>
- <translations>
- <translation>it-IT</translation>
- <translation>zh-CN</translation>
- <translation>zh-TW</translation>
- <translation>es-ES</translation>
- <translation>ko-KR</translation>
- <translation>de-DE</translation>
- <translation>pt-BR</translation>
- </translations>
<imageResource>
<directory>${pom.basedir}/en-US</directory>
<includes>
@@ -89,7 +82,7 @@
<stylesheetResource>
classpath:/xslt/org/jboss/webbeans/pdf.xsl
</stylesheetResource>
- <finalName>webbeans_reference.pdf</finalName>
+ <finalName>weld_reference.pdf</finalName>
</format>
<format>
<formatName>html</formatName>
@@ -109,8 +102,14 @@
<options>
<xincludeSupported>true</xincludeSupported>
<xmlTransformerType>saxon</xmlTransformerType>
- <!-- needed for uri-resolvers; can be ommitted if using 'current' uri scheme -->
- <!-- could also locate the docbook dependency and inspect its version... -->
+ <!--
+ needed for uri-resolvers; can be ommitted if using
+ 'current' uri scheme
+ -->
+ <!--
+ could also locate the docbook dependency and
+ inspect its version...
+ -->
<docbookVersion>1.72.0</docbookVersion>
<localeSeparator>-</localeSeparator>
</options>
@@ -125,7 +124,7 @@
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-release-plugin</artifactId>
<configuration>
- <arguments>-Dbuild.translations</arguments>
+ <arguments>-Ptranslations</arguments>
</configuration>
</plugin>
<plugin>
@@ -135,7 +134,9 @@
<phase>process-classes</phase>
<configuration>
<tasks>
- <copy file="${basedir}/target/docbook/publish/en-US/pdf/webbeans_reference.pdf" todir="${basedir}" />
+ <copy
+ file="${basedir}/target/docbook/publish/en-US/pdf/weld_reference.pdf"
+ todir="${basedir}" />
</tasks>
</configuration>
<goals>
@@ -148,7 +149,7 @@
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-enforcer-plugin</artifactId>
</plugin>
- <plugin>
+ <plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-release-plugin</artifactId>
<configuration>
@@ -163,125 +164,31 @@
<artifactId>maven-dependency-plugin</artifactId>
<version>2.0</version>
</plugin>
+ <!-- Remove for parent-3 -->
<plugin>
<groupId>org.jboss.maven.plugins</groupId>
<artifactId>maven-jdocbook-plugin</artifactId>
- <version>${mpjdocbook.version}</version>
+ <version>2.1.1</version>
</plugin>
+ <!-- Remove for parent-3 -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-jar-plugin</artifactId>
- <configuration>
- <archive>
- <manifest>
- <addDefaultImplementationEntries>
- true
- </addDefaultImplementationEntries>
- <addDefaultSpecificationEntries>
- true
- </addDefaultSpecificationEntries>
- </manifest>
- </archive>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-surefire-report-plugin</artifactId>
- <version>2.4.3</version>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-surefire-plugin</artifactId>
- <version>2.4.3</version>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-clean-plugin</artifactId>
- <version>2.2</version>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-deploy-plugin</artifactId>
- <version>2.4</version>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-install-plugin</artifactId>
- <version>2.2</version>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-site-plugin</artifactId>
- <version>2.0-beta-6</version>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-source-plugin</artifactId>
- <version>2.0.4</version>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-jar-plugin</artifactId>
- <version>2.2</version>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-antrun-plugin</artifactId>
- <version>1.1</version>
+ <version>1.3</version>
</plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-release-plugin</artifactId>
- <version>2.0-beta-7</version>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-enforcer-plugin</artifactId>
- <version>1.0-alpha-4</version>
- <executions>
- <execution>
- <id>enforce</id>
- <goals>
- <goal>enforce</goal>
- </goals>
- <configuration>
- <rules>
- <requireMavenVersion>
- <version>2.0.9</version>
- </requireMavenVersion>
- <requirePluginVersions>
- <unCheckedPlugins>
- <unCheckedPlugin>org.apache.maven.plugins:maven-eclipse-plugin</unCheckedPlugin>
- </unCheckedPlugins>
- </requirePluginVersions>
- </rules>
- </configuration>
- </execution>
- </executions>
- </plugin>
+
</plugins>
</pluginManagement>
- <extensions>
- <extension>
- <groupId>org.apache.maven.wagon</groupId>
- <artifactId>wagon-webdav</artifactId>
- <version>1.0-beta-2</version>
- </extension>
- </extensions>
</build>
-
+
<profiles>
<profile>
- <activation>
- <property>
- <name>build.translations</name>
- </property>
- </activation>
+ <id>translations</id>
<build>
<plugins>
<plugin>
- <groupId>org.jboss.maven.plugins</groupId>
- <artifactId>maven-jdocbook-plugin</artifactId>
+ <groupId>org.jboss.maven.plugins</groupId>
+ <artifactId>maven-jdocbook-plugin</artifactId>
<executions>
<execution>
<phase>process-resources</phase>
@@ -290,13 +197,24 @@
</goals>
</execution>
</executions>
+ <configuration>
+ <translations>
+ <translation>it-IT</translation>
+ <translation>zh-CN</translation>
+ <translation>zh-TW</translation>
+ <translation>es-ES</translation>
+ <translation>ko-KR</translation>
+ <translation>de-DE</translation>
+ <translation>pt-BR</translation>
+ </translations>
+ </configuration>
</plugin>
</plugins>
</build>
</profile>
</profiles>
-
- <ciManagement>
+
+ <ciManagement>
<system>Hudson</system>
<url />
@@ -304,28 +222,18 @@
<issueManagement>
<system>JIRA</system>
- <url>http://jira.jboss.org/browse/WBRI</url>
+ <url>http://jira.jboss.org/browse/WELD</url>
</issueManagement>
<inceptionYear>2008</inceptionYear>
+
+
<scm>
- <connection>scm:svn:http://anonsvn.jboss.org/repos/webbeans/doc</connection>
- <developerConnection>scm:svn:https://svn.jboss.org/repos/webbeans/doc</developerConnection>
- <url>http://fisheye.jboss.org/browse/WebBeans/doc</url>
- </scm>
+ <connection>scm:svn:http://anonsvn.jboss.org/repos/weld/doc</connection>
+ <developerConnection>scm:svn:https://svn.jboss.org/repos/weld/doc</developerConnection>
+ <url>http://fisheye.jboss.org/browse/Weld/doc</url>
+ </scm>
- <distributionManagement>
- <repository>
- <id>repository.jboss.org</id>
- <name>JBoss Releases Repository</name>
- <url>dav:https://svn.jboss.org/repos/repository.jboss.org/maven2</url>
- </repository>
- <snapshotRepository>
- <id>snapshots.jboss.org</id>
- <name>JBoss Snapshot Repository</name>
- <url>dav:https://snapshots.jboss.org/maven2</url>
- </snapshotRepository>
- </distributionManagement>
</project>
\ No newline at end of file
15 years
Weld SVN: r4107 - in core/trunk/impl/src/main/java/org/jboss/weld: util and 1 other directory.
by weld-commits@lists.jboss.org
Author: pete.muir(a)jboss.org
Date: 2009-10-15 09:39:52 -0400 (Thu, 15 Oct 2009)
New Revision: 4107
Modified:
core/trunk/impl/src/main/java/org/jboss/weld/bootstrap/WeldBootstrap.java
core/trunk/impl/src/main/java/org/jboss/weld/util/Names.java
Log:
Nicer version string
Modified: core/trunk/impl/src/main/java/org/jboss/weld/bootstrap/WeldBootstrap.java
===================================================================
--- core/trunk/impl/src/main/java/org/jboss/weld/bootstrap/WeldBootstrap.java 2009-10-15 06:46:13 UTC (rev 4106)
+++ core/trunk/impl/src/main/java/org/jboss/weld/bootstrap/WeldBootstrap.java 2009-10-15 13:39:52 UTC (rev 4107)
@@ -64,6 +64,7 @@
import org.jboss.weld.resources.spi.ResourceLoader;
import org.jboss.weld.servlet.ServletApiAbstraction;
import org.jboss.weld.transaction.spi.TransactionServices;
+import org.jboss.weld.util.Names;
import org.jboss.weld.util.serviceProvider.ServiceLoader;
import org.jboss.weld.ws.WSApiAbstraction;
@@ -318,7 +319,7 @@
public static String getVersion()
{
Package pkg = WeldBootstrap.class.getPackage();
- return pkg != null ? pkg.getImplementationVersion() : null;
+ return pkg != null ? Names.version(pkg.getImplementationVersion()) : null;
}
protected void initializeContexts()
Modified: core/trunk/impl/src/main/java/org/jboss/weld/util/Names.java
===================================================================
--- core/trunk/impl/src/main/java/org/jboss/weld/util/Names.java 2009-10-15 06:46:13 UTC (rev 4106)
+++ core/trunk/impl/src/main/java/org/jboss/weld/util/Names.java 2009-10-15 13:39:52 UTC (rev 4107)
@@ -332,5 +332,10 @@
buffer.append("]");
return buffer.toString();
}
+
+ public static String version(String version)
+ {
+ return new StringBuilder().append(version.substring(0, version.lastIndexOf("-"))).append(" (").append(version.substring(version.lastIndexOf("-") + 1)).append(")").toString();
+ }
}
15 years
Weld SVN: r4106 - in core/trunk: impl/src/main/java/org/jboss/weld/bean and 9 other directories.
by weld-commits@lists.jboss.org
Author: marius.bogoevici
Date: 2009-10-15 02:46:13 -0400 (Thu, 15 Oct 2009)
New Revision: 4106
Added:
core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/
core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/interceptorWithNonSerializableField/
core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/interceptorWithNonSerializableField/Ball.java
core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/interceptorWithNonSerializableField/Defender.java
core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/interceptorWithNonSerializableField/InterceptorWithNonSerializableFieldOnPassivatingBean.java
core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/interceptorWithNonSerializableField/Pass.java
core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/interceptorWithNonSerializableField/Team.java
core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/nonSerializableInterceptor/
core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/nonSerializableInterceptor/Ball.java
core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/nonSerializableInterceptor/Defender.java
core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/nonSerializableInterceptor/NonPassivatingInterceptorOnPassivatingBean.java
core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/nonSerializableInterceptor/Pass.java
core/trunk/tests/src/test/resources/org/jboss/weld/test/unit/interceptor/passivation/broken/
core/trunk/tests/src/test/resources/org/jboss/weld/test/unit/interceptor/passivation/broken/interceptorWithNonSerializableField/
core/trunk/tests/src/test/resources/org/jboss/weld/test/unit/interceptor/passivation/broken/interceptorWithNonSerializableField/beans.xml
core/trunk/tests/src/test/resources/org/jboss/weld/test/unit/interceptor/passivation/broken/nonSerializableInterceptor/
core/trunk/tests/src/test/resources/org/jboss/weld/test/unit/interceptor/passivation/broken/nonSerializableInterceptor/beans.xml
Modified:
core/trunk/impl/src/main/java/org/jboss/weld/Validator.java
core/trunk/impl/src/main/java/org/jboss/weld/bean/AbstractClassBean.java
core/trunk/impl/src/main/java/org/jboss/weld/bean/ManagedBean.java
core/trunk/impl/src/main/java/org/jboss/weld/util/Beans.java
Log:
Enforcing serializability check for interceptors on passivating beans + tests + factoring out injection points test.
Modified: core/trunk/impl/src/main/java/org/jboss/weld/Validator.java
===================================================================
--- core/trunk/impl/src/main/java/org/jboss/weld/Validator.java 2009-10-15 06:25:02 UTC (rev 4105)
+++ core/trunk/impl/src/main/java/org/jboss/weld/Validator.java 2009-10-15 06:46:13 UTC (rev 4106)
@@ -118,7 +118,7 @@
for (InjectionPoint ij : decorator.getInjectionPoints())
{
Bean<?> resolvedBean = beanManager.resolve(beanManager.getInjectableBeans(ij));
- validateInjectionPointPassivationCapable(ij, resolvedBean, beanManager);
+ Beans.validateInjectionPointPassivationCapable(ij, resolvedBean, beanManager);
}
}
}
@@ -176,22 +176,10 @@
}
if (ij.getBean() != null && Beans.isPassivatingScope(ij.getBean(), beanManager) && (!ij.isTransient()) && !Beans.isPassivationCapableBean(resolvedBean))
{
- validateInjectionPointPassivationCapable(ij, resolvedBean, beanManager);
+ Beans.validateInjectionPointPassivationCapable(ij, resolvedBean, beanManager);
}
}
- public void validateInjectionPointPassivationCapable(InjectionPoint ij, Bean<?> resolvedBean, BeanManagerImpl beanManager)
- {
- if (!ij.isTransient() && !Beans.isPassivationCapableBean(resolvedBean))
- {
- if (resolvedBean.getScope().equals(Dependent.class) && resolvedBean instanceof AbstractProducerBean<?, ?,?>)
- {
- throw new IllegalProductException("The bean " + ij.getBean() + " declares a passivating scope but the producer returned a non-serializable bean for injection: " + resolvedBean);
- }
- throw new UnserializableDependencyException("The bean " + ij.getBean() + " declares a passivating scope but has non-serializable dependency: " + resolvedBean);
- }
- }
-
public void validateDeployment(BeanManagerImpl manager, BeanDeployerEnvironment environment)
{
validateBeans(manager.getDecorators(), new ArrayList<RIBean<?>>(), manager);
Modified: core/trunk/impl/src/main/java/org/jboss/weld/bean/AbstractClassBean.java
===================================================================
--- core/trunk/impl/src/main/java/org/jboss/weld/bean/AbstractClassBean.java 2009-10-15 06:25:02 UTC (rev 4105)
+++ core/trunk/impl/src/main/java/org/jboss/weld/bean/AbstractClassBean.java 2009-10-15 06:46:13 UTC (rev 4106)
@@ -24,6 +24,7 @@
import java.util.LinkedHashSet;
import java.util.List;
import java.util.Set;
+import java.util.Collection;
import javassist.util.proxy.ProxyFactory;
import javassist.util.proxy.ProxyObject;
@@ -37,6 +38,7 @@
import javax.enterprise.inject.spi.InjectionTarget;
import javax.enterprise.inject.spi.InterceptionType;
import javax.enterprise.inject.spi.Interceptor;
+import javax.enterprise.inject.spi.Bean;
import javax.inject.Scope;
import org.jboss.interceptor.model.InterceptionModelBuilder;
@@ -57,6 +59,7 @@
import org.jboss.weld.util.Beans;
import org.jboss.weld.util.Proxies;
import org.jboss.weld.util.Strings;
+import org.jboss.weld.util.Reflections;
/**
* An abstract bean representation common for class-based beans
@@ -412,7 +415,8 @@
{
if (manager.getBoundInterceptorsRegistry().getInterceptionModel(getType()) == null)
{
- InterceptionModelBuilder<Class<?>, SerializableContextual<Interceptor<?>, ?>> builder = InterceptionModelBuilder.newBuilderFor(getType(), (Class) SerializableContextual.class);
+ InterceptionModelBuilder<Class<?>, SerializableContextual<Interceptor<?>, ?>> builder =
+ InterceptionModelBuilder.newBuilderFor(getType(), (Class) SerializableContextual.class);
Set<Annotation> classBindingAnnotations = flattenInterceptorBindings(manager, getAnnotatedItem().getAnnotations());
for (Class<? extends Annotation> annotation : getStereotypes())
{
@@ -422,11 +426,26 @@
{
if (Beans.findInterceptorBindingConflicts(manager, classBindingAnnotations))
throw new DeploymentException("Conflicting interceptor bindings found on " + getType());
+
Annotation[] classBindingAnnotationsArray = classBindingAnnotations.toArray(new Annotation[0]);
- builder.interceptPostConstruct().with(toSerializableContextualArray(manager.resolveInterceptors(InterceptionType.POST_CONSTRUCT, classBindingAnnotationsArray)));
- builder.interceptPreDestroy().with(toSerializableContextualArray(manager.resolveInterceptors(InterceptionType.PRE_DESTROY, classBindingAnnotationsArray)));
- builder.interceptPrePassivate().with(toSerializableContextualArray(manager.resolveInterceptors(InterceptionType.PRE_PASSIVATE, classBindingAnnotationsArray)));
- builder.interceptPostActivate().with(toSerializableContextualArray(manager.resolveInterceptors(InterceptionType.POST_ACTIVATE, classBindingAnnotationsArray)));
+
+ List<Interceptor<?>> resolvedPostConstructInterceptors = manager.resolveInterceptors(InterceptionType.POST_CONSTRUCT, classBindingAnnotationsArray);
+ validateSerializableInterceptors(resolvedPostConstructInterceptors);
+ builder.interceptPostConstruct().with(toSerializableContextualArray(resolvedPostConstructInterceptors));
+
+ List<Interceptor<?>> resolvedPreDestroyInterceptors = manager.resolveInterceptors(InterceptionType.PRE_DESTROY, classBindingAnnotationsArray);
+ validateSerializableInterceptors(resolvedPreDestroyInterceptors);
+ builder.interceptPreDestroy().with(toSerializableContextualArray(resolvedPreDestroyInterceptors));
+
+
+ List<Interceptor<?>> resolvedPrePassivateInterceptors = manager.resolveInterceptors(InterceptionType.PRE_PASSIVATE, classBindingAnnotationsArray);
+ validateSerializableInterceptors(resolvedPrePassivateInterceptors);
+ builder.interceptPrePassivate().with(toSerializableContextualArray(resolvedPrePassivateInterceptors));
+
+ List<Interceptor<?>> resolvedPostActivateInterceptors = manager.resolveInterceptors(InterceptionType.POST_ACTIVATE, classBindingAnnotationsArray);
+ validateSerializableInterceptors(resolvedPostActivateInterceptors);
+ builder.interceptPostActivate().with(toSerializableContextualArray(resolvedPostActivateInterceptors));
+
}
List<WeldMethod<?, ?>> businessMethods = Beans.getInterceptableBusinessMethods(getAnnotatedItem());
for (WeldMethod<?, ?> method : businessMethods)
@@ -438,12 +457,33 @@
if (Beans.findInterceptorBindingConflicts(manager, classBindingAnnotations))
throw new DeploymentException("Conflicting interceptor bindings found on " + getType() + "." + method.getName() + "()");
List<Interceptor<?>> methodBoundInterceptors = manager.resolveInterceptors(InterceptionType.AROUND_INVOKE, methodBindingAnnotations.toArray(new Annotation[]{}));
+ validateSerializableInterceptors(methodBoundInterceptors);
builder.interceptAroundInvoke(((AnnotatedMethod) method).getJavaMember()).with(toSerializableContextualArray(methodBoundInterceptors));
}
}
manager.getBoundInterceptorsRegistry().registerInterceptionModel(getType(), builder.build());
}
}
+
+ private void validateSerializableInterceptors(Collection<Interceptor<?>> interceptors)
+ {
+ if (Beans.isPassivationCapableBean(this))
+ {
+ for (Interceptor<?> interceptor: interceptors)
+ {
+ if (!Reflections.isSerializable(interceptor.getBeanClass()))
+ {
+ throw new DeploymentException("The bean " + this + " declared a passivating scope, " +
+ "but has a non-serializable interceptor: " + interceptor);
+ }
+ for (InjectionPoint injectionPoint: interceptor.getInjectionPoints())
+ {
+ Bean<?> resolvedBean = manager.resolve(manager.getInjectableBeans(injectionPoint));
+ Beans.validateInjectionPointPassivationCapable(injectionPoint, resolvedBean, manager);
+ }
+ }
+ }
+ }
public void setInjectionTarget(InjectionTarget<T> injectionTarget)
{
Modified: core/trunk/impl/src/main/java/org/jboss/weld/bean/ManagedBean.java
===================================================================
--- core/trunk/impl/src/main/java/org/jboss/weld/bean/ManagedBean.java 2009-10-15 06:25:02 UTC (rev 4105)
+++ core/trunk/impl/src/main/java/org/jboss/weld/bean/ManagedBean.java 2009-10-15 06:46:13 UTC (rev 4106)
@@ -28,6 +28,7 @@
import javax.enterprise.inject.spi.Decorator;
import javax.enterprise.inject.spi.InjectionPoint;
import javax.enterprise.inject.spi.InjectionTarget;
+import javax.enterprise.inject.spi.Bean;
import org.jboss.interceptor.model.InterceptionModelBuilder;
import org.jboss.interceptor.model.InterceptorClassMetadataImpl;
@@ -418,7 +419,7 @@
return !Beans.isInterceptor(getAnnotatedItem()) && !Beans.isDecorator(getAnnotatedItem());
}
- private boolean hasBoundInterceptors()
+ public boolean hasBoundInterceptors()
{
if (manager.getBoundInterceptorsRegistry().getInterceptionModel(getType()) != null)
return manager.getBoundInterceptorsRegistry().getInterceptionModel(getType()).getAllInterceptors().size() > 0;
@@ -472,6 +473,10 @@
Annotation interceptorsAnnotation = getType().getAnnotation(InterceptionUtils.getInterceptorsAnnotationClass());
classDeclaredInterceptors = Reflections.extractValues(interceptorsAnnotation);
}
+
+ validatePassivatingInterceptors(classDeclaredInterceptors);
+
+
if (classDeclaredInterceptors != null)
{
builder.interceptPostConstruct().with(classDeclaredInterceptors);
@@ -489,6 +494,7 @@
{
methodDeclaredInterceptors = Reflections.extractValues(method.getAnnotation(InterceptionUtils.getInterceptorsAnnotationClass()));
}
+ validatePassivatingInterceptors(methodDeclaredInterceptors);
if (!excludeClassInterceptors && classDeclaredInterceptors != null)
{
builder.interceptAroundInvoke(((AnnotatedMethod) method).getJavaMember()).with(classDeclaredInterceptors);
@@ -504,4 +510,25 @@
}
}
+ private void validatePassivatingInterceptors(Class<?>[] classDeclaredInterceptors)
+ {
+ if (classDeclaredInterceptors != null && Beans.isPassivationCapableBean(this))
+ {
+ for (Class<?> interceptorClass: classDeclaredInterceptors)
+ {
+ if (!Reflections.isSerializable(interceptorClass))
+ {
+ throw new DeploymentException("The bean " + this + " declared a passivating scope, " +
+ "but has a non-serializable interceptor class: " + interceptorClass.getName());
+ }
+ InjectionTarget<Object> injectionTarget = (InjectionTarget<Object>) manager.createInjectionTarget(manager.createAnnotatedType(interceptorClass));
+ for (InjectionPoint injectionPoint: injectionTarget.getInjectionPoints())
+ {
+ Bean<?> resolvedBean = manager.resolve(manager.getInjectableBeans(injectionPoint));
+ Beans.validateInjectionPointPassivationCapable(injectionPoint, resolvedBean, manager);
+ }
+ }
+ }
+ }
+
}
Modified: core/trunk/impl/src/main/java/org/jboss/weld/util/Beans.java
===================================================================
--- core/trunk/impl/src/main/java/org/jboss/weld/util/Beans.java 2009-10-15 06:25:02 UTC (rev 4105)
+++ core/trunk/impl/src/main/java/org/jboss/weld/util/Beans.java 2009-10-15 06:46:13 UTC (rev 4106)
@@ -34,17 +34,21 @@
import javax.decorator.Decorator;
import javax.enterprise.context.spi.Contextual;
import javax.enterprise.context.spi.CreationalContext;
+import javax.enterprise.context.Dependent;
import javax.enterprise.event.Observes;
import javax.enterprise.inject.CreationException;
import javax.enterprise.inject.Disposes;
import javax.enterprise.inject.Produces;
+import javax.enterprise.inject.IllegalProductException;
import javax.enterprise.inject.spi.Bean;
+import javax.enterprise.inject.spi.InjectionPoint;
import javax.inject.Inject;
import org.jboss.interceptor.model.InterceptionType;
import org.jboss.interceptor.model.InterceptionTypeRegistry;
import org.jboss.weld.BeanManagerImpl;
import org.jboss.weld.DefinitionException;
+import org.jboss.weld.UnserializableDependencyException;
import org.jboss.weld.bean.AbstractProducerBean;
import org.jboss.weld.bean.RIBean;
import org.jboss.weld.bean.SessionBean;
@@ -128,6 +132,18 @@
}
}
+ public static void validateInjectionPointPassivationCapable(InjectionPoint ij, Bean<?> resolvedBean, BeanManagerImpl beanManager)
+ {
+ if (!ij.isTransient() && !Beans.isPassivationCapableBean(resolvedBean))
+ {
+ if (resolvedBean.getScope().equals(Dependent.class) && resolvedBean instanceof AbstractProducerBean<?, ?, ?>)
+ {
+ throw new IllegalProductException("The bean " + ij.getBean() + " declares a passivating scope but the producer returned a non-serializable bean for injection: " + resolvedBean);
+ }
+ throw new UnserializableDependencyException("The bean " + ij.getBean() + " declares a passivating scope but has non-serializable dependency: " + resolvedBean);
+ }
+ }
+
/**
* Indicates if a bean is proxyable
*
Added: core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/interceptorWithNonSerializableField/Ball.java
===================================================================
--- core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/interceptorWithNonSerializableField/Ball.java (rev 0)
+++ core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/interceptorWithNonSerializableField/Ball.java 2009-10-15 06:46:13 UTC (rev 4106)
@@ -0,0 +1,38 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2009, Red Hat, Inc. and/or its affiliates, and individual
+ * contributors by the @authors tag. See the copyright.txt in the
+ * distribution for a full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.jboss.weld.test.unit.interceptor.passivation.broken.interceptorWithNonSerializableField;
+
+import java.io.Serializable;
+
+
+/**
+ * @author <a href="mailto:mariusb@redhat.com">Marius Bogoevici</a>
+ */
+
+public class Ball implements Serializable
+{
+ public void shoot()
+ {
+ }
+
+ @Pass
+ public void pass()
+ {
+ }
+
+}
\ No newline at end of file
Added: core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/interceptorWithNonSerializableField/Defender.java
===================================================================
--- core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/interceptorWithNonSerializableField/Defender.java (rev 0)
+++ core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/interceptorWithNonSerializableField/Defender.java 2009-10-15 06:46:13 UTC (rev 4106)
@@ -0,0 +1,26 @@
+package org.jboss.weld.test.unit.interceptor.passivation.broken.interceptorWithNonSerializableField;
+
+import java.io.Serializable;
+
+import javax.interceptor.Interceptor;
+import javax.interceptor.AroundInvoke;
+import javax.interceptor.InvocationContext;
+import javax.inject.Inject;
+
+/**
+ * @author Marius Bogoevici
+ */
+@Interceptor @Pass
+public class Defender implements Serializable
+{
+
+ @Inject
+ Team team;
+
+ @AroundInvoke
+ public Object defend(InvocationContext invocationContext) throws Exception
+ {
+ return invocationContext.proceed();
+ }
+
+}
\ No newline at end of file
Added: core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/interceptorWithNonSerializableField/InterceptorWithNonSerializableFieldOnPassivatingBean.java
===================================================================
--- core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/interceptorWithNonSerializableField/InterceptorWithNonSerializableFieldOnPassivatingBean.java (rev 0)
+++ core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/interceptorWithNonSerializableField/InterceptorWithNonSerializableFieldOnPassivatingBean.java 2009-10-15 06:46:13 UTC (rev 4106)
@@ -0,0 +1,50 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2009, Red Hat, Inc. and/or its affiliates, and individual
+ * contributors by the @authors tag. See the copyright.txt in the
+ * distribution for a full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.jboss.weld.test.unit.interceptor.passivation.broken.interceptorWithNonSerializableField;
+
+import java.io.ByteArrayOutputStream;
+import java.io.ObjectOutputStream;
+import java.io.ObjectInputStream;
+import java.io.ByteArrayInputStream;
+
+import javax.enterprise.inject.spi.Bean;
+import javax.enterprise.context.spi.CreationalContext;
+
+import org.jboss.testharness.impl.packaging.Artifact;
+import org.jboss.testharness.impl.packaging.ExpectedDeploymentException;
+import org.jboss.testharness.impl.packaging.jsr299.BeansXml;
+import org.jboss.weld.test.AbstractWeldTest;
+import org.jboss.weld.test.unit.interceptor.passivation.Ball;
+import org.jboss.weld.test.unit.interceptor.passivation.PassivationActivationInterceptor;
+import org.jboss.weld.DeploymentException;
+
+import org.testng.annotations.Test;
+
+/**
+ * @author Marius Bogoevici
+ */
+@Artifact
+@BeansXml("beans.xml")
+public class InterceptorWithNonSerializableFieldOnPassivatingBean extends AbstractWeldTest
+{
+ @Test
+ public void testNonPassivatingField() throws Exception
+ {
+ assert false;
+ }
+}
\ No newline at end of file
Added: core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/interceptorWithNonSerializableField/Pass.java
===================================================================
--- core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/interceptorWithNonSerializableField/Pass.java (rev 0)
+++ core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/interceptorWithNonSerializableField/Pass.java 2009-10-15 06:46:13 UTC (rev 4106)
@@ -0,0 +1,38 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2009, Red Hat, Inc. and/or its affiliates, and individual
+ * contributors by the @authors tag. See the copyright.txt in the
+ * distribution for a full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.jboss.weld.test.unit.interceptor.passivation.broken.interceptorWithNonSerializableField;
+
+import java.lang.annotation.Retention;
+import java.lang.annotation.Target;
+import java.lang.annotation.ElementType;
+import java.lang.annotation.Documented;
+import static java.lang.annotation.RetentionPolicy.RUNTIME;
+
+import javax.interceptor.InterceptorBinding;
+
+/**
+ * @author <a href="mailto:mariusb@redhat.com">Marius Bogoevici</a>
+ */
+@InterceptorBinding
+@Retention(RUNTIME)
+(a)Target({ElementType.METHOD, ElementType.TYPE})
+@Documented
+public @interface Pass
+{
+
+}
\ No newline at end of file
Added: core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/interceptorWithNonSerializableField/Team.java
===================================================================
--- core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/interceptorWithNonSerializableField/Team.java (rev 0)
+++ core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/interceptorWithNonSerializableField/Team.java 2009-10-15 06:46:13 UTC (rev 4106)
@@ -0,0 +1,9 @@
+package org.jboss.weld.test.unit.interceptor.passivation.broken.interceptorWithNonSerializableField;
+
+/**
+ * @author Marius Bogoevici
+ */
+public class Team
+{
+
+}
Copied: core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/nonSerializableInterceptor/Ball.java (from rev 4102, core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/Ball.java)
===================================================================
--- core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/nonSerializableInterceptor/Ball.java (rev 0)
+++ core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/nonSerializableInterceptor/Ball.java 2009-10-15 06:46:13 UTC (rev 4106)
@@ -0,0 +1,38 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2009, Red Hat, Inc. and/or its affiliates, and individual
+ * contributors by the @authors tag. See the copyright.txt in the
+ * distribution for a full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.jboss.weld.test.unit.interceptor.passivation.broken.nonSerializableInterceptor;
+
+import java.io.Serializable;
+
+
+/**
+ * @author <a href="mailto:mariusb@redhat.com">Marius Bogoevici</a>
+ */
+
+public class Ball implements Serializable
+{
+ public void shoot()
+ {
+ }
+
+ @Pass
+ public void pass()
+ {
+ }
+
+}
\ No newline at end of file
Added: core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/nonSerializableInterceptor/Defender.java
===================================================================
--- core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/nonSerializableInterceptor/Defender.java (rev 0)
+++ core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/nonSerializableInterceptor/Defender.java 2009-10-15 06:46:13 UTC (rev 4106)
@@ -0,0 +1,20 @@
+package org.jboss.weld.test.unit.interceptor.passivation.broken.nonSerializableInterceptor;
+
+import javax.interceptor.Interceptor;
+import javax.interceptor.AroundInvoke;
+import javax.interceptor.InvocationContext;
+
+
+/**
+ * @author Marius Bogoevici
+ */
+@Interceptor @Pass
+public class Defender
+{
+ @AroundInvoke
+ public Object defend(InvocationContext invocationContext) throws Exception
+ {
+ return invocationContext.proceed();
+ }
+
+}
Copied: core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/nonSerializableInterceptor/NonPassivatingInterceptorOnPassivatingBean.java (from rev 4102, core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/PassivationActivationTest.java)
===================================================================
--- core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/nonSerializableInterceptor/NonPassivatingInterceptorOnPassivatingBean.java (rev 0)
+++ core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/nonSerializableInterceptor/NonPassivatingInterceptorOnPassivatingBean.java 2009-10-15 06:46:13 UTC (rev 4106)
@@ -0,0 +1,51 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2009, Red Hat, Inc. and/or its affiliates, and individual
+ * contributors by the @authors tag. See the copyright.txt in the
+ * distribution for a full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.jboss.weld.test.unit.interceptor.passivation.broken.nonSerializableInterceptor;
+
+import java.io.ByteArrayOutputStream;
+import java.io.ObjectOutputStream;
+import java.io.ObjectInputStream;
+import java.io.ByteArrayInputStream;
+
+import javax.enterprise.inject.spi.Bean;
+import javax.enterprise.context.spi.CreationalContext;
+
+import org.jboss.testharness.impl.packaging.Artifact;
+import org.jboss.testharness.impl.packaging.ExpectedDeploymentException;
+import org.jboss.testharness.impl.packaging.jsr299.BeansXml;
+import org.jboss.weld.test.AbstractWeldTest;
+import org.jboss.weld.test.unit.interceptor.passivation.Ball;
+import org.jboss.weld.test.unit.interceptor.passivation.PassivationActivationInterceptor;
+import org.jboss.weld.DeploymentException;
+
+import org.testng.annotations.Test;
+
+/**
+ * @author Marius Bogoevici
+ */
+@Artifact
+@BeansXml("beans.xml")
+(a)ExpectedDeploymentException(DeploymentException.class)
+public class NonPassivatingInterceptorOnPassivatingBean extends AbstractWeldTest
+{
+ @Test
+ public void testNonPassivatingInterceptor() throws Exception
+ {
+ assert false;
+ }
+}
\ No newline at end of file
Copied: core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/nonSerializableInterceptor/Pass.java (from rev 4102, core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/Pass.java)
===================================================================
--- core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/nonSerializableInterceptor/Pass.java (rev 0)
+++ core/trunk/tests/src/test/java/org/jboss/weld/test/unit/interceptor/passivation/broken/nonSerializableInterceptor/Pass.java 2009-10-15 06:46:13 UTC (rev 4106)
@@ -0,0 +1,38 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2009, Red Hat, Inc. and/or its affiliates, and individual
+ * contributors by the @authors tag. See the copyright.txt in the
+ * distribution for a full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.jboss.weld.test.unit.interceptor.passivation.broken.nonSerializableInterceptor;
+
+import java.lang.annotation.Retention;
+import java.lang.annotation.Target;
+import java.lang.annotation.ElementType;
+import java.lang.annotation.Documented;
+import static java.lang.annotation.RetentionPolicy.RUNTIME;
+
+import javax.interceptor.InterceptorBinding;
+
+/**
+ * @author <a href="mailto:mariusb@redhat.com">Marius Bogoevici</a>
+ */
+@InterceptorBinding
+@Retention(RUNTIME)
+(a)Target({ElementType.METHOD, ElementType.TYPE})
+@Documented
+public @interface Pass
+{
+
+}
\ No newline at end of file
Added: core/trunk/tests/src/test/resources/org/jboss/weld/test/unit/interceptor/passivation/broken/interceptorWithNonSerializableField/beans.xml
===================================================================
--- core/trunk/tests/src/test/resources/org/jboss/weld/test/unit/interceptor/passivation/broken/interceptorWithNonSerializableField/beans.xml (rev 0)
+++ core/trunk/tests/src/test/resources/org/jboss/weld/test/unit/interceptor/passivation/broken/interceptorWithNonSerializableField/beans.xml 2009-10-15 06:46:13 UTC (rev 4106)
@@ -0,0 +1,5 @@
+<beans>
+ <interceptors>
+ <class>org.jboss.weld.test.unit.interceptor.passivation.broken.interceptorWithNonSerializableField.Defender</class>
+ </interceptors>
+</beans>
\ No newline at end of file
Added: core/trunk/tests/src/test/resources/org/jboss/weld/test/unit/interceptor/passivation/broken/nonSerializableInterceptor/beans.xml
===================================================================
--- core/trunk/tests/src/test/resources/org/jboss/weld/test/unit/interceptor/passivation/broken/nonSerializableInterceptor/beans.xml (rev 0)
+++ core/trunk/tests/src/test/resources/org/jboss/weld/test/unit/interceptor/passivation/broken/nonSerializableInterceptor/beans.xml 2009-10-15 06:46:13 UTC (rev 4106)
@@ -0,0 +1,5 @@
+<beans>
+ <interceptors>
+ <class>org.jboss.weld.test.unit.interceptor.passivation.broken.nonSerializableInterceptor.Defender</class>
+ </interceptors>
+</beans>
\ No newline at end of file
15 years
Weld SVN: r4105 - cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/interceptors/definition/enterprise.
by weld-commits@lists.jboss.org
Author: marius.bogoevici
Date: 2009-10-15 02:25:02 -0400 (Thu, 15 Oct 2009)
New Revision: 4105
Modified:
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/interceptors/definition/enterprise/MissileInterceptor.java
Log:
Inteceptors bound on passivatable beans must be serializable.
Modified: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/interceptors/definition/enterprise/MissileInterceptor.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/interceptors/definition/enterprise/MissileInterceptor.java 2009-10-15 02:57:33 UTC (rev 4104)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/interceptors/definition/enterprise/MissileInterceptor.java 2009-10-15 06:25:02 UTC (rev 4105)
@@ -1,11 +1,13 @@
package org.jboss.jsr299.tck.tests.interceptors.definition.enterprise;
+import java.io.Serializable;
+
import javax.interceptor.AroundInvoke;
import javax.interceptor.Interceptor;
import javax.interceptor.InvocationContext;
@Interceptor @Airborne
-class MissileInterceptor
+class MissileInterceptor implements Serializable
{
public static boolean intercepted = false;
15 years
Weld SVN: r4104 - in cdi-tck/trunk/impl/src/main: resources/org/jboss/jsr299/tck/tests/interceptors/definition and 1 other directories.
by weld-commits@lists.jboss.org
Author: marius.bogoevici
Date: 2009-10-14 22:57:33 -0400 (Wed, 14 Oct 2009)
New Revision: 4104
Added:
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/interceptors/definition/enterprise/Airborne.java
cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/interceptors/definition/enterprise/
cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/interceptors/definition/enterprise/beans.xml
Modified:
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/interceptors/definition/enterprise/Missile.java
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/interceptors/definition/enterprise/MissileInterceptor.java
cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/interceptors/definition/enterprise/SessionBeanInterceptorDefinitionTest.java
Log:
Testing that @InterceptorBinding interceptors are applied on EJBs
Added: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/interceptors/definition/enterprise/Airborne.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/interceptors/definition/enterprise/Airborne.java (rev 0)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/interceptors/definition/enterprise/Airborne.java 2009-10-15 02:57:33 UTC (rev 4104)
@@ -0,0 +1,19 @@
+package org.jboss.jsr299.tck.tests.interceptors.definition.enterprise;
+
+import java.lang.annotation.Target;
+import java.lang.annotation.Retention;
+import java.lang.annotation.Documented;
+import static java.lang.annotation.RetentionPolicy.RUNTIME;
+import static java.lang.annotation.ElementType.TYPE;
+import static java.lang.annotation.ElementType.METHOD;
+
+import javax.interceptor.InterceptorBinding;
+
+@Target( { TYPE, METHOD})
+@Retention(RUNTIME)
+@Documented
+@InterceptorBinding
+public @interface Airborne
+{
+
+}
\ No newline at end of file
Modified: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/interceptors/definition/enterprise/Missile.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/interceptors/definition/enterprise/Missile.java 2009-10-14 23:46:51 UTC (rev 4103)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/interceptors/definition/enterprise/Missile.java 2009-10-15 02:57:33 UTC (rev 4104)
@@ -4,7 +4,7 @@
import javax.interceptor.Interceptors;
@Stateful
-(a)Interceptors(MissileInterceptor.class)
+@Airborne
public class Missile implements MissileLocal
{
public void fire() {}
Modified: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/interceptors/definition/enterprise/MissileInterceptor.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/interceptors/definition/enterprise/MissileInterceptor.java 2009-10-14 23:46:51 UTC (rev 4103)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/interceptors/definition/enterprise/MissileInterceptor.java 2009-10-15 02:57:33 UTC (rev 4104)
@@ -4,7 +4,7 @@
import javax.interceptor.Interceptor;
import javax.interceptor.InvocationContext;
-@Interceptor
+@Interceptor @Airborne
class MissileInterceptor
{
public static boolean intercepted = false;
Modified: cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/interceptors/definition/enterprise/SessionBeanInterceptorDefinitionTest.java
===================================================================
--- cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/interceptors/definition/enterprise/SessionBeanInterceptorDefinitionTest.java 2009-10-14 23:46:51 UTC (rev 4103)
+++ cdi-tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/interceptors/definition/enterprise/SessionBeanInterceptorDefinitionTest.java 2009-10-15 02:57:33 UTC (rev 4104)
@@ -7,6 +7,8 @@
import org.jboss.testharness.impl.packaging.IntegrationTest;
import org.jboss.testharness.impl.packaging.Packaging;
import org.jboss.testharness.impl.packaging.PackagingType;
+import org.jboss.testharness.impl.packaging.jsr299.BeansXml;
+
import org.testng.annotations.Test;
@@ -14,9 +16,10 @@
@Artifact
@Packaging(PackagingType.EAR)
@SpecVersion(spec="cdi", version="PFD2")
+@BeansXml("beans.xml")
public class SessionBeanInterceptorDefinitionTest extends AbstractJSR299Test
{
- @Test(groups="ri-broken")
+ @Test
@SpecAssertion(section = "7.2", id = "c")
public void testSessionBeanIsIntercepted()
{
Added: cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/interceptors/definition/enterprise/beans.xml
===================================================================
--- cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/interceptors/definition/enterprise/beans.xml (rev 0)
+++ cdi-tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/interceptors/definition/enterprise/beans.xml 2009-10-15 02:57:33 UTC (rev 4104)
@@ -0,0 +1,5 @@
+<beans>
+ <interceptors>
+ <class>org.jboss.jsr299.tck.tests.interceptors.definition.enterprise.MissileInterceptor</class>
+ </interceptors>
+</beans>
\ No newline at end of file
15 years
Weld SVN: r4102 - core/trunk/osgi-bundle.
by weld-commits@lists.jboss.org
Author: pete.muir(a)jboss.org
Date: 2009-10-14 17:29:23 -0400 (Wed, 14 Oct 2009)
New Revision: 4102
Modified:
core/trunk/osgi-bundle/pom.xml
Log:
revert, lost too much info
Modified: core/trunk/osgi-bundle/pom.xml
===================================================================
--- core/trunk/osgi-bundle/pom.xml 2009-10-14 21:16:38 UTC (rev 4101)
+++ core/trunk/osgi-bundle/pom.xml 2009-10-14 21:29:23 UTC (rev 4102)
@@ -1,155 +1,146 @@
-<!--
-/*
-* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
-*
-* Copyright 1997-2008 Sun Microsystems, Inc. All rights reserved.
-*
-* Use is subject to license terms.
-*
-* Licensed under the Apache License, Version 2.0 (the "License");
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-* http://www.apache.org/licenses/LICENSE-2.0
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
--->
+
+ <!--
+ /* * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. * *
+ Copyright 1997-2008 Sun Microsystems, Inc. All rights reserved. *
+ * Use is subject to license terms. * * Licensed under the Apache
+ License, Version 2.0 (the "License"); * you may not use this file
+ except in compliance with the License. * You may obtain a copy of
+ the License at * http://www.apache.org/licenses/LICENSE-2.0 *
+ Unless required by applicable law or agreed to in writing,
+ software * distributed under the License is distributed on an "AS
+ IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ express or implied. * See the License for the specific language
+ governing permissions and * limitations under the License. */
+ -->
<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/maven-v4_0_0.xsd">
<parent>
<artifactId>weld-core-parent</artifactId>
<groupId>org.jboss.weld</groupId>
<version>1.0.0-SNAPSHOT</version>
+ <relativePath>../parent/pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
<groupId>org.jboss.weld</groupId>
<artifactId>weld-osgi-bundle</artifactId>
<name>Weld OSGi Bundle</name>
- <description>Weld implementation packaged as an OSGi bundle</description>
+ <description>Weld runtime packaged as an OSGi bundle</description>
<developers>
- <developer>
-
- <id>ss141213</id>
- <name>Sanjeeb Sahoo</name>
- <url>http://weblogs.dev.java.net/ss141213</url>
- <organization>Sun Microsystems, Inc.</organization>
- <roles>
- <role>developer</role>
-
- </roles>
- </developer>
+ <developer>
+ <id>ss141213</id>
+ <name>Sanjeeb Sahoo</name>
+ <url>http://weblogs.dev.java.net/ss141213</url>
+ <organization>Sun Microsystems, Inc.</organization>
+ <roles>
+ <role>developer</role>
+ </roles>
+ </developer>
+ <developer>
+ <name>Roger Kitain</name>
+ <id>rogerk</id>
+ <organization>Sun Microsystems, Inc.</organization>
+ </developer>
</developers>
<properties>
- <osgi.version>1.0</osgi.version>
+ <osgi.version>1.0</osgi.version>
</properties>
<build>
- <plugins>
+ <plugins>
- <plugin>
- <groupId>org.apache.felix</groupId>
- <artifactId>maven-bundle-plugin</artifactId>
- <version>2.0.0</version>
- <configuration>
- <instructions>
- <_include>-osgi.bundle</_include>
+ <plugin>
+ <groupId>org.apache.felix</groupId>
+ <artifactId>maven-bundle-plugin</artifactId>
+ <configuration>
+ <instructions>
+ <_include>-osgi.bundle</_include>
- <Embed-Dependency>*; scope=compile; inline=true</Embed-Dependency>
- <_exportcontents>javax.event; javax.context; javax.weld; javax.decorator; javax.inject; javax.enterprise.*; version=${osgi.version},
- org.jboss.weld.context; org.jboss.weld.ejb; org.jboss.weld.bean; org.jboss.weld.bean.proxy; org.jboss.weld.*.api.*; org.jboss.weld.*.spi.*; org.jboss.weld.conversation; org.jboss.weld; org.jboss.weld.bootstrap; org.jboss.weld.introspector; org.jboss.weld.servlet; version=${osgi.version},
- org.jboss.weld.el; version=${osgi.version},
- org.jboss.weld.jsf; include:="WeldPhaseListener"; version=${osgi.version},
- javassist.util.proxy;version="3.8.1.GA"
+ <Embed-Dependency>*; scope=compile; inline=true</Embed-Dependency>
+ <_exportcontents>javax.decorator;
+ javax.enterprise.*; version=${osgi.version},
+ org.jboss.weld.context; org.jboss.weld.ejb;
+ org.jboss.weld.bean; org.jboss.weld.bean.proxy;
+ org.jboss.weld.*.api.*; org.jboss.weld.*.spi.*;
+ org.jboss.weld.conversation; org.jboss.weld;
+ org.jboss.weld.bootstrap;
+ org.jboss.weld.introspector;
+ org.jboss.weld.servlet; version=${osgi.version},
+ org.jboss.weld.el; version=${osgi.version},
+ org.jboss.weld.jsf; include:="WeldPhaseListener";
+ version=${osgi.version},
+ javassist.util.proxy;version="3.8.1.GA"
</_exportcontents>
- <Import-Package>javax.annotation, javax.interceptor.*, *;resolution:=optional</Import-Package>
- <Private-Package>!javax.annotation.*, !javax.interceptor.*</Private-Package>
- </instructions>
- <!-- Maven uses the output directory (target/classes)
- rather than the final bundle, when compiling against
- projects in the same reactor (ie. the same build).
- Since this jar comprises of classes that come from
- some other jar and other modules may depend on this
- artifact, we need to unpack.
- -->
- <unpackBundle>true</unpackBundle>
-
- </configuration>
- <executions>
- <execution>
- <id>osgi-bundle</id>
- <goals>
- <goal>bundle</goal>
- </goals>
- <phase>package</phase>
-
- </execution>
- </executions>
- </plugin>
- </plugins>
+ <Import-Package>javax.annotation, javax.interceptor,
+ *;resolution:=optional</Import-Package>
+ <Private-Package>!javax.annotation.*,
+ !javax.interceptor.*</Private-Package>
+ </instructions>
+ <!--
+ Maven uses the output directory (target/classes)
+ rather than the final bundle, when compiling against
+ projects in the same reactor (ie. the same build).
+ Since this jar comprises of classes that come from
+ some other jar and other modules may depend on this
+ artifact, we need to unpack.
+ -->
+ <unpackBundle>true</unpackBundle>
+ </configuration>
+ <executions>
+ <execution>
+ <id>osgi-bundle</id>
+ <goals>
+ <goal>bundle</goal>
+ </goals>
+ <phase>package</phase>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
</build>
<dependencies>
- <dependency>
- <groupId>javax.enterprise</groupId>
- <artifactId>cdi-api</artifactId>
- </dependency>
+
+ <dependency>
+ <groupId>javax.enterprise</groupId>
+ <artifactId>cdi-api</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>org.jboss.weld</groupId>
+ <artifactId>weld-api</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>org.jboss.weld</groupId>
+ <artifactId>weld-spi</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>org.jboss.weld</groupId>
+ <artifactId>weld-core</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>org.jboss.weld</groupId>
+ <artifactId>weld-logging</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>javassist</groupId>
+ <artifactId>javassist</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>com.google.collections</groupId>
+ <artifactId>google-collections</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>javax.inject</groupId>
+ <artifactId>javax.inject</artifactId>
+ </dependency>
- <dependency>
- <groupId>org.jboss.weld</groupId>
- <artifactId>weld-api</artifactId>
- </dependency>
-
- <dependency>
- <groupId>org.jboss.weld</groupId>
- <artifactId>weld-core</artifactId>
- </dependency>
-
- <dependency>
- <groupId>org.jboss.weld</groupId>
- <artifactId>weld-spi</artifactId>
- </dependency>
-
- <dependency>
- <groupId>javax.enterprise</groupId>
- <artifactId>cdi-api</artifactId>
- </dependency>
-
- <dependency>
- <groupId>org.jboss.weld</groupId>
- <artifactId>weld-logging</artifactId>
- </dependency>
-
- <dependency>
- <groupId>javassist</groupId>
- <artifactId>javassist</artifactId>
- </dependency>
-
- <dependency>
- <groupId>com.google.collections</groupId>
- <artifactId>google-collections</artifactId>
- </dependency>
-
- <dependency>
- <groupId>javax.inject</groupId>
- <artifactId>inject-api</artifactId>
- <version>1.0.0-PRD</version>
- </dependency>
-
- <dependency>
- <groupId>org.jboss.interceptor</groupId>
- <artifactId>jboss-interceptor</artifactId>
- <version>1.0.0-CR1</version>
- </dependency>
-
- <dependency>
- <groupId>commons-logging</groupId>
- <artifactId>commons-logging</artifactId>
- <version>1.1.1</version>
- </dependency>
-
</dependencies>
+
</project>
15 years
Weld SVN: r4101 - core/trunk/osgi-bundle.
by weld-commits@lists.jboss.org
Author: rogerk
Date: 2009-10-14 17:16:38 -0400 (Wed, 14 Oct 2009)
New Revision: 4101
Modified:
core/trunk/osgi-bundle/pom.xml
Log:
updated to work
Modified: core/trunk/osgi-bundle/pom.xml
===================================================================
--- core/trunk/osgi-bundle/pom.xml 2009-10-14 20:07:37 UTC (rev 4100)
+++ core/trunk/osgi-bundle/pom.xml 2009-10-14 21:16:38 UTC (rev 4101)
@@ -1,146 +1,155 @@
-
- <!--
- /* * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. * *
- Copyright 1997-2008 Sun Microsystems, Inc. All rights reserved. *
- * Use is subject to license terms. * * Licensed under the Apache
- License, Version 2.0 (the "License"); * you may not use this file
- except in compliance with the License. * You may obtain a copy of
- the License at * http://www.apache.org/licenses/LICENSE-2.0 *
- Unless required by applicable law or agreed to in writing,
- software * distributed under the License is distributed on an "AS
- IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- express or implied. * See the License for the specific language
- governing permissions and * limitations under the License. */
- -->
+<!--
+/*
+* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
+*
+* Copyright 1997-2008 Sun Microsystems, Inc. All rights reserved.
+*
+* Use is subject to license terms.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+* http://www.apache.org/licenses/LICENSE-2.0
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+-->
<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/maven-v4_0_0.xsd">
<parent>
<artifactId>weld-core-parent</artifactId>
<groupId>org.jboss.weld</groupId>
<version>1.0.0-SNAPSHOT</version>
- <relativePath>../parent/pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
<groupId>org.jboss.weld</groupId>
<artifactId>weld-osgi-bundle</artifactId>
<name>Weld OSGi Bundle</name>
- <description>Weld runtime packaged as an OSGi bundle</description>
+ <description>Weld implementation packaged as an OSGi bundle</description>
<developers>
- <developer>
- <id>ss141213</id>
- <name>Sanjeeb Sahoo</name>
- <url>http://weblogs.dev.java.net/ss141213</url>
- <organization>Sun Microsystems, Inc.</organization>
- <roles>
- <role>developer</role>
- </roles>
- </developer>
- <developer>
- <name>Roger Kitain</name>
- <id>rogerk</id>
- <organization>Sun Microsystems, Inc.</organization>
- </developer>
+ <developer>
+
+ <id>ss141213</id>
+ <name>Sanjeeb Sahoo</name>
+ <url>http://weblogs.dev.java.net/ss141213</url>
+ <organization>Sun Microsystems, Inc.</organization>
+ <roles>
+ <role>developer</role>
+
+ </roles>
+ </developer>
</developers>
<properties>
- <osgi.version>1.0</osgi.version>
+ <osgi.version>1.0</osgi.version>
</properties>
<build>
- <plugins>
+ <plugins>
- <plugin>
- <groupId>org.apache.felix</groupId>
- <artifactId>maven-bundle-plugin</artifactId>
- <configuration>
- <instructions>
- <_include>-osgi.bundle</_include>
+ <plugin>
+ <groupId>org.apache.felix</groupId>
+ <artifactId>maven-bundle-plugin</artifactId>
+ <version>2.0.0</version>
+ <configuration>
+ <instructions>
+ <_include>-osgi.bundle</_include>
- <Embed-Dependency>*; scope=compile; inline=true</Embed-Dependency>
- <_exportcontents>javax.decorator;
- javax.enterprise.*; version=${osgi.version},
- org.jboss.weld.context; org.jboss.weld.ejb;
- org.jboss.weld.bean; org.jboss.weld.bean.proxy;
- org.jboss.weld.*.api.*; org.jboss.weld.*.spi.*;
- org.jboss.weld.conversation; org.jboss.weld;
- org.jboss.weld.bootstrap;
- org.jboss.weld.introspector;
- org.jboss.weld.servlet; version=${osgi.version},
- org.jboss.weld.el; version=${osgi.version},
- org.jboss.weld.jsf; include:="WeldPhaseListener";
- version=${osgi.version},
- javassist.util.proxy;version="3.8.1.GA"
+ <Embed-Dependency>*; scope=compile; inline=true</Embed-Dependency>
+ <_exportcontents>javax.event; javax.context; javax.weld; javax.decorator; javax.inject; javax.enterprise.*; version=${osgi.version},
+ org.jboss.weld.context; org.jboss.weld.ejb; org.jboss.weld.bean; org.jboss.weld.bean.proxy; org.jboss.weld.*.api.*; org.jboss.weld.*.spi.*; org.jboss.weld.conversation; org.jboss.weld; org.jboss.weld.bootstrap; org.jboss.weld.introspector; org.jboss.weld.servlet; version=${osgi.version},
+ org.jboss.weld.el; version=${osgi.version},
+ org.jboss.weld.jsf; include:="WeldPhaseListener"; version=${osgi.version},
+ javassist.util.proxy;version="3.8.1.GA"
</_exportcontents>
- <Import-Package>javax.annotation, javax.interceptor,
- *;resolution:=optional</Import-Package>
- <Private-Package>!javax.annotation.*,
- !javax.interceptor.*</Private-Package>
- </instructions>
- <!--
- Maven uses the output directory (target/classes)
- rather than the final bundle, when compiling against
- projects in the same reactor (ie. the same build).
- Since this jar comprises of classes that come from
- some other jar and other modules may depend on this
- artifact, we need to unpack.
- -->
- <unpackBundle>true</unpackBundle>
- </configuration>
- <executions>
- <execution>
- <id>osgi-bundle</id>
- <goals>
- <goal>bundle</goal>
- </goals>
- <phase>package</phase>
- </execution>
- </executions>
- </plugin>
- </plugins>
+ <Import-Package>javax.annotation, javax.interceptor.*, *;resolution:=optional</Import-Package>
+ <Private-Package>!javax.annotation.*, !javax.interceptor.*</Private-Package>
+ </instructions>
+ <!-- Maven uses the output directory (target/classes)
+ rather than the final bundle, when compiling against
+ projects in the same reactor (ie. the same build).
+ Since this jar comprises of classes that come from
+ some other jar and other modules may depend on this
+ artifact, we need to unpack.
+ -->
+ <unpackBundle>true</unpackBundle>
+
+ </configuration>
+ <executions>
+ <execution>
+ <id>osgi-bundle</id>
+ <goals>
+ <goal>bundle</goal>
+ </goals>
+ <phase>package</phase>
+
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
</build>
<dependencies>
-
- <dependency>
- <groupId>javax.enterprise</groupId>
- <artifactId>cdi-api</artifactId>
- </dependency>
-
- <dependency>
- <groupId>org.jboss.weld</groupId>
- <artifactId>weld-api</artifactId>
- </dependency>
-
- <dependency>
- <groupId>org.jboss.weld</groupId>
- <artifactId>weld-spi</artifactId>
- </dependency>
-
- <dependency>
- <groupId>org.jboss.weld</groupId>
- <artifactId>weld-core</artifactId>
- </dependency>
-
- <dependency>
- <groupId>org.jboss.weld</groupId>
- <artifactId>weld-logging</artifactId>
- </dependency>
-
- <dependency>
- <groupId>javassist</groupId>
- <artifactId>javassist</artifactId>
- </dependency>
-
- <dependency>
- <groupId>com.google.collections</groupId>
- <artifactId>google-collections</artifactId>
- </dependency>
-
- <dependency>
- <groupId>javax.inject</groupId>
- <artifactId>javax.inject</artifactId>
- </dependency>
+ <dependency>
+ <groupId>javax.enterprise</groupId>
+ <artifactId>cdi-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.weld</groupId>
+ <artifactId>weld-api</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>org.jboss.weld</groupId>
+ <artifactId>weld-core</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>org.jboss.weld</groupId>
+ <artifactId>weld-spi</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>javax.enterprise</groupId>
+ <artifactId>cdi-api</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>org.jboss.weld</groupId>
+ <artifactId>weld-logging</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>javassist</groupId>
+ <artifactId>javassist</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>com.google.collections</groupId>
+ <artifactId>google-collections</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>javax.inject</groupId>
+ <artifactId>inject-api</artifactId>
+ <version>1.0.0-PRD</version>
+ </dependency>
+
+ <dependency>
+ <groupId>org.jboss.interceptor</groupId>
+ <artifactId>jboss-interceptor</artifactId>
+ <version>1.0.0-CR1</version>
+ </dependency>
+
+ <dependency>
+ <groupId>commons-logging</groupId>
+ <artifactId>commons-logging</artifactId>
+ <version>1.1.1</version>
+ </dependency>
+
</dependencies>
-
</project>
15 years