summaryrefslogtreecommitdiffstats
path: root/java/sca/modules/definitions-xml
diff options
context:
space:
mode:
authorrfeng <rfeng@13f79535-47bb-0310-9956-ffa450edef68>2009-08-12 23:43:27 +0000
committerrfeng <rfeng@13f79535-47bb-0310-9956-ffa450edef68>2009-08-12 23:43:27 +0000
commitc122a7379b57d45d2c994728171d20609842f7c5 (patch)
tree9ea10773724f65216b0ebe8d155db4dabaca08f9 /java/sca/modules/definitions-xml
parentaaa85d1773cf5740e22913a9b5027f0bfebbf1de (diff)
Fix issues around XMLStreamWriter based on the isRepairingNamespaces property of XMLOutputFactory
More refactoring to use common-xml and common-java git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@803742 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'java/sca/modules/definitions-xml')
-rw-r--r--java/sca/modules/definitions-xml/META-INF/MANIFEST.MF1
-rw-r--r--java/sca/modules/definitions-xml/src/main/java/org/apache/tuscany/sca/definitions/xml/DefinitionsDocumentProcessor.java6
2 files changed, 3 insertions, 4 deletions
diff --git a/java/sca/modules/definitions-xml/META-INF/MANIFEST.MF b/java/sca/modules/definitions-xml/META-INF/MANIFEST.MF
index 682aacaf39..b9e4e04b91 100644
--- a/java/sca/modules/definitions-xml/META-INF/MANIFEST.MF
+++ b/java/sca/modules/definitions-xml/META-INF/MANIFEST.MF
@@ -12,6 +12,7 @@ Bundle-Description: Apache Tuscany SCA Definitions XML Model
Import-Package: javax.xml.namespace,
javax.xml.stream,
org.apache.tuscany.sca.assembly;version="2.0.0",
+ org.apache.tuscany.sca.common.java.io;version="2.0.0",
org.apache.tuscany.sca.contribution.processor;version="2.0.0",
org.apache.tuscany.sca.contribution.resolver;version="2.0.0",
org.apache.tuscany.sca.core;version="2.0.0",
diff --git a/java/sca/modules/definitions-xml/src/main/java/org/apache/tuscany/sca/definitions/xml/DefinitionsDocumentProcessor.java b/java/sca/modules/definitions-xml/src/main/java/org/apache/tuscany/sca/definitions/xml/DefinitionsDocumentProcessor.java
index 7213783478..3691212960 100644
--- a/java/sca/modules/definitions-xml/src/main/java/org/apache/tuscany/sca/definitions/xml/DefinitionsDocumentProcessor.java
+++ b/java/sca/modules/definitions-xml/src/main/java/org/apache/tuscany/sca/definitions/xml/DefinitionsDocumentProcessor.java
@@ -23,7 +23,6 @@ import java.io.IOException;
import java.io.InputStream;
import java.net.URI;
import java.net.URL;
-import java.net.URLConnection;
import java.security.AccessController;
import java.security.PrivilegedActionException;
import java.security.PrivilegedExceptionAction;
@@ -33,6 +32,7 @@ import javax.xml.stream.XMLStreamConstants;
import javax.xml.stream.XMLStreamException;
import javax.xml.stream.XMLStreamReader;
+import org.apache.tuscany.sca.common.java.io.IOHelper;
import org.apache.tuscany.sca.contribution.processor.ContributionReadException;
import org.apache.tuscany.sca.contribution.processor.ContributionResolveException;
import org.apache.tuscany.sca.contribution.processor.StAXArtifactProcessor;
@@ -103,9 +103,7 @@ public class DefinitionsDocumentProcessor implements URLArtifactProcessor<Defini
try {
urlStream = AccessController.doPrivileged(new PrivilegedExceptionAction<InputStream>() {
public InputStream run() throws IOException {
- URLConnection connection = url.openConnection();
- connection.setUseCaches(false);
- return connection.getInputStream();
+ return IOHelper.openStream(url);
}
});
} catch (PrivilegedActionException e) {