You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ws.apache.org by ve...@apache.org on 2011/10/09 14:59:01 UTC
svn commit: r1180602 - in /webservices/commons/trunk/modules/axiom: ./
modules/axiom-all/ modules/axiom-api/
modules/axiom-api/src/main/java/org/apache/axiom/locator/
modules/axiom-api/src/main/java/org/apache/axiom/om/
modules/axiom-api/src/main/java/...
Author: veithen
Date: Sun Oct 9 12:59:00 2011
New Revision: 1180602
URL: http://svn.apache.org/viewvc?rev=1180602&view=rev
Log:
Integrated the redesigned OSGi support into the trunk.
Added:
webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/locator/
- copied from r1180596, webservices/axiom/branches/osgi-redesign/modules/axiom-api/src/main/java/org/apache/axiom/locator/
webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/locator/Activator.java
- copied unchanged from r1180596, webservices/axiom/branches/osgi-redesign/modules/axiom-api/src/main/java/org/apache/axiom/locator/Activator.java
webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/locator/DefaultLoader.java
- copied unchanged from r1180596, webservices/axiom/branches/osgi-redesign/modules/axiom-api/src/main/java/org/apache/axiom/locator/DefaultLoader.java
webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/locator/DefaultOMMetaFactoryLocator.java
- copied unchanged from r1180596, webservices/axiom/branches/osgi-redesign/modules/axiom-api/src/main/java/org/apache/axiom/locator/DefaultOMMetaFactoryLocator.java
webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/locator/Feature.java
- copied unchanged from r1180596, webservices/axiom/branches/osgi-redesign/modules/axiom-api/src/main/java/org/apache/axiom/locator/Feature.java
webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/locator/Implementation.java
- copied unchanged from r1180596, webservices/axiom/branches/osgi-redesign/modules/axiom-api/src/main/java/org/apache/axiom/locator/Implementation.java
webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/locator/ImplementationFactory.java
- copied unchanged from r1180596, webservices/axiom/branches/osgi-redesign/modules/axiom-api/src/main/java/org/apache/axiom/locator/ImplementationFactory.java
webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/locator/Loader.java
- copied unchanged from r1180596, webservices/axiom/branches/osgi-redesign/modules/axiom-api/src/main/java/org/apache/axiom/locator/Loader.java
webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/locator/OSGiLoader.java
- copied unchanged from r1180596, webservices/axiom/branches/osgi-redesign/modules/axiom-api/src/main/java/org/apache/axiom/locator/OSGiLoader.java
webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/locator/OSGiOMMetaFactoryLocator.java
- copied unchanged from r1180596, webservices/axiom/branches/osgi-redesign/modules/axiom-api/src/main/java/org/apache/axiom/locator/OSGiOMMetaFactoryLocator.java
webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/locator/PriorityBasedOMMetaFactoryLocator.java
- copied unchanged from r1180596, webservices/axiom/branches/osgi-redesign/modules/axiom-api/src/main/java/org/apache/axiom/locator/PriorityBasedOMMetaFactoryLocator.java
webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/locator/RegisteredImplementation.java
- copied unchanged from r1180596, webservices/axiom/branches/osgi-redesign/modules/axiom-api/src/main/java/org/apache/axiom/locator/RegisteredImplementation.java
webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/locator/package.html
- copied unchanged from r1180596, webservices/axiom/branches/osgi-redesign/modules/axiom-api/src/main/java/org/apache/axiom/locator/package.html
webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/om/OMMetaFactoryLocator.java
- copied unchanged from r1180596, webservices/axiom/branches/osgi-redesign/modules/axiom-api/src/main/java/org/apache/axiom/om/OMMetaFactoryLocator.java
webservices/commons/trunk/modules/axiom/modules/axiom-buildutils/src/main/java/org/apache/axiom/buildutils/AxiomXmlResourceTransformer.java
- copied unchanged from r1180596, webservices/axiom/branches/osgi-redesign/modules/axiom-buildutils/src/main/java/org/apache/axiom/buildutils/AxiomXmlResourceTransformer.java
webservices/commons/trunk/modules/axiom/modules/axiom-buildutils/src/main/java/org/apache/axiom/buildutils/DOMUtils.java
- copied unchanged from r1180596, webservices/axiom/branches/osgi-redesign/modules/axiom-buildutils/src/main/java/org/apache/axiom/buildutils/DOMUtils.java
webservices/commons/trunk/modules/axiom/modules/axiom-dom/src/main/resources/META-INF/axiom.xml
- copied unchanged from r1180596, webservices/axiom/branches/osgi-redesign/modules/axiom-dom/src/main/resources/META-INF/axiom.xml
webservices/commons/trunk/modules/axiom/modules/axiom-dom/src/test/java/org/apache/axiom/om/impl/dom/factory/DOMFeatureTest.java
- copied unchanged from r1180596, webservices/axiom/branches/osgi-redesign/modules/axiom-dom/src/test/java/org/apache/axiom/om/impl/dom/factory/DOMFeatureTest.java
webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/resources/META-INF/axiom.xml
- copied unchanged from r1180596, webservices/axiom/branches/osgi-redesign/modules/axiom-impl/src/main/resources/META-INF/axiom.xml
Removed:
webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/osgi/
Modified:
webservices/commons/trunk/modules/axiom/ (props changed)
webservices/commons/trunk/modules/axiom/modules/axiom-all/pom.xml
webservices/commons/trunk/modules/axiom/modules/axiom-api/pom.xml
webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/om/OMAbstractFactory.java
webservices/commons/trunk/modules/axiom/modules/axiom-buildutils/src/main/java/org/apache/axiom/buildutils/PluginXmlResourceTransformer.java
webservices/commons/trunk/modules/axiom/modules/axiom-dom/pom.xml
webservices/commons/trunk/modules/axiom/modules/axiom-dom/src/main/java/org/apache/axiom/om/impl/dom/DOOMAbstractFactory.java
webservices/commons/trunk/modules/axiom/modules/axiom-dom/src/main/java/org/apache/axiom/om/impl/dom/factory/OMDOMMetaFactory.java
webservices/commons/trunk/modules/axiom/modules/axiom-impl/pom.xml
webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/factory/OMLinkedListMetaFactory.java
webservices/commons/trunk/modules/axiom/modules/axiom-osgi-tests/pom.xml
webservices/commons/trunk/modules/axiom/modules/axiom-parent/pom.xml
webservices/commons/trunk/modules/axiom/modules/axiom-testutils/pom.xml
webservices/commons/trunk/modules/axiom/pom.xml
Propchange: webservices/commons/trunk/modules/axiom/
------------------------------------------------------------------------------
svn:mergeinfo = /webservices/axiom/branches/osgi-redesign:1180368-1180596
Modified: webservices/commons/trunk/modules/axiom/modules/axiom-all/pom.xml
URL: http://svn.apache.org/viewvc/webservices/commons/trunk/modules/axiom/modules/axiom-all/pom.xml?rev=1180602&r1=1180601&r2=1180602&view=diff
==============================================================================
--- webservices/commons/trunk/modules/axiom/modules/axiom-all/pom.xml (original)
+++ webservices/commons/trunk/modules/axiom/modules/axiom-all/pom.xml Sun Oct 9 12:59:00 2011
@@ -77,9 +77,19 @@
<include>${project.groupId}:*</include>
</includes>
</artifactSet>
+ <transformers>
+ <transformer implementation="org.apache.axiom.buildutils.AxiomXmlResourceTransformer" />
+ </transformers>
</configuration>
</execution>
</executions>
+ <dependencies>
+ <dependency>
+ <groupId>${project.groupId}</groupId>
+ <artifactId>axiom-buildutils</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ </dependencies>
</plugin>
<plugin>
<!-- If we deploy the uber-JAR to the Maven repositories, then we will end up with
Modified: webservices/commons/trunk/modules/axiom/modules/axiom-api/pom.xml
URL: http://svn.apache.org/viewvc/webservices/commons/trunk/modules/axiom/modules/axiom-api/pom.xml?rev=1180602&r1=1180601&r2=1180602&view=diff
==============================================================================
--- webservices/commons/trunk/modules/axiom/modules/axiom-api/pom.xml (original)
+++ webservices/commons/trunk/modules/axiom/modules/axiom-api/pom.xml Sun Oct 9 12:59:00 2011
@@ -63,6 +63,16 @@
<artifactId>apache-mime4j-core</artifactId>
</dependency>
<dependency>
+ <groupId>org.osgi</groupId>
+ <artifactId>org.osgi.core</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.osgi</groupId>
+ <artifactId>org.osgi.compendium</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<scope>test</scope>
@@ -217,13 +227,10 @@
<_removeheaders>Private-Package</_removeheaders>
<Export-Package>*;-noimport:=true</Export-Package>
<Import-Package>org.jaxen.*;resolution:=optional,*</Import-Package>
+ <Bundle-Activator>org.apache.axiom.locator.Activator</Bundle-Activator>
</instructions>
</configuration>
</plugin>
- <plugin>
- <groupId>org.apache.felix</groupId>
- <artifactId>maven-scr-plugin</artifactId>
- </plugin>
<!--
Attach a JAR with the test classes so that we can reuse them in
other modules (see
Modified: webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/om/OMAbstractFactory.java
URL: http://svn.apache.org/viewvc/webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/om/OMAbstractFactory.java?rev=1180602&r1=1180601&r2=1180602&view=diff
==============================================================================
--- webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/om/OMAbstractFactory.java (original)
+++ webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/om/OMAbstractFactory.java Sun Oct 9 12:59:00 2011
@@ -19,19 +19,32 @@
package org.apache.axiom.om;
-import java.io.BufferedReader;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.InputStreamReader;
-
import org.apache.axiom.soap.SOAPFactory;
/**
- * Provides default instances for object model and meta factories.
+ * Provides instances for object model and meta factories.
+ * <p>
+ * The {@link #getMetaFactory()} method returns the {@link OMMetaFactory} instance for the default
+ * Axiom implementation. The {@link #getMetaFactory(String)} method locates a {@link OMMetaFactory}
+ * instance for an Axiom implementation with a given feature. The following features are predefined
+ * by the Axiom API:
+ * <dl>
+ * <dt>{@link #FEATURE_DEFAULT}
+ * <dd>Identifies the default Axiom implementation. An implementation with that feature is expected
+ * to provide a full implementation of the Axiom API.
+ * <dt>{@link #FEATURE_DOM}
+ * <dd>Used by Axiom implementations that implement DOM in addition to the Axiom API.
+ * </dl>
+ * Implementations may define other custom features.
* <p>
- * The {@link #getMetaFactory()} method returns the default {@link OMMetaFactory} instance.
- * See the Javadoc of the {@link #getMetaFactory()} method for details about how this
- * instance is determined.
+ * Axiom discovers implementations by looking for <tt>META-INF/axiom.xml</tt> resources. They
+ * specify the {@link OMMetaFactory} implementation as well as the set of features that each
+ * implementation supports. If multiple implementations with the same feature are found, then Axiom
+ * will select the one with the highest priority. The priority for a given feature is also declared
+ * in <tt>META-INF/axiom.xml</tt>. This algorithm is used both in non OSGi and OSGi environments.
+ * <p>
+ * In a non OSGi environment, the default Axiom implementation can be overridden using the system
+ * property specified by {@link #META_FACTORY_NAME_PROPERTY}.
* <p>
* The {@link #getOMFactory()}, {@link #getSOAP11Factory()} and {@link #getSOAP12Factory()}
* methods return default instances for plain XML, SOAP 1.1 and SOAP 1.2 object model factories.
@@ -46,132 +59,103 @@ import org.apache.axiom.soap.SOAPFactory
public class OMAbstractFactory {
public static final String META_FACTORY_NAME_PROPERTY = "org.apache.axiom.om.OMMetaFactory";
- private static final String DEFAULT_META_FACTORY_CLASS_NAME =
- "org.apache.axiom.om.impl.llom.factory.OMLinkedListMetaFactory";
-
/**
- * The default {@link OMMetaFactory} instance determined by the system
- * property {@link #META_FACTORY_NAME_PROPERTY}, or if no such system
- * property is set, by the value of the
- * {@link #DEFAULT_META_FACTORY_CLASS_NAME} constant.
+ * Feature for Axiom implementations that can be used as default implementations.
*/
- private static OMMetaFactory defaultMetaFactory;
+ public static final String FEATURE_DEFAULT = "default";
/**
- * The {@link OMMetaFactory} set through
- * {@link #setMetaFactory(OMMetaFactory)}. If this is <code>null</code>,
- * then {@link #defaultMetaFactory} will be returned by
- * {@link #getMetaFactory()}.
+ * Feature for Axiom implementations that implement DOM in addition to the Axiom API.
*/
- private static OMMetaFactory metaFactory;
+ public static final String FEATURE_DOM = "dom";
+
+ private static final String DEFAULT_LOCATOR_CLASS_NAME =
+ "org.apache.axiom.locator.DefaultOMMetaFactoryLocator";
+ /**
+ * The default {@link OMMetaFactoryLocator} that will be used if no locator has been set
+ * explicitly.
+ */
+ private static final OMMetaFactoryLocator defaultMetaFactoryLocator;
+
+ /**
+ * The {@link OMMetaFactoryLocator} set through
+ * {@link #setMetaFactoryLocator(OMMetaFactoryLocator)}. If this is <code>null</code>, then
+ * {@link #defaultMetaFactoryLocator} will be used.
+ */
+ private static volatile OMMetaFactoryLocator metaFactoryLocator;
+
+ static {
+ // We could actually instantiate the default locator directly, but doing it using
+ // reflection avoids introducing a circular dependency between the org.apache.axiom.om
+ // and org.apache.axiom.locator packages.
+ try {
+ defaultMetaFactoryLocator = (OMMetaFactoryLocator)Class.forName(DEFAULT_LOCATOR_CLASS_NAME).newInstance();
+ } catch (InstantiationException ex) {
+ throw new InstantiationError(ex.getMessage());
+ } catch (IllegalAccessException ex) {
+ throw new IllegalAccessError(ex.getMessage());
+ } catch (ClassNotFoundException ex) {
+ throw new NoClassDefFoundError(ex.getMessage());
+ }
+ }
+
private OMAbstractFactory() {}
/**
- * Explicitly set a meta factory instance. The new instance will be returned
- * by all subsequent calls to {@link #getMetaFactory()}. Note that this is
- * an application wide setting. More precisely, the configured meta factory
- * will be used by all classes loaded from the class loader where Axiom is
- * deployed and all its child class loaders. Therefore this method should be
- * used with care and only be invoked during the initialization of the
- * application.
+ * Explicitly set a meta factory locator. The new locator will be used by all subsequent calls
+ * to {@link #getMetaFactory()} and {@link #getMetaFactory(String)} to locate the appropriate
+ * meta factory. Note that the meta factory locator is an application wide setting. More
+ * precisely, the configured locator will be used by all classes loaded from the class loader
+ * where Axiom is deployed and all its child class loaders. Therefore this method should be used
+ * with care and only be invoked during the initialization of the application.
* <p>
- * When Axiom is deployed as a bundle in an OSGi environment, this method
- * will be used to inject the meta factory instance from the implementation
- * bundle.
+ * When Axiom is deployed as a bundle in an OSGi environment, this method will be used to inject
+ * the meta factory instances from the deployed implementation bundles.
*
- * @param newMetaFactory
- * the new meta factory instance, or <code>null</code> to revert
- * to the default meta factory instance determined by the
- * <code>org.apache.axiom.om.OMMetaFactory</code> system property
- */
- public static void setMetaFactory(OMMetaFactory newMetaFactory) {
- metaFactory = newMetaFactory;
+ * @param locator
+ * the new meta factory locator, or <code>null</code> to revert to the default meta
+ * factory locator
+ */
+ public static void setMetaFactoryLocator(OMMetaFactoryLocator locator) {
+ metaFactoryLocator = locator;
}
/**
- * Get the default meta factory instance. This method uses the following ordered lookup
- * procedure to determine the default instance:
- * <ol>
- * <li>If an instance has been set using {@link #setMetaFactory(OMMetaFactory)}, then that
- * instance is returned. Note that this will be the case in an OSGi runtime, where
- * {@link #setMetaFactory(OMMetaFactory)} is invoked by a helper component that is part of
- * Axiom.
- * <li>Use the <code>org.apache.axiom.om.OMMetaFactory</code> system property. This method uses
- * {@link System#getProperty(String)} to determine the value of the system property. A
- * {@link SecurityException} thrown by this method is simply ignored and the lookup procedure
- * continues.
- * <li>Use the JDK 1.3 service discovery mechanism to determine the classname of the meta
- * factory. The method will look for a classname in the file
- * <code>META-INF/services/org.apache.axiom.om.OMMetaFactory</code> in jars in the class path.
- * <li>Return the meta factory for the LLOM implementation is returned.
- * </ol>
+ * Get the meta factory instance for the default Axiom implementation. This method is equivalent
+ * to {@link #getMetaFactory(String)} with {@link #FEATURE_DEFAULT} as parameter.
*
- * @return the default OM factory instance
+ * @return the meta factory instance for the default Axiom implementation
* @throws OMException
- * if the factory's implementation class can't be found or if the class can't be
- * instantiated
+ * if no Axiom implementation with {@link #FEATURE_DEFAULT} could be located
*/
public static OMMetaFactory getMetaFactory() {
- if (metaFactory != null) {
+ return getMetaFactory(FEATURE_DEFAULT);
+ }
+
+ /**
+ * Get the meta factory instance for the Axiom implementation with a given feature. If multiple
+ * Axiom implementations declare the same feature, then the method will return the meta factory
+ * for the implementation that declares the highest priority for that feature in its
+ * <tt>META-INF/axiom.xml</tt> descriptor.
+ *
+ * @param feature
+ * the requested feature
+ * @return the meta factory instance for the Axiom implementation with the given feature.
+ * @throws OMException
+ * if no Axiom implementation with the requested feature could be located
+ */
+ public static OMMetaFactory getMetaFactory(String feature) {
+ OMMetaFactoryLocator locator = metaFactoryLocator;
+ if (locator == null) {
+ locator = defaultMetaFactoryLocator;
+ }
+ OMMetaFactory metaFactory = locator.getOMMetaFactory(feature);
+ if (metaFactory == null) {
+ throw new OMException("No meta factory found for feature '" + feature + "'");
+ } else {
return metaFactory;
}
-
- if (defaultMetaFactory != null) {
- return defaultMetaFactory;
- }
-
- String metaFactoryClassName = null;
-
- // First try system property
- try {
- metaFactoryClassName = System.getProperty(META_FACTORY_NAME_PROPERTY);
- if ("".equals(metaFactoryClassName)) {
- metaFactoryClassName = null;
- }
- } catch (SecurityException e) {
- // Ignore and continue
- }
-
- // Next use JDK 1.3 service discovery
- if (metaFactoryClassName == null) {
- try {
- InputStream in = OMAbstractFactory.class.getResourceAsStream("/META-INF/services/" + OMMetaFactory.class.getName());
- if (in != null) {
- try {
- BufferedReader r = new BufferedReader(new InputStreamReader(in));
- String line;
- while ((line = r.readLine()) != null) {
- line = line.trim();
- if (line.length() > 0 && !line.startsWith("#")) {
- metaFactoryClassName = line;
- break;
- }
- }
- } finally {
- in.close();
- }
- }
- } catch (IOException ex) {
- // Ignore and continue
- }
- }
-
- // Default to LLOM
- if (metaFactoryClassName == null) {
- metaFactoryClassName = DEFAULT_META_FACTORY_CLASS_NAME;
- }
-
- try {
- defaultMetaFactory = (OMMetaFactory) Class.forName(metaFactoryClassName).newInstance();
- } catch (InstantiationException e) {
- throw new OMException(e);
- } catch (IllegalAccessException e) {
- throw new OMException(e);
- } catch (ClassNotFoundException e) {
- throw new OMException(e);
- }
- return defaultMetaFactory;
}
/**
Modified: webservices/commons/trunk/modules/axiom/modules/axiom-buildutils/src/main/java/org/apache/axiom/buildutils/PluginXmlResourceTransformer.java
URL: http://svn.apache.org/viewvc/webservices/commons/trunk/modules/axiom/modules/axiom-buildutils/src/main/java/org/apache/axiom/buildutils/PluginXmlResourceTransformer.java?rev=1180602&r1=1180601&r2=1180602&view=diff
==============================================================================
--- webservices/commons/trunk/modules/axiom/modules/axiom-buildutils/src/main/java/org/apache/axiom/buildutils/PluginXmlResourceTransformer.java (original)
+++ webservices/commons/trunk/modules/axiom/modules/axiom-buildutils/src/main/java/org/apache/axiom/buildutils/PluginXmlResourceTransformer.java Sun Oct 9 12:59:00 2011
@@ -24,18 +24,10 @@ import java.util.List;
import java.util.jar.JarEntry;
import java.util.jar.JarOutputStream;
-import javax.xml.parsers.DocumentBuilderFactory;
-import javax.xml.parsers.ParserConfigurationException;
-import javax.xml.transform.TransformerException;
-import javax.xml.transform.TransformerFactory;
-import javax.xml.transform.dom.DOMSource;
-import javax.xml.transform.stream.StreamResult;
-
import org.apache.maven.plugins.shade.resource.ResourceTransformer;
import org.w3c.dom.Document;
import org.w3c.dom.Element;
import org.w3c.dom.Node;
-import org.xml.sax.SAXException;
/**
* Quick and dirty hack to adjust the groupId/artifactId/version in a shaded Maven plugin.
@@ -58,13 +50,7 @@ public class PluginXmlResourceTransforme
}
public void processResource(String resource, InputStream is, List relocators) throws IOException {
- try {
- pluginXml = DocumentBuilderFactory.newInstance().newDocumentBuilder().parse(is);
- } catch (SAXException ex) {
- throw toIOException(ex);
- } catch (ParserConfigurationException ex) {
- throw toIOException(ex);
- }
+ pluginXml = DOMUtils.parse(is);
is.close();
Node node = pluginXml.getDocumentElement().getFirstChild();
while (node != null) {
@@ -85,16 +71,6 @@ public class PluginXmlResourceTransforme
public void modifyOutputStream(JarOutputStream os) throws IOException {
os.putNextEntry(new JarEntry(PLUGIN_XML));
- try {
- TransformerFactory.newInstance().newTransformer().transform(new DOMSource(pluginXml), new StreamResult(os));
- } catch (TransformerException ex) {
- throw toIOException(ex);
- }
- }
-
- private IOException toIOException(Exception ex) {
- IOException ioException = new IOException();
- ioException.initCause(ex);
- return ioException;
+ DOMUtils.serialize(pluginXml, os);
}
}
Modified: webservices/commons/trunk/modules/axiom/modules/axiom-dom/pom.xml
URL: http://svn.apache.org/viewvc/webservices/commons/trunk/modules/axiom/modules/axiom-dom/pom.xml?rev=1180602&r1=1180601&r2=1180602&view=diff
==============================================================================
--- webservices/commons/trunk/modules/axiom/modules/axiom-dom/pom.xml (original)
+++ webservices/commons/trunk/modules/axiom/modules/axiom-dom/pom.xml Sun Oct 9 12:59:00 2011
@@ -136,10 +136,6 @@
</instructions>
</configuration>
</plugin>
- <plugin>
- <groupId>org.apache.felix</groupId>
- <artifactId>maven-scr-plugin</artifactId>
- </plugin>
<plugin>
<groupId>${project.groupId}</groupId>
<artifactId>shade-plugin-patched</artifactId>
Modified: webservices/commons/trunk/modules/axiom/modules/axiom-dom/src/main/java/org/apache/axiom/om/impl/dom/DOOMAbstractFactory.java
URL: http://svn.apache.org/viewvc/webservices/commons/trunk/modules/axiom/modules/axiom-dom/src/main/java/org/apache/axiom/om/impl/dom/DOOMAbstractFactory.java?rev=1180602&r1=1180601&r2=1180602&view=diff
==============================================================================
--- webservices/commons/trunk/modules/axiom/modules/axiom-dom/src/main/java/org/apache/axiom/om/impl/dom/DOOMAbstractFactory.java (original)
+++ webservices/commons/trunk/modules/axiom/modules/axiom-dom/src/main/java/org/apache/axiom/om/impl/dom/DOOMAbstractFactory.java Sun Oct 9 12:59:00 2011
@@ -19,12 +19,17 @@
package org.apache.axiom.om.impl.dom;
+import org.apache.axiom.om.OMAbstractFactory;
import org.apache.axiom.om.OMFactory;
import org.apache.axiom.om.impl.dom.factory.OMDOMFactory;
import org.apache.axiom.soap.SOAPFactory;
import org.apache.axiom.soap.impl.dom.soap11.SOAP11Factory;
import org.apache.axiom.soap.impl.dom.soap12.SOAP12Factory;
+/**
+ * @deprecated Use {@link OMAbstractFactory#getMetaFactory(String)} with
+ * {@link OMAbstractFactory#FEATURE_DOM} to get a meta factory for DOOM.
+ */
public class DOOMAbstractFactory {
public static OMFactory getOMFactory() {
Modified: webservices/commons/trunk/modules/axiom/modules/axiom-dom/src/main/java/org/apache/axiom/om/impl/dom/factory/OMDOMMetaFactory.java
URL: http://svn.apache.org/viewvc/webservices/commons/trunk/modules/axiom/modules/axiom-dom/src/main/java/org/apache/axiom/om/impl/dom/factory/OMDOMMetaFactory.java?rev=1180602&r1=1180601&r2=1180602&view=diff
==============================================================================
--- webservices/commons/trunk/modules/axiom/modules/axiom-dom/src/main/java/org/apache/axiom/om/impl/dom/factory/OMDOMMetaFactory.java (original)
+++ webservices/commons/trunk/modules/axiom/modules/axiom-dom/src/main/java/org/apache/axiom/om/impl/dom/factory/OMDOMMetaFactory.java Sun Oct 9 12:59:00 2011
@@ -31,10 +31,6 @@ import org.apache.axiom.soap.impl.dom.so
* As explained in {@link OMDOMFactory}, OM factories for DOOM are not stateless.
* Therefore {@link #getOMFactory()}, {@link #getSOAP11Factory()} and
* {@link #getSOAP12Factory()} will return a new instance on every invocation.
- *
- * @scr.component name="metafactory.dom.component" immediate="true"
- * @scr.service interface="org.apache.axiom.om.OMMetaFactory"
- * @scr.property name="implementationName" type="String" value="doom"
*/
public class OMDOMMetaFactory extends AbstractOMMetaFactory {
public OMFactory getOMFactory() {
Modified: webservices/commons/trunk/modules/axiom/modules/axiom-impl/pom.xml
URL: http://svn.apache.org/viewvc/webservices/commons/trunk/modules/axiom/modules/axiom-impl/pom.xml?rev=1180602&r1=1180601&r2=1180602&view=diff
==============================================================================
--- webservices/commons/trunk/modules/axiom/modules/axiom-impl/pom.xml (original)
+++ webservices/commons/trunk/modules/axiom/modules/axiom-impl/pom.xml Sun Oct 9 12:59:00 2011
@@ -131,10 +131,6 @@
</configuration>
</plugin>
<plugin>
- <groupId>org.apache.felix</groupId>
- <artifactId>maven-scr-plugin</artifactId>
- </plugin>
- <plugin>
<groupId>${project.groupId}</groupId>
<artifactId>shade-plugin-patched</artifactId>
<version>${project.version}</version>
Modified: webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/factory/OMLinkedListMetaFactory.java
URL: http://svn.apache.org/viewvc/webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/factory/OMLinkedListMetaFactory.java?rev=1180602&r1=1180601&r2=1180602&view=diff
==============================================================================
--- webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/factory/OMLinkedListMetaFactory.java (original)
+++ webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/factory/OMLinkedListMetaFactory.java Sun Oct 9 12:59:00 2011
@@ -31,10 +31,6 @@ import org.apache.axiom.soap.impl.llom.s
* Since all OM factories for LLOM are stateless, {@link #getOMFactory()},
* {@link #getSOAP11Factory()} and {@link #getSOAP12Factory()} will return the
* same instance on every invocation.
- *
- * @scr.component name="metafactory.llom.component" immediate="true"
- * @scr.service interface="org.apache.axiom.om.OMMetaFactory"
- * @scr.property name="implementationName" type="String" value="llom"
*/
public class OMLinkedListMetaFactory extends AbstractOMMetaFactory {
private final OMFactory omFactory = new OMLinkedListImplFactory(this);
Modified: webservices/commons/trunk/modules/axiom/modules/axiom-osgi-tests/pom.xml
URL: http://svn.apache.org/viewvc/webservices/commons/trunk/modules/axiom/modules/axiom-osgi-tests/pom.xml?rev=1180602&r1=1180601&r2=1180602&view=diff
==============================================================================
--- webservices/commons/trunk/modules/axiom/modules/axiom-osgi-tests/pom.xml (original)
+++ webservices/commons/trunk/modules/axiom/modules/axiom-osgi-tests/pom.xml Sun Oct 9 12:59:00 2011
@@ -96,12 +96,6 @@
<scope>provided</scope>
</dependency>
<dependency>
- <groupId>org.apache.felix</groupId>
- <artifactId>org.apache.felix.scr</artifactId>
- <version>1.0.6</version>
- <scope>provided</scope>
- </dependency>
- <dependency>
<groupId>org.ops4j.pax.exam</groupId>
<artifactId>pax-exam</artifactId>
<version>${exam.version}</version>
Modified: webservices/commons/trunk/modules/axiom/modules/axiom-parent/pom.xml
URL: http://svn.apache.org/viewvc/webservices/commons/trunk/modules/axiom/modules/axiom-parent/pom.xml?rev=1180602&r1=1180601&r2=1180602&view=diff
==============================================================================
--- webservices/commons/trunk/modules/axiom/modules/axiom-parent/pom.xml (original)
+++ webservices/commons/trunk/modules/axiom/modules/axiom-parent/pom.xml Sun Oct 9 12:59:00 2011
@@ -234,19 +234,6 @@
<plugins>
<plugin>
<groupId>org.apache.felix</groupId>
- <artifactId>maven-scr-plugin</artifactId>
- <version>1.2.0</version>
- <executions>
- <execution>
- <id>generate-scr-scrdescriptor</id>
- <goals>
- <goal>scr</goal>
- </goals>
- </execution>
- </executions>
- </plugin>
- <plugin>
- <groupId>org.apache.felix</groupId>
<artifactId>maven-bundle-plugin</artifactId>
<version>1.4.0</version>
</plugin>
@@ -416,6 +403,16 @@
<version>0.8-SNAPSHOT</version>
</dependency>
<dependency>
+ <groupId>org.osgi</groupId>
+ <artifactId>org.osgi.core</artifactId>
+ <version>${osgi.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.osgi</groupId>
+ <artifactId>org.osgi.compendium</artifactId>
+ <version>${osgi.version}</version>
+ </dependency>
+ <dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.9</version>
@@ -447,6 +444,7 @@
</site>
</distributionManagement>
<properties>
+ <osgi.version>4.2.0</osgi.version>
<stax.impl.groupid>org.codehaus.woodstox</stax.impl.groupid>
<stax.impl.artifact>wstx-asl</stax.impl.artifact>
<stax.impl.version>3.2.9</stax.impl.version>
Modified: webservices/commons/trunk/modules/axiom/modules/axiom-testutils/pom.xml
URL: http://svn.apache.org/viewvc/webservices/commons/trunk/modules/axiom/modules/axiom-testutils/pom.xml?rev=1180602&r1=1180601&r2=1180602&view=diff
==============================================================================
--- webservices/commons/trunk/modules/axiom/modules/axiom-testutils/pom.xml (original)
+++ webservices/commons/trunk/modules/axiom/modules/axiom-testutils/pom.xml Sun Oct 9 12:59:00 2011
@@ -60,7 +60,6 @@
<!-- We use this only for LDAP like filters -->
<groupId>org.osgi</groupId>
<artifactId>org.osgi.core</artifactId>
- <version>4.2.0</version>
</dependency>
</dependencies>
</project>
Modified: webservices/commons/trunk/modules/axiom/pom.xml
URL: http://svn.apache.org/viewvc/webservices/commons/trunk/modules/axiom/pom.xml?rev=1180602&r1=1180601&r2=1180602&view=diff
==============================================================================
--- webservices/commons/trunk/modules/axiom/pom.xml (original)
+++ webservices/commons/trunk/modules/axiom/pom.xml Sun Oct 9 12:59:00 2011
@@ -318,24 +318,6 @@
<link>http://jaxen.codehaus.org/apidocs/</link>
</links>
<excludePackageNames>org.apache.axiom.test:org.apache.axiom.testutils:org.jaxen.test</excludePackageNames>
- <tags>
- <tag>
- <name>scr.component</name>
- <placement>X</placement>
- </tag>
- <tag>
- <name>scr.reference</name>
- <placement>X</placement>
- </tag>
- <tag>
- <name>scr.service</name>
- <placement>X</placement>
- </tag>
- <tag>
- <name>scr.property</name>
- <placement>X</placement>
- </tag>
- </tags>
<breakiterator>true</breakiterator>
</configuration>
</plugin>