DO NOT REPLY [Bug 31331] Controling the XML processor used by the XSLT element

2008-10-01 Thread bugzilla
https://issues.apache.org/bugzilla/show_bug.cgi?id=31331





--- Comment #1 from Patrick Wiederkehr [EMAIL PROTECTED]  2008-10-01 06:05:28 
PST ---
I would also like to have a passthroug for features to the xml parser (eg
xerces)

cause i need xerces to activate xinclude features.


-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.


[jira] Created: (IVY-927) NullPointerException when Ivy cannot locate pom parent

2008-10-01 Thread Xavier Hanin (JIRA)
NullPointerException when Ivy cannot locate pom parent
--

 Key: IVY-927
 URL: https://issues.apache.org/jira/browse/IVY-927
 Project: Ivy
  Issue Type: Bug
  Components: Maven Compatibility
Affects Versions: 2.0-RC1
Reporter: Xavier Hanin
Assignee: Xavier Hanin


When Ivy cannot locate a pom parent, it results in a NullPointerException:
{noformat}
java.lang.NullPointerException at 
org.apache.ivy.plugins.parser.m2.PomModuleDescriptorParser.parseDescriptor(PomModuleDescriptorParser.java:134)
{noformat}


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



svn commit: r700792 - in /ant/ivy/core/trunk: CHANGES.txt src/java/org/apache/ivy/plugins/parser/m2/PomModuleDescriptorParser.java

2008-10-01 Thread xavier
Author: xavier
Date: Wed Oct  1 07:41:39 2008
New Revision: 700792

URL: http://svn.apache.org/viewvc?rev=700792view=rev
Log:
FIX: NullPointerException when Ivy cannot locate pom parent (IVY-927)

Modified:
ant/ivy/core/trunk/CHANGES.txt

ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/m2/PomModuleDescriptorParser.java

Modified: ant/ivy/core/trunk/CHANGES.txt
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/CHANGES.txt?rev=700792r1=700791r2=700792view=diff
==
--- ant/ivy/core/trunk/CHANGES.txt (original)
+++ ant/ivy/core/trunk/CHANGES.txt Wed Oct  1 07:41:39 2008
@@ -84,6 +84,7 @@
 - IMPROVEMENT: Error messages on use of relative paths can be cyrptic (IVY-909)
 - IMPROVEMENT: Maven accepts illegal XML for its pom's, Ivy not (IVY-921)
 
+- FIX: NullPointerException when Ivy cannot locate pom parent (IVY-927)
 - FIX: Cannot configure items with java.io.File attributes (IVY-905)
 - FIX: Environment properties in ivy settings are no longer resolved (IVY-907)
 - FIX: Resolve failed on certain proxy environment (IVY-911)

Modified: 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/m2/PomModuleDescriptorParser.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/m2/PomModuleDescriptorParser.java?rev=700792r1=700791r2=700792view=diff
==
--- 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/m2/PomModuleDescriptorParser.java
 (original)
+++ 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/m2/PomModuleDescriptorParser.java
 Wed Oct  1 07:41:39 2008
@@ -137,13 +137,14 @@
Message.warn(impossible to load parent for  + 
descriptorURL + .
+  Parent= + parentModRevID); 
 }
-
-Map parentPomProps = 
PomModuleDescriptorBuilder.extractPomProperties(
-
parentDescr.getExtraInfo());
-for (Iterator iter = parentPomProps.entrySet().iterator(); 
iter.hasNext();) {
-Map.Entry prop = (Map.Entry) iter.next();
-domReader.setProperty((String) prop.getKey(), (String) 
prop.getValue());
-}
+if (parentDescr != null) {
+Map parentPomProps = 
PomModuleDescriptorBuilder.extractPomProperties(
+parentDescr.getExtraInfo());
+for (Iterator iter = parentPomProps.entrySet().iterator(); 
iter.hasNext();) {
+Map.Entry prop = (Map.Entry) iter.next();
+domReader.setProperty((String) prop.getKey(), (String) 
prop.getValue());
+}
+}
 }
 
 String groupId = domReader.getGroupId();




svn commit: r700793 - in /ant/ivy/updatesite: ./ branches/ tags/ trunk/ trunk/dist/ trunk/dist/features/ trunk/dist/plugins/ trunk/ivy-feature-template/

2008-10-01 Thread hibou
Author: hibou
Date: Wed Oct  1 07:46:28 2008
New Revision: 700793

URL: http://svn.apache.org/viewvc?rev=700793view=rev
Log:
As discussed on ant-dev, move the updatesite so it has its own 
tags-branches-trunk structure

Added:
ant/ivy/updatesite/
ant/ivy/updatesite/branches/
ant/ivy/updatesite/tags/
ant/ivy/updatesite/trunk/
ant/ivy/updatesite/trunk/.project
ant/ivy/updatesite/trunk/build.xml
  - copied, changed from r699295, ant/ivy/site/build.xml
ant/ivy/updatesite/trunk/dist/
ant/ivy/updatesite/trunk/dist/digest.zip
  - copied unchanged from r700024, ant/ivy/site/ivyde/updatesite/digest.zip
ant/ivy/updatesite/trunk/dist/digest.zip.asc
  - copied unchanged from r700024, 
ant/ivy/site/ivyde/updatesite/digest.zip.asc
ant/ivy/updatesite/trunk/dist/digest.zip.sha
  - copied unchanged from r700024, 
ant/ivy/site/ivyde/updatesite/digest.zip.sha
ant/ivy/updatesite/trunk/dist/features/
  - copied from r700024, ant/ivy/site/ivyde/updatesite/features/
ant/ivy/updatesite/trunk/dist/features/org.apache.ivy.feature_2.0.0.cr1.jar
  - copied unchanged from r700791, 
ant/ivy/site/ivyde/updatesite/features/org.apache.ivy.feature_2.0.0.cr1.jar

ant/ivy/updatesite/trunk/dist/features/org.apache.ivy.feature_2.0.0.cr1.jar.asc
  - copied unchanged from r700791, 
ant/ivy/site/ivyde/updatesite/features/org.apache.ivy.feature_2.0.0.cr1.jar.asc

ant/ivy/updatesite/trunk/dist/features/org.apache.ivy.feature_2.0.0.cr1.jar.md5
  - copied unchanged from r700791, 
ant/ivy/site/ivyde/updatesite/features/org.apache.ivy.feature_2.0.0.cr1.jar.md5

ant/ivy/updatesite/trunk/dist/features/org.apache.ivy.feature_2.0.0.cr1.jar.sha
  - copied unchanged from r700791, 
ant/ivy/site/ivyde/updatesite/features/org.apache.ivy.feature_2.0.0.cr1.jar.sha

ant/ivy/updatesite/trunk/dist/features/org.apache.ivyde.feature_2.0.0.alpha1.jar
  - copied unchanged from r700791, 
ant/ivy/site/ivyde/updatesite/features/org.apache.ivyde.feature_2.0.0.alpha1.jar

ant/ivy/updatesite/trunk/dist/features/org.apache.ivyde.feature_2.0.0.alpha1.jar.asc
  - copied unchanged from r700791, 
ant/ivy/site/ivyde/updatesite/features/org.apache.ivyde.feature_2.0.0.alpha1.jar.asc

ant/ivy/updatesite/trunk/dist/features/org.apache.ivyde.feature_2.0.0.alpha1.jar.md5
  - copied unchanged from r700791, 
ant/ivy/site/ivyde/updatesite/features/org.apache.ivyde.feature_2.0.0.alpha1.jar.md5

ant/ivy/updatesite/trunk/dist/features/org.apache.ivyde.feature_2.0.0.alpha1.jar.sha
  - copied unchanged from r700791, 
ant/ivy/site/ivyde/updatesite/features/org.apache.ivyde.feature_2.0.0.alpha1.jar.sha
ant/ivy/updatesite/trunk/dist/plugins/
  - copied from r700024, ant/ivy/site/ivyde/updatesite/plugins/
ant/ivy/updatesite/trunk/dist/plugins/org.apache.ivy_2.0.0.cr1.jar
  - copied unchanged from r700791, 
ant/ivy/site/ivyde/updatesite/plugins/org.apache.ivy_2.0.0.cr1.jar
ant/ivy/updatesite/trunk/dist/plugins/org.apache.ivy_2.0.0.cr1.jar.asc
  - copied unchanged from r700791, 
ant/ivy/site/ivyde/updatesite/plugins/org.apache.ivy_2.0.0.cr1.jar.asc
ant/ivy/updatesite/trunk/dist/plugins/org.apache.ivy_2.0.0.cr1.jar.md5
  - copied unchanged from r700791, 
ant/ivy/site/ivyde/updatesite/plugins/org.apache.ivy_2.0.0.cr1.jar.md5
ant/ivy/updatesite/trunk/dist/plugins/org.apache.ivy_2.0.0.cr1.jar.pack.gz
  - copied unchanged from r700791, 
ant/ivy/site/ivyde/updatesite/plugins/org.apache.ivy_2.0.0.cr1.jar.pack.gz

ant/ivy/updatesite/trunk/dist/plugins/org.apache.ivy_2.0.0.cr1.jar.pack.gz.asc
  - copied unchanged from r700791, 
ant/ivy/site/ivyde/updatesite/plugins/org.apache.ivy_2.0.0.cr1.jar.pack.gz.asc

ant/ivy/updatesite/trunk/dist/plugins/org.apache.ivy_2.0.0.cr1.jar.pack.gz.md5
  - copied unchanged from r700791, 
ant/ivy/site/ivyde/updatesite/plugins/org.apache.ivy_2.0.0.cr1.jar.pack.gz.md5

ant/ivy/updatesite/trunk/dist/plugins/org.apache.ivy_2.0.0.cr1.jar.pack.gz.sha
  - copied unchanged from r700791, 
ant/ivy/site/ivyde/updatesite/plugins/org.apache.ivy_2.0.0.cr1.jar.pack.gz.sha
ant/ivy/updatesite/trunk/dist/plugins/org.apache.ivy_2.0.0.cr1.jar.sha
  - copied unchanged from r700791, 
ant/ivy/site/ivyde/updatesite/plugins/org.apache.ivy_2.0.0.cr1.jar.sha

ant/ivy/updatesite/trunk/dist/plugins/org.apache.ivyde.eclipse_2.0.0.alpha1.jar
  - copied unchanged from r700791, 
ant/ivy/site/ivyde/updatesite/plugins/org.apache.ivyde.eclipse_2.0.0.alpha1.jar

ant/ivy/updatesite/trunk/dist/plugins/org.apache.ivyde.eclipse_2.0.0.alpha1.jar.asc
  - copied unchanged from r700791, 
ant/ivy/site/ivyde/updatesite/plugins/org.apache.ivyde.eclipse_2.0.0.alpha1.jar.asc

ant/ivy/updatesite/trunk/dist/plugins/org.apache.ivyde.eclipse_2.0.0.alpha1.jar.md5
  - copied unchanged from r700791, 
ant/ivy/site/ivyde/updatesite/plugins/org.apache.ivyde.eclipse_2.0.0.alpha1.jar.md5


svn commit: r700798 - in /ant/ivy/core/trunk: CHANGES.txt src/java/org/apache/ivy/plugins/resolver/AbstractPatternsBasedResolver.java

2008-10-01 Thread xavier
Author: xavier
Date: Wed Oct  1 07:50:18 2008
New Revision: 700798

URL: http://svn.apache.org/viewvc?rev=700798view=rev
Log:
FIX: NullPointerException in AbstractPatternsBasedResolver when organization is 
null (IVY-928)

Modified:
ant/ivy/core/trunk/CHANGES.txt

ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/resolver/AbstractPatternsBasedResolver.java

Modified: ant/ivy/core/trunk/CHANGES.txt
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/CHANGES.txt?rev=700798r1=700797r2=700798view=diff
==
--- ant/ivy/core/trunk/CHANGES.txt (original)
+++ ant/ivy/core/trunk/CHANGES.txt Wed Oct  1 07:50:18 2008
@@ -84,6 +84,7 @@
 - IMPROVEMENT: Error messages on use of relative paths can be cyrptic (IVY-909)
 - IMPROVEMENT: Maven accepts illegal XML for its pom's, Ivy not (IVY-921)
 
+- FIX: NullPointerException in AbstractPatternsBasedResolver when organization 
is null (IVY-928)
 - FIX: NullPointerException when Ivy cannot locate pom parent (IVY-927)
 - FIX: Cannot configure items with java.io.File attributes (IVY-905)
 - FIX: Environment properties in ivy settings are no longer resolved (IVY-907)

Modified: 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/resolver/AbstractPatternsBasedResolver.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/resolver/AbstractPatternsBasedResolver.java?rev=700798r1=700797r2=700798view=diff
==
--- 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/resolver/AbstractPatternsBasedResolver.java
 (original)
+++ 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/resolver/AbstractPatternsBasedResolver.java
 Wed Oct  1 07:50:18 2008
@@ -438,7 +438,7 @@
 }
 
 protected ModuleRevisionId convertM2IdForResourceSearch(ModuleRevisionId 
mrid) {
-if (mrid.getOrganisation().indexOf('.') == -1) {
+if (mrid.getOrganisation() == null || 
mrid.getOrganisation().indexOf('.') == -1) {
 return mrid;
 }
 return 
ModuleRevisionId.newInstance(mrid.getOrganisation().replace('.', '/'), 




[jira] Resolved: (IVY-928) NullPointerException in AbstractPatternsBasedResolver when organization is null

2008-10-01 Thread Xavier Hanin (JIRA)

 [ 
https://issues.apache.org/jira/browse/IVY-928?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Xavier Hanin resolved IVY-928.
--

   Resolution: Fixed
Fix Version/s: trunk
 Assignee: Xavier Hanin

Fixed on trunk, still have to merge on 2.0.x branch

 NullPointerException in AbstractPatternsBasedResolver when organization is 
 null
 ---

 Key: IVY-928
 URL: https://issues.apache.org/jira/browse/IVY-928
 Project: Ivy
  Issue Type: Bug
  Components: Core
Affects Versions: 2.0-RC1
Reporter: Xavier Hanin
Assignee: Xavier Hanin
 Fix For: trunk


 When a mrid organization is null (it can happen when there is no groupId in 
 m2 pom for instance), AbstractPatternsBasedResolver run into a 
 NullPointException:
 {noformat}
 java.lang.NullPointerException at 
 org.apache.ivy.plugins.resolver.AbstractPatternsBasedResolver.convertM2IdForResourceSearch(AbstractPatternsBasedResolver.java:441)
 {noformat}

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



svn commit: r700803 - in /ant/ivy/site: build.xml ivyde/updatesite/features/ ivyde/updatesite/ivy-feature-template/ ivyde/updatesite/plugins/ ivyde/updatesite/signArtifacts.sh ivyde/updatesite/verifyA

2008-10-01 Thread hibou
Author: hibou
Date: Wed Oct  1 07:59:15 2008
New Revision: 700803

URL: http://svn.apache.org/viewvc?rev=700803view=rev
Log:
remove the moved updatesite, just keep the cgi script for mirror managing and 
the artifact deployed into the site

Removed:
ant/ivy/site/ivyde/updatesite/features/
ant/ivy/site/ivyde/updatesite/ivy-feature-template/
ant/ivy/site/ivyde/updatesite/plugins/
ant/ivy/site/ivyde/updatesite/signArtifacts.sh
ant/ivy/site/ivyde/updatesite/verifyArtifacts.sh
Modified:
ant/ivy/site/build.xml

Modified: ant/ivy/site/build.xml
URL: 
http://svn.apache.org/viewvc/ant/ivy/site/build.xml?rev=700803r1=700802r2=700803view=diff
==
--- ant/ivy/site/build.xml (original)
+++ ant/ivy/site/build.xml Wed Oct  1 07:59:15 2008
@@ -21,8 +21,6 @@
 
 taskdef uri=antlib:xooki file=${basedir}/xooki/antlib.xml /
 property name=target.dir value=${basedir}/target /
-property name=work.dir value=${basedir}/work/
-property name=updatesite.dir value=${basedir}/ivyde/updatesite/
 
 target name=/all description=-- force whole site generation, 
disabling incremental mode
 property name=checkUpToDate value=false /
@@ -247,165 +245,4 @@
 /generate-tagsdoc
 /target
 
-!-- 
-
===
-Targets to intialize an ant run with Eclipse. Will be used to manage 
the updatesite
-
===

-  --
-target name=eclipse-startup-check
-fail message=An Eclipse install is needed to run the build. Set your 
Eclipse install dir into the baseLocation property. unless=baseLocation /
-
-condition property=eclipse.startup
-available file=${baseLocation}/startup.jar /
-/condition
-/target
-
-target name=eclipse-startup-classpath depends=eclipse-startup-check 
if=eclipse.startup
-property name=eclipse.classpath value=${baseLocation}/startup.jar 
/
-/target
-
-target name=eclipse-launcher-classpath depends=eclipse-startup-check 
unless=eclipse.startup
-!-- store path to newest launcher JAR in path id 
'newest.equinox.launcher.path.id' --
-path id=newest.equinox.launcher.path.id
-first count=1
-sort
-fileset dir=${baseLocation}/plugins 
includes=**/org.eclipse.equinox.launcher_*.jar /
-!-- Seems the default order is oldest  newest so we must 
reverse it.
-   The 'reverse' and 'date' comparators are in the 
internal antlib
-   org.apache.tools.ant.types.resources.comparators.
---
-reverse 
xmlns=antlib:org.apache.tools.ant.types.resources.comparators
-!-- 'date' inherits 'reverse's namespace --
-date /
-/reverse
-/sort
-/first
-/path
-
-!-- turn the path into a property --
-property name=eclipse.classpath 
refid=newest.equinox.launcher.path.id /
-/target
-
-target name=eclipse-classpath 
depends=eclipse-startup-classpath,eclipse-launcher-classpath
-echo message=Using equinox launcher jar: ${eclipse.classpath} /
-/target
-
-!-- 
-
===
-   Target to generate the Ivy feature and put it in the updatesite
-
===

-  --
-target name=updatesite:generate-ivy-feature description=Generate the 
Eclipse feature for Ivy
-fail message=You have to specify the version of the ivy 
unless=ivy.version /
-!-- first generate a feature descriptor with the proper version --
-delete file=${work.dir}/feature.xml /
-copy file=${updatesite.dir}/ivy-feature-template/feature.xml 
todir=${work.dir}
-filterset
-filter token=ivy.version value=${ivy.version}/
-/filterset
-/copy
-!-- package the feature --
-jar 
destfile=${updatesite.dir}/features/org.apache.ivy.feature_${ivy.version}.jar
-fileset dir=${updatesite.dir}/ivy-feature-template
-include name=feature.properties /
-include name=LICENCE/
-include name=NOTICE/
-/fileset
-fileset dir=${work.dir}
-include name=feature.xml/
-/fileset
-/jar
-/target
-
-!-- 
-
===
-   Targets to manage the 

svn commit: r700807 - /ant/ivy/core/trunk/doc/dev/updatesite.html

2008-10-01 Thread hibou
Author: hibou
Date: Wed Oct  1 08:22:41 2008
New Revision: 700807

URL: http://svn.apache.org/viewvc?rev=700807view=rev
Log:
Update of the release process of the updatesite

Modified:
ant/ivy/core/trunk/doc/dev/updatesite.html

Modified: ant/ivy/core/trunk/doc/dev/updatesite.html
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/doc/dev/updatesite.html?rev=700807r1=700806r2=700807view=diff
==
--- ant/ivy/core/trunk/doc/dev/updatesite.html (original)
+++ ant/ivy/core/trunk/doc/dev/updatesite.html Wed Oct  1 08:22:41 2008
@@ -25,62 +25,152 @@
 /head
 body
textarea id=xooki-source
-Once a release have been build for Ivy or IvyDE, they should be push to the 
Eclipse updatesite so that Eclipse users will be able to update automatically 
their installed version of Ivy or IvyDE.
+Once a release have been build for Ivy or IvyDE, they should be pushed to the 
Eclipse updatesite so that Eclipse users will be able to update automatically 
their installed version of Ivy or IvyDE.
 
-h1Push the new version/h1
+This doc is in two parts, the a href=#setupsetup/a of the updatesite 
which will be the candidate for the vote of the Ivy or IvyDE release, and the 
a href=#deploymentfinal deployment/a once the release is accepted.
 
-The update site svn location is there: 
https://svn.apache.org/repos/asf/ant/ivy/site/ivyde/updatesite/
+uImportant note:/u in this doc, the released version is denoted as 
$VERSION (and have to be replaced accordingly in every commands), but this is 
the OSGi one, not the usually shown one, in particular for release candidate 
versions. For instance an Ivy version can be tt2.0.0-RC1/tt but the OSGi 
one, and the one to use here is tt2.0.0.cr1/tt.
 
-ul
-liFor an uIvy release/u:
-the new ivy bundle have to be placed in the plugins directory of the 
updatesite. The convention is to name the bundle 
org.apache.ivy_${BUNDLE-VERSION}.jar.
-Eclipse needs a feature, it can be generated at the right place with an ant 
target. From the a 
href=https://svn.apache.org/repos/asf/ant/ivy/site/build.xml;build file of 
the site/a, run: preant updatesite:generate-ivy-feature 
-Divy.version=${BUNDLE-VERSION}/pre
-/li
-liFor an uIvyDE release/u:
-it contains a plugin and a feature, so they have to be place respectivly in 
the plugins directory and in the features directory. /li
-/ul
-
-Then the deprecated versions of the plugins and the features should be removed.
-
-And the site.xml file should be edited. The version number should be updated 
accordingly to the release.
-
-h1Prepare the update site/h1
-
-The update site is optimized: the metadata of the features are aggregated into 
the digest.zip, and the jar of the plugins are compressed with a better 
algorithm.
+h1a name=setup/aBuild the updatesite/h1
 
-To accomplish this task, from the a 
href=https://svn.apache.org/repos/asf/ant/ivy/site/build.xml;build file of 
the site/a, run:
-preant updatesite:optimize/pre
+h2Push the new version/h2
 
-The binary files then need to be signed and their checksum computed. For the 
checksums, run:
-preant updatesite:checksum/pre
-To sign the binaries, you can use the signArtifacts.sh scripts which is in the 
updatesite directory.
+The update site svn location is there: 
https://svn.apache.org/repos/asf/ant/ivy/site/ivyde/updatesite/ . You will 
update it so it will contain the new artifacts.
 
-bNote:/b these previous tasks may optimize, checksum and sign already 
released artifacts. Just so a svn status to check the modified artifacts; the 
only modified files should be the digest.zip (with its signature and checksum) 
and the site.xml. Then do some svn revert ifile/i to revert the 
unexpected changes.
+ulliFor an uIvy release/u:
+The new ivy bundle have to be placed in the plugins directory of the 
updatesite. So you should do something like:
+codecp folder/ivy.jar dist/plugins/org.apache.ivy_$VERSION.jar/code
 
-h1Test the updatesite/h1
+Then Eclipse needs a feature, which will be generated at the right place with 
an ant target. At the root of your working copy of the website, run:
+pre
+ant generate-ivy-feature -Divy.version=$VERSION/pre
+/lili
+For an uIvyDE release:/u
+The zip distribution needs to be unpacked into the updatesite directory:
+pre
+cd dist
+unzip /org.apache.ivyde.feature-$VERSION.zip
+/pre
+/li
+/ul
 
-The updatesite is ready to be tested. In order to test the new artifacts, as 
they are not yet deployed on Apache mirrors, the updatesite mirroring have to 
be disable. Basically it is just about not deploying the eclipse-update--xml 
files.
+Then the deprecated versions of the plugins and the features should be removed.
 
-If you are willing to just test yourself, you can setup in Eclipse a local 
updatesite. Wherever you want on your local filesystem, make a clone of you 
working copy of the updatesite directory, but uwithout/u the 
eclipse-update--xml files.
+h2Update the site.xml/h2
 
-To let the 

DO NOT REPLY [Bug 42275] running ant off a network share can cause Ant to fail

2008-10-01 Thread bugzilla
https://issues.apache.org/bugzilla/show_bug.cgi?id=42275





--- Comment #12 from Jesse Glick [EMAIL PROTECTED]  2008-10-01 09:07:15 PST 
---
The minimal fix for the UNC import problem in Ant 1.7.1 (which I think should
be merged to a 1.7.2 if one is created, since this is a serious regression),
borrowed from SVN r631263:

Index: src/main/org/apache/tools/ant/launch/Locator.java
===
--- src/main/org/apache/tools/ant/launch/Locator.java   (revision 700534)
+++ src/main/org/apache/tools/ant/launch/Locator.java   (working copy)
@@ -275,7 +275,8 @@
 path = decodeUri(uri);
 String cwd = System.getProperty(user.dir);
 int posi = cwd.indexOf(:);
-if ((posi  0)  path.startsWith(File.separator)) {
+if ((posi  0)  path.startsWith(File.separator)
+/* #42275: UNC */  !path.startsWith()) {
path = cwd.substring(0, posi + 1) + path;
 }
 } catch (UnsupportedEncodingException exc) {


-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.


svn commit: r700826 - /ant/ivy/core/trunk/doc/dev/updatesite.html

2008-10-01 Thread hibou
Author: hibou
Date: Wed Oct  1 09:26:49 2008
New Revision: 700826

URL: http://svn.apache.org/viewvc?rev=700826view=rev
Log:
Document that there is now one target for Ivy and one target for IvyDE

Modified:
ant/ivy/core/trunk/doc/dev/updatesite.html

Modified: ant/ivy/core/trunk/doc/dev/updatesite.html
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/doc/dev/updatesite.html?rev=700826r1=700825r2=700826view=diff
==
--- ant/ivy/core/trunk/doc/dev/updatesite.html (original)
+++ ant/ivy/core/trunk/doc/dev/updatesite.html Wed Oct  1 09:26:49 2008
@@ -65,9 +65,17 @@
 The update site is optimized: the metadata of the features are aggregated into 
the digest.zip, and the jar of the plugins are compressed with a better 
algorithm.
 
 To accomplish this task, just run an ant task at the root of your working copy 
of the updatesite:
+ul
+liFor an uIvy/u release
 pre
-ant optimize
-/pre
+ant optimize-ivy
+/pre/li
+li
+For an uIvyDE/u release
+pre
+ant optimize-ivyde
+/pre/li
+/ul
 
 The binary files then need to be signed and their checksum computed. For the 
checksums, run:
 preant checksum/pre




[jira] Created: (IVY-930) HttpClientHandler hanging in certain cases

2008-10-01 Thread Scott Hebert (JIRA)
HttpClientHandler hanging in certain cases
--

 Key: IVY-930
 URL: https://issues.apache.org/jira/browse/IVY-930
 Project: Ivy
  Issue Type: Bug
Affects Versions: 2.0-RC1
Reporter: Scott Hebert
Priority: Blocker


Using Commons HttpClient and an URL Resolver, it is possible for the 
HttpClientHandler to hang.

The following seems to correct the problem:

{code:java}
public InputStream openStream(URL url) throws IOException {
GetMethod get = doGet(url);
if (!checkStatusCode(url, get)) {
// Make sure the number of connections does not get exhausted
get.releaseConnection();
//
throw new IOException(
The HTTP response code for  + url +  did not indicate a 
success.
+  See log for more detail.);
}
return new GETInputStream(get);
}

public void download(URL src, File dest, CopyProgressListener l) throws 
IOException {
GetMethod get = doGet(src);
// We can only figure the content we got is want we want if the status 
is success.
if (!checkStatusCode(src, get)) {
// Make sure the number of connections does not get exhausted
get.releaseConnection();
//
throw new IOException(
The HTTP response code for  + src +  did not indicate a 
success.
+  See log for more detail.);
}
FileUtil.copy(get.getResponseBodyAsStream(), dest, l);
dest.setLastModified(getLastModified(get));
get.releaseConnection();
}

{code}

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Assigned: (IVY-925) ivy:settings / ivy:configure task are skipped if ivy.instance property doesn't exists

2008-10-01 Thread Maarten Coene (JIRA)

 [ 
https://issues.apache.org/jira/browse/IVY-925?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Maarten Coene reassigned IVY-925:
-

Assignee: Maarten Coene

 ivy:settings / ivy:configure task are skipped if ivy.instance property 
 doesn't exists
 -

 Key: IVY-925
 URL: https://issues.apache.org/jira/browse/IVY-925
 Project: Ivy
  Issue Type: Bug
  Components: Core
Reporter: Jean-Louis Boudart
Assignee: Maarten Coene
Priority: Minor
 Attachments: test-ivyInstance.tar.gz


 It seems that using ivy;settings or ivy:configure task when you havn't 
 initialized ivy.instance property doesn't work
 Here is my ivy:configure 
 {noformat}
 ivy:configure settingsId=ivy.instance.project 
 file=${common.dir}/ivysettings.xml  /
 {noformat}
 I'm using my own ivysettings.properties instead of the one given by ivy. My 
 ivysettings.properties doesn't contains ivy.instance property.
 Here is part of my ivysettings.xml
 {noformat}
 ivysettings
   properties file=${common.dir}/ivysettings.properties 
 override=false/
 ...
 /ivysettings
 {noformat}
 And running this in debug mode i can see Skipped because property 
 'ivy.instance' not set.
 Consequences are, when i'm trying to use any ivy task that use this instance, 
 i have a build failed with a message like Reference ivy.instance.project not 
 found.
 Exemple try to use ivy:resolve
 {noformat}
 ivy:resolve file=${ivy.file} useCacheOnly=${ivy.use.cache.only} 
 settingsRef=ivy.instance.project/
 {noformat}
 The result is :
 {noformat}
 BUILD FAILED
 /home/neoverflow/work/sg/sogera-git/common/common.xml:124: Reference 
 ivy.instance.project not found.
   at 
 org.apache.tools.ant.types.Reference.getReferencedObject(Reference.java:115)
   at org.apache.ivy.ant.IvyTask.getIvyInstance(IvyTask.java:76)
   at org.apache.ivy.ant.IvyTask.prepareTask(IvyTask.java:256)
   at org.apache.ivy.ant.IvyTask.execute(IvyTask.java:276)
   at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
   at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
   at 
 sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
   at java.lang.reflect.Method.invoke(Method.java:585)
   at 
 org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:105)
   at org.apache.tools.ant.Task.perform(Task.java:348)
   at org.apache.tools.ant.Target.execute(Target.java:357)
   at org.apache.tools.ant.Target.performTasks(Target.java:385)
   at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1329)
   at org.apache.tools.ant.Project.executeTarget(Project.java:1298)
   at 
 org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
   at org.apache.tools.ant.Project.executeTargets(Project.java:1181)
   at org.apache.tools.ant.Main.runBuild(Main.java:698)
   at org.apache.tools.ant.Main.startAnt(Main.java:199)
   at org.apache.tools.ant.launch.Launcher.run(Launcher.java:257)
   at org.apache.tools.ant.launch.Launcher.main(Launcher.java:104)
 {noformat}
 Adding this property to my own ivysettings.properties, everything seems ok.
 I think that when you give an settingsId (in ivy:configure) or an id in 
 (ivy:instance) you doesn't need to use ivy.instance property.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Resolved: (IVY-925) ivy:settings doesn't work if id is a property

2008-10-01 Thread Maarten Coene (JIRA)

 [ 
https://issues.apache.org/jira/browse/IVY-925?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Maarten Coene resolved IVY-925.
---

   Resolution: Fixed
Fix Version/s: trunk

I was able to reproduce your problem and fixed it in SVN trunk.
Could you please give it a try to see if it also fixes your problem and post 
your feedback?

 ivy:settings doesn't work if id is a property
 -

 Key: IVY-925
 URL: https://issues.apache.org/jira/browse/IVY-925
 Project: Ivy
  Issue Type: Bug
  Components: Ant
Affects Versions: 2.0-RC1
Reporter: Jean-Louis Boudart
Assignee: Maarten Coene
Priority: Minor
 Fix For: trunk

 Attachments: test-ivyInstance.tar.gz


 It seems that using ivy;settings or ivy:configure task when you havn't 
 initialized ivy.instance property doesn't work
 Here is my ivy:configure 
 {noformat}
 ivy:configure settingsId=ivy.instance.project 
 file=${common.dir}/ivysettings.xml  /
 {noformat}
 I'm using my own ivysettings.properties instead of the one given by ivy. My 
 ivysettings.properties doesn't contains ivy.instance property.
 Here is part of my ivysettings.xml
 {noformat}
 ivysettings
   properties file=${common.dir}/ivysettings.properties 
 override=false/
 ...
 /ivysettings
 {noformat}
 And running this in debug mode i can see Skipped because property 
 'ivy.instance' not set.
 Consequences are, when i'm trying to use any ivy task that use this instance, 
 i have a build failed with a message like Reference ivy.instance.project not 
 found.
 Exemple try to use ivy:resolve
 {noformat}
 ivy:resolve file=${ivy.file} useCacheOnly=${ivy.use.cache.only} 
 settingsRef=ivy.instance.project/
 {noformat}
 The result is :
 {noformat}
 BUILD FAILED
 /home/neoverflow/work/sg/sogera-git/common/common.xml:124: Reference 
 ivy.instance.project not found.
   at 
 org.apache.tools.ant.types.Reference.getReferencedObject(Reference.java:115)
   at org.apache.ivy.ant.IvyTask.getIvyInstance(IvyTask.java:76)
   at org.apache.ivy.ant.IvyTask.prepareTask(IvyTask.java:256)
   at org.apache.ivy.ant.IvyTask.execute(IvyTask.java:276)
   at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
   at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
   at 
 sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
   at java.lang.reflect.Method.invoke(Method.java:585)
   at 
 org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:105)
   at org.apache.tools.ant.Task.perform(Task.java:348)
   at org.apache.tools.ant.Target.execute(Target.java:357)
   at org.apache.tools.ant.Target.performTasks(Target.java:385)
   at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1329)
   at org.apache.tools.ant.Project.executeTarget(Project.java:1298)
   at 
 org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
   at org.apache.tools.ant.Project.executeTargets(Project.java:1181)
   at org.apache.tools.ant.Main.runBuild(Main.java:698)
   at org.apache.tools.ant.Main.startAnt(Main.java:199)
   at org.apache.tools.ant.launch.Launcher.run(Launcher.java:257)
   at org.apache.tools.ant.launch.Launcher.main(Launcher.java:104)
 {noformat}
 Adding this property to my own ivysettings.properties, everything seems ok.
 I think that when you give an settingsId (in ivy:configure) or an id in 
 (ivy:instance) you doesn't need to use ivy.instance property.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



svn commit: r700929 - in /ant/ivy/core/trunk/test/java/org/apache/ivy/ant: IvyAntSettingsBuildFileStackOverflow.xml IvyAntSettingsBuildFileTest.java

2008-10-01 Thread maartenc
Author: maartenc
Date: Wed Oct  1 14:12:02 2008
New Revision: 700929

URL: http://svn.apache.org/viewvc?rev=700929view=rev
Log:
Added junit test for IVY-924

Added:

ant/ivy/core/trunk/test/java/org/apache/ivy/ant/IvyAntSettingsBuildFileStackOverflow.xml
Modified:

ant/ivy/core/trunk/test/java/org/apache/ivy/ant/IvyAntSettingsBuildFileTest.java

Added: 
ant/ivy/core/trunk/test/java/org/apache/ivy/ant/IvyAntSettingsBuildFileStackOverflow.xml
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/test/java/org/apache/ivy/ant/IvyAntSettingsBuildFileStackOverflow.xml?rev=700929view=auto
==
--- 
ant/ivy/core/trunk/test/java/org/apache/ivy/ant/IvyAntSettingsBuildFileStackOverflow.xml
 (added)
+++ 
ant/ivy/core/trunk/test/java/org/apache/ivy/ant/IvyAntSettingsBuildFileStackOverflow.xml
 Wed Oct  1 14:12:02 2008
@@ -0,0 +1,33 @@
+!--
+   Licensed to the Apache Software Foundation (ASF) under one
+   or more contributor license agreements.  See the NOTICE file
+   distributed with this work for additional information
+   regarding copyright ownership.  The ASF licenses this file
+   to you under the Apache License, Version 2.0 (the
+   License); you may not use this file except in compliance
+   with the License.  You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing,
+   software distributed under the License is distributed on an
+   AS IS BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+   KIND, either express or implied.  See the License for the
+   specific language governing permissions and limitations
+   under the License.
+--
+project xmlns:ivy=antlib:org.apache.ivy.ant basedir=../../../../../..
+  target name=setUp
+property name=ivy.cache.repository value=build/cache /
+  /target
+
+  target name=tearDown
+   delete dir=build/cache /
+  /target
+
+  target name=testStackOverflow
+   ivy:settings id=ivy.instance 
file=test/repositories/ivysettings.xml /
+   ivy:resolve settingsRef=ivy.instance 
file=test/java/org/apache/ivy/ant/ivy-simple.xml /
+  /target
+
+/project
\ No newline at end of file

Modified: 
ant/ivy/core/trunk/test/java/org/apache/ivy/ant/IvyAntSettingsBuildFileTest.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/test/java/org/apache/ivy/ant/IvyAntSettingsBuildFileTest.java?rev=700929r1=700928r2=700929view=diff
==
--- 
ant/ivy/core/trunk/test/java/org/apache/ivy/ant/IvyAntSettingsBuildFileTest.java
 (original)
+++ 
ant/ivy/core/trunk/test/java/org/apache/ivy/ant/IvyAntSettingsBuildFileTest.java
 Wed Oct  1 14:12:02 2008
@@ -49,10 +49,21 @@
 }
 
 public void testSettingsWithIdIvyInstance() {
+// IVY-925
 executeTarget(testSettingsWithPropertyAsId);
 ResolveReport report = (ResolveReport) 
getProject().getReference(ivy.resolved.report);
 assertNotNull(report);
 assertFalse(report.hasError());
 assertEquals(1, report.getDependencies().size());
 }
+
+public void testStackOverflow() {
+// IVY-924
+
configureProject(test/java/org/apache/ivy/ant/IvyAntSettingsBuildFileStackOverflow.xml);
+executeTarget(testStackOverflow);
+ResolveReport report = (ResolveReport) 
getProject().getReference(ivy.resolved.report);
+assertNotNull(report);
+assertFalse(report.hasError());
+assertEquals(1, report.getDependencies().size());
+}
 }




svn commit: r700932 - in /ant/ivy/core/trunk: CHANGES.txt src/java/org/apache/ivy/util/url/HttpClientHandler.java

2008-10-01 Thread maartenc
Author: maartenc
Date: Wed Oct  1 14:21:11 2008
New Revision: 700932

URL: http://svn.apache.org/viewvc?rev=700932view=rev
Log:
FIX: HttpClientHandler hanging in certain cases (IVY-930) (thanks to Scott 
Hebert)

Modified:
ant/ivy/core/trunk/CHANGES.txt
ant/ivy/core/trunk/src/java/org/apache/ivy/util/url/HttpClientHandler.java

Modified: ant/ivy/core/trunk/CHANGES.txt
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/CHANGES.txt?rev=700932r1=700931r2=700932view=diff
==
--- ant/ivy/core/trunk/CHANGES.txt (original)
+++ ant/ivy/core/trunk/CHANGES.txt Wed Oct  1 14:21:11 2008
@@ -34,6 +34,7 @@
Tobias Himstedt
Ben Hale
Peter Hayes
+   Scott Hebert
Matt Inger
Anders Janmyr
Christer Jonsson
@@ -96,6 +97,7 @@
 - FIX: StackOverflow when using ivy:settings with ivy.instance as id 
(IVY-924)
 - FIX: Maven Pom reader doesn't handle optional dependencies correctly in some 
instances (IVY-926) (thanks to Phil Messenger)
 - FIX: ivy:settings doesn't work if id is a property (IVY-925)
+- FIX: HttpClientHandler hanging in certain cases (IVY-930) (thanks to Scott 
Hebert)
 
2.0.0-rc1
 =

Modified: 
ant/ivy/core/trunk/src/java/org/apache/ivy/util/url/HttpClientHandler.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/util/url/HttpClientHandler.java?rev=700932r1=700931r2=700932view=diff
==
--- ant/ivy/core/trunk/src/java/org/apache/ivy/util/url/HttpClientHandler.java 
(original)
+++ ant/ivy/core/trunk/src/java/org/apache/ivy/util/url/HttpClientHandler.java 
Wed Oct  1 14:21:11 2008
@@ -94,6 +94,7 @@
 public InputStream openStream(URL url) throws IOException {
 GetMethod get = doGet(url, 0);
 if (!checkStatusCode(url, get)) {
+get.releaseConnection();
 throw new IOException(
 The HTTP response code for  + url +  did not indicate a 
success.
 +  See log for more detail.);
@@ -103,15 +104,18 @@
 
 public void download(URL src, File dest, CopyProgressListener l) throws 
IOException {
 GetMethod get = doGet(src, 0);
-// We can only figure the content we got is want we want if the status 
is success.
-if (!checkStatusCode(src, get)) {
-throw new IOException(
-The HTTP response code for  + src +  did not indicate a 
success.
-+  See log for more detail.);
+try {
+// We can only figure the content we got is want we want if the 
status is success.
+if (!checkStatusCode(src, get)) {
+throw new IOException(
+The HTTP response code for  + src +  did not 
indicate a success.
++  See log for more detail.);
+}
+FileUtil.copy(get.getResponseBodyAsStream(), dest, l);
+dest.setLastModified(getLastModified(get));
+} finally {
+get.releaseConnection();
 }
-FileUtil.copy(get.getResponseBodyAsStream(), dest, l);
-dest.setLastModified(getLastModified(get));
-get.releaseConnection();
 }
 
 public void upload(File src, URL dest, CopyProgressListener l) throws 
IOException {
@@ -133,6 +137,7 @@
 /* ignored */
 }
 }
+put.releaseConnection();
 }
 }
 




[jira] Resolved: (IVY-930) HttpClientHandler hanging in certain cases

2008-10-01 Thread Maarten Coene (JIRA)

 [ 
https://issues.apache.org/jira/browse/IVY-930?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Maarten Coene resolved IVY-930.
---

   Resolution: Fixed
Fix Version/s: trunk

Thank you for reporting!

I've committed your (slighlty modified) patch into SVN trunk.
Please give it a try and post your feedback here.

 HttpClientHandler hanging in certain cases
 --

 Key: IVY-930
 URL: https://issues.apache.org/jira/browse/IVY-930
 Project: Ivy
  Issue Type: Bug
Affects Versions: 2.0-RC1
Reporter: Scott Hebert
Assignee: Maarten Coene
Priority: Blocker
 Fix For: trunk


 Using Commons HttpClient and an URL Resolver, it is possible for the 
 HttpClientHandler to hang.
 The following seems to correct the problem:
 {code:java}
 public InputStream openStream(URL url) throws IOException {
 GetMethod get = doGet(url);
 if (!checkStatusCode(url, get)) {
 // Make sure the number of connections does not get exhausted
 get.releaseConnection();
 //
 throw new IOException(
 The HTTP response code for  + url +  did not indicate 
 a success.
 +  See log for more detail.);
 }
 return new GETInputStream(get);
 }
 public void download(URL src, File dest, CopyProgressListener l) throws 
 IOException {
 GetMethod get = doGet(src);
 // We can only figure the content we got is want we want if the 
 status is success.
 if (!checkStatusCode(src, get)) {
 // Make sure the number of connections does not get exhausted
 get.releaseConnection();
 //
 throw new IOException(
 The HTTP response code for  + src +  did not indicate 
 a success.
 +  See log for more detail.);
 }
 FileUtil.copy(get.getResponseBodyAsStream(), dest, l);
 dest.setLastModified(getLastModified(get));
 get.releaseConnection();
 }
 {code}

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



svn commit: r700941 - in /ant/ivy/core/trunk: CHANGES.txt src/java/org/apache/ivy/util/url/AbstractURLHandler.java src/java/org/apache/ivy/util/url/BasicURLHandler.java src/java/org/apache/ivy/util/ur

2008-10-01 Thread maartenc
Author: maartenc
Date: Wed Oct  1 14:52:11 2008
New Revision: 700941

URL: http://svn.apache.org/viewvc?rev=700941view=rev
Log:
FIX: Can't download files containing space or + in their names by HTTP (IVY-923)

Modified:
ant/ivy/core/trunk/CHANGES.txt
ant/ivy/core/trunk/src/java/org/apache/ivy/util/url/AbstractURLHandler.java
ant/ivy/core/trunk/src/java/org/apache/ivy/util/url/BasicURLHandler.java
ant/ivy/core/trunk/src/java/org/apache/ivy/util/url/HttpClientHandler.java

Modified: ant/ivy/core/trunk/CHANGES.txt
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/CHANGES.txt?rev=700941r1=700940r2=700941view=diff
==
--- ant/ivy/core/trunk/CHANGES.txt (original)
+++ ant/ivy/core/trunk/CHANGES.txt Wed Oct  1 14:52:11 2008
@@ -98,6 +98,7 @@
 - FIX: Maven Pom reader doesn't handle optional dependencies correctly in some 
instances (IVY-926) (thanks to Phil Messenger)
 - FIX: ivy:settings doesn't work if id is a property (IVY-925)
 - FIX: HttpClientHandler hanging in certain cases (IVY-930) (thanks to Scott 
Hebert)
+- FIX: Can't download files containing space or + in their names by HTTP 
(IVY-923)
 
2.0.0-rc1
 =

Modified: 
ant/ivy/core/trunk/src/java/org/apache/ivy/util/url/AbstractURLHandler.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/util/url/AbstractURLHandler.java?rev=700941r1=700940r2=700941view=diff
==
--- ant/ivy/core/trunk/src/java/org/apache/ivy/util/url/AbstractURLHandler.java 
(original)
+++ ant/ivy/core/trunk/src/java/org/apache/ivy/util/url/AbstractURLHandler.java 
Wed Oct  1 14:52:11 2008
@@ -17,12 +17,18 @@
  */
 package org.apache.ivy.util.url;
 
+import java.net.MalformedURLException;
+import java.net.URI;
+import java.net.URISyntaxException;
 import java.net.URL;
 import java.net.HttpURLConnection;
+import java.util.regex.Pattern;
 import java.io.IOException;
 
 public abstract class AbstractURLHandler implements URLHandler {
 
+private static final Pattern ESCAPE_PATTERN = 
Pattern.compile(%25([0-9a-fA-F][0-9a-fA-F]));
+
 // the request method to use. TODO: don't use a static here
 private static int requestMethod = REQUEST_METHOD_HEAD;
 
@@ -79,4 +85,38 @@
 public int getRequestMethod() {
 return requestMethod;
 }
+
+protected String normalizeToString(URL url) throws IOException {
+if (!http.equals(url.getProtocol())  
!https.equals(url.getProtocol())) {
+return url.toExternalForm();
+}
+
+try {
+URI uri = new URI(url.getProtocol(), url.getUserInfo(), 
url.getHost(), 
+url.getPort(), url.getPath(), url.getQuery(), 
url.getRef());
+
+// it is possible that the original url was already (partial) 
escaped,
+// so we must unescape all '%' followed by 2 hexadecimals...
+String uriString = uri.toString();
+
+// manually escape the '+' character
+uriString = uriString.replaceAll(\\+, %2B);
+
+return ESCAPE_PATTERN.matcher(uriString).replaceAll(%$1);
+} catch (URISyntaxException e) {
+IOException ioe = new MalformedURLException(Couldn't convert ' 
++ url.toString() + ' to a valid URI); 
+ioe.initCause(e); 
+throw ioe;
+}
+}
+
+protected URL normalizeToURL(URL url) throws IOException {
+if (!http.equals(url.getProtocol())  
!https.equals(url.getProtocol())) {
+return url;
+}
+
+return new URL(normalizeToString(url));
+}
+
 }

Modified: 
ant/ivy/core/trunk/src/java/org/apache/ivy/util/url/BasicURLHandler.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/util/url/BasicURLHandler.java?rev=700941r1=700940r2=700941view=diff
==
--- ant/ivy/core/trunk/src/java/org/apache/ivy/util/url/BasicURLHandler.java 
(original)
+++ ant/ivy/core/trunk/src/java/org/apache/ivy/util/url/BasicURLHandler.java 
Wed Oct  1 14:52:11 2008
@@ -25,13 +25,9 @@
 import java.io.InputStream;
 import java.io.OutputStream;
 import java.net.HttpURLConnection;
-import java.net.MalformedURLException;
-import java.net.URI;
-import java.net.URISyntaxException;
 import java.net.URL;
 import java.net.URLConnection;
 import java.net.UnknownHostException;
-import java.util.regex.Pattern;
 
 import org.apache.ivy.Ivy;
 import org.apache.ivy.util.CopyProgressListener;
@@ -42,8 +38,6 @@
  * 
  */
 public class BasicURLHandler extends AbstractURLHandler {
-
-private static final Pattern ESCAPE_PATTERN = 
Pattern.compile(%25([0-9a-fA-F][0-9a-fA-F]));
 
 private static final int BUFFER_SIZE = 64 * 1024;
 
@@ -70,7 +64,7 @@
 public 

[jira] Resolved: (IVY-923) Can't download files containing space or + in their names by HTTP

2008-10-01 Thread Maarten Coene (JIRA)

 [ 
https://issues.apache.org/jira/browse/IVY-923?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Maarten Coene resolved IVY-923.
---

   Resolution: Fixed
Fix Version/s: trunk
 Assignee: Maarten Coene

I've committed a fix into SVN trunk.
Could you give it a try and please reopen if the problem hasn't been solved.

 Can't download files containing space or + in their names by HTTP
 -

 Key: IVY-923
 URL: https://issues.apache.org/jira/browse/IVY-923
 Project: Ivy
  Issue Type: Bug
  Components: Core
Affects Versions: 2.0-RC1
Reporter: Pavel Sher
Assignee: Maarten Coene
 Fix For: trunk


 I have an artifact with space in it's name, such artifact can't be downloaded 
 by Ivy 2.0 RC1. The problem is somewhere near the doHead() method of the 
 org.apache.ivy.util.url.HttpClientHandler class. This method receives url but 
 this url contains spaces and when HttpClient HeadMethod is constructed an 
 exception is thrown (which is silently ignored by the way). It seems that URL 
 parts must be properly escaped before sent to HTTP client, since 
 URL.toExternalForm() does not do this.
 The same problem seems to occur if file name contains +.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Resolved: (IVY-915) Examples broken due to removal of antlib.xml from ivy.jar

2008-10-01 Thread Maarten Coene (JIRA)

 [ 
https://issues.apache.org/jira/browse/IVY-915?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Maarten Coene resolved IVY-915.
---

Resolution: Invalid
  Assignee: Maarten Coene

I'll mark this issue as invalid because I think you did use the wrong ivy jar.
Please reopen if this wasn't the case.

 Examples broken due to removal of antlib.xml from ivy.jar
 -

 Key: IVY-915
 URL: https://issues.apache.org/jira/browse/IVY-915
 Project: Ivy
  Issue Type: Bug
  Components: Documentation
Affects Versions: 2.0.0-beta-2
 Environment: Windows, Java 1.5, Ant 1.7.0
Reporter: Tim U
Assignee: Maarten Coene

 I installed Ivy 2.0.0.beta2 as per the first method in the install directions 
 (manually unzip the distribution and copy the ivy jar into ANT_HOME/lib).
 Then upon running 'ant' in the hello-ivy example, the following error occurs 
 in ant:
BUILD FAILED

 C:\java\apache-ivy-2.0.0-beta2\tutorial\src\example\hello-ivy\build.xml:38: 
 Problem: failed to create task or type antlib:org.apache.ivy.ant:retrieve
Cause: The name is undefined.
Action: Check the spelling.
Action: Check that any custom tasks/types have been declared.
Action: Check that any presetdef/macrodef declarations have taken 
 place.
This appears to be an antlib declaration.
Action: Check that the implementing library exists in one of:
-C:\java\apache-ant-1.7.0\lib
-C:\Documents and Settings\timu\.ant\lib
-a directory added on the command line with the -lib argument
 It appears that the examples assume that org/apache/ivy/ant/antlib.xml is 
 present in the ivy.jar.  This file was present in the 2.0.0.beta1 version of 
 the ivy.jar, but appears to have been removed as of beta2.  
 Either the antlib.xml needs to be added back into the ivy jar, or the example 
 build.xml files need to be updated with appropriate taskdefs.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.