Build failed in Hudson: Ant_JDK_1.4 #229

2010-06-09 Thread Apache Hudson Server
See http://hudson.zones.apache.org/hudson/job/Ant_JDK_1.4/229/

--
Started by an SCM change
Building remotely on hudson-solaris (Solaris)
Updating http://svn.apache.org/repos/asf/ant/core/trunk
ERROR: Failed to update http://svn.apache.org/repos/asf/ant/core/trunk
org.tmatesoft.svn.core.SVNException: svn: Connection reset
svn: OPTIONS request failed on '/repos/asf/ant/core/trunk'
at 
org.tmatesoft.svn.core.internal.wc.SVNErrorManager.error(SVNErrorManager.java:103)
at 
org.tmatesoft.svn.core.internal.wc.SVNErrorManager.error(SVNErrorManager.java:87)
at 
org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:616)
at 
org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:273)
at 
org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:261)
at 
org.tmatesoft.svn.core.internal.io.dav.DAVConnection.exchangeCapabilities(DAVConnection.java:516)
at 
org.tmatesoft.svn.core.internal.io.dav.DAVConnection.open(DAVConnection.java:98)
at 
org.tmatesoft.svn.core.internal.io.dav.DAVRepository.openConnection(DAVRepository.java:1001)
at 
org.tmatesoft.svn.core.internal.io.dav.DAVRepository.getRepositoryUUID(DAVRepository.java:146)
at 
org.tmatesoft.svn.core.wc.SVNBasicClient.createRepository(SVNBasicClient.java:342)
at 
org.tmatesoft.svn.core.wc.SVNBasicClient.createRepository(SVNBasicClient.java:330)
at 
org.tmatesoft.svn.core.wc.SVNUpdateClient.update(SVNUpdateClient.java:535)
at 
org.tmatesoft.svn.core.wc.SVNUpdateClient.doUpdate(SVNUpdateClient.java:401)
at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:699)
at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:660)
at hudson.FilePath$FileCallableWrapper.call(FilePath.java:2018)
at hudson.remoting.UserRequest.perform(UserRequest.java:114)
at hudson.remoting.UserRequest.perform(UserRequest.java:48)
at hudson.remoting.Request$2.run(Request.java:270)
at 
java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:417)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:269)
at java.util.concurrent.FutureTask.run(FutureTask.java:123)
at 
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:651)
at 
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:676)
at java.lang.Thread.run(Thread.java:595)
Caused by: java.net.SocketException: Connection reset
at java.net.SocketInputStream.read(SocketInputStream.java:168)
at java.io.BufferedInputStream.fill(BufferedInputStream.java:218)
at java.io.BufferedInputStream.read(BufferedInputStream.java:235)
at 
org.tmatesoft.svn.core.internal.io.dav.http.HTTPParser.readPlainLine(HTTPParser.java:69)
at 
org.tmatesoft.svn.core.internal.io.dav.http.HTTPParser.readLine(HTTPParser.java:51)
at 
org.tmatesoft.svn.core.internal.io.dav.http.HTTPParser.parseStatus(HTTPParser.java:39)
at 
org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.readHeader(HTTPConnection.java:195)
at 
org.tmatesoft.svn.core.internal.io.dav.http.HTTPRequest.dispatch(HTTPRequest.java:175)
at 
org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:345)
... 22 more
Archiving artifacts



Build failed in Hudson: IvyDE-updatesite #266

2010-06-09 Thread Apache Hudson Server
See http://hudson.zones.apache.org/hudson/job/IvyDE-updatesite/266/

--
Started by an SCM change
Building remotely on minerva.apache.org (Ubuntu)
Updating http://svn.apache.org/repos/asf/ant/ivy/updatesite/trunk
ERROR: Failed to update http://svn.apache.org/repos/asf/ant/ivy/updatesite/trunk
org.tmatesoft.svn.core.SVNException: svn: Connection reset
svn: OPTIONS request failed on '/repos/asf/ant/ivy/updatesite/trunk'
at 
org.tmatesoft.svn.core.internal.wc.SVNErrorManager.error(SVNErrorManager.java:103)
at 
org.tmatesoft.svn.core.internal.wc.SVNErrorManager.error(SVNErrorManager.java:87)
at 
org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:616)
at 
org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:273)
at 
org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:261)
at 
org.tmatesoft.svn.core.internal.io.dav.DAVConnection.exchangeCapabilities(DAVConnection.java:516)
at 
org.tmatesoft.svn.core.internal.io.dav.DAVConnection.open(DAVConnection.java:98)
at 
org.tmatesoft.svn.core.internal.io.dav.DAVRepository.openConnection(DAVRepository.java:1001)
at 
org.tmatesoft.svn.core.internal.io.dav.DAVRepository.getRepositoryUUID(DAVRepository.java:146)
at 
org.tmatesoft.svn.core.wc.SVNBasicClient.createRepository(SVNBasicClient.java:342)
at 
org.tmatesoft.svn.core.wc.SVNBasicClient.createRepository(SVNBasicClient.java:330)
at 
org.tmatesoft.svn.core.wc.SVNUpdateClient.update(SVNUpdateClient.java:535)
at 
org.tmatesoft.svn.core.wc.SVNUpdateClient.doUpdate(SVNUpdateClient.java:401)
at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:699)
at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:660)
at hudson.FilePath$FileCallableWrapper.call(FilePath.java:2018)
at hudson.remoting.UserRequest.perform(UserRequest.java:114)
at hudson.remoting.UserRequest.perform(UserRequest.java:48)
at hudson.remoting.Request$2.run(Request.java:270)
at 
java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
at java.util.concurrent.FutureTask.run(FutureTask.java:138)
at 
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at 
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:619)
Caused by: java.net.SocketException: Connection reset
at java.net.SocketInputStream.read(SocketInputStream.java:168)
at java.io.BufferedInputStream.fill(BufferedInputStream.java:218)
at java.io.BufferedInputStream.read(BufferedInputStream.java:237)
at 
org.tmatesoft.svn.core.internal.io.dav.http.HTTPParser.readPlainLine(HTTPParser.java:69)
at 
org.tmatesoft.svn.core.internal.io.dav.http.HTTPParser.readLine(HTTPParser.java:51)
at 
org.tmatesoft.svn.core.internal.io.dav.http.HTTPParser.parseStatus(HTTPParser.java:39)
at 
org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.readHeader(HTTPConnection.java:195)
at 
org.tmatesoft.svn.core.internal.io.dav.http.HTTPRequest.dispatch(HTTPRequest.java:175)
at 
org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:345)
... 22 more
Archiving artifacts



Hudson build is back to normal : IvyDE-updatesite #267

2010-06-09 Thread Apache Hudson Server
See http://hudson.zones.apache.org/hudson/job/IvyDE-updatesite/267/




Hudson build is back to normal : Ant_JDK_1.4 #230

2010-06-09 Thread Apache Hudson Server
See http://hudson.zones.apache.org/hudson/job/Ant_JDK_1.4/230/




[jira] Created: (IVYDE-246) Spurious error handling

2010-06-09 Thread gamhead (JIRA)
Spurious error handling
---

 Key: IVYDE-246
 URL: https://issues.apache.org/jira/browse/IVYDE-246
 Project: IvyDE
  Issue Type: Bug
  Components: workspace resolver
Affects Versions: 2.0.0.final
 Environment: eclipse.buildId=M20090917-0800
java.version=1.6.0_20
java.vendor=Sun Microsystems Inc.
BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=en_GB
Command-line arguments:  -os win32 -ws win32 -arch x86 -data 
C:\Dev\ritchiebd\projects\Workspaces\backtest
Reporter: gamhead


We get the following when we are referencing an Ivy properties file in our 
settings but it is not available

java.lang.NullPointerException
at 
org.apache.ivyde.eclipse.cpcontainer.IvyClasspathContainerConfiguration.doGetIvy(IvyClasspathContainerConfiguration.java:494)
at 
org.apache.ivyde.eclipse.cpcontainer.IvyClasspathContainerConfiguration.getIvy(IvyClasspathContainerConfiguration.java:453)
at 
org.apache.ivyde.eclipse.cpcontainer.IvyResolveJob.run(IvyResolveJob.java:200)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)

Although to be fair we are using the Eclipse special notation:

project:///../build/ivyde-settings.xml

to pull in our settings from our build eclipse project - and this happens when 
that project is closed.

-

Another issue we have is when we try to resolve dependancies but are in a 
debug/run session in Eclipse. 

Because the files are locked Ivy cannot replace them , but the way IvyDE 
reports this is very strange. We get a popup - see attached.

Impossible to resolve dependencies of 
com.rbsfm.hft#backtest-scripts;work...@lonmw85560
  unresolved dependency: com.rbsfm.hft#Filter;TRUNK: not found
  unresolved dependency: com.rbsfm.hft#backtest-api;TRUNK: not found
  unresolved dependency: com.rbsfm.hft#Filter;TRUNK: not found
  unresolved dependency: com.rbsfm.hft#backtest-api;TRUNK: not found
  unresolved dependency: com.rbsfm.hft#Filter;TRUNK: not found
  unresolved dependency: com.rbsfm.hft#backtest-api;TRUNK: not found

Looking in the Ivy Console we can see :

 ERRORS
Couldn't delete outdated artifact from cache: 
C:\ivyrepo\cache\com.rbsfm.hft\Filter\TRUNK\Filter-TRUNK.jar

Couldn't delete outdated artifact from cache: 
C:\ivyrepo\cache\com.rbsfm.hft\backtest-api\TRUNK\backtest-api-TRUNK.jar

.. but would be nice to get the error handling on this improved

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



svn commit: r953001 - in /ant/antlibs/common/trunk: build.xml ivy.xml ivysettings-nexus.xml upload.xml

2010-06-09 Thread bodewig
Author: bodewig
Date: Wed Jun  9 13:41:23 2010
New Revision: 953001

URL: http://svn.apache.org/viewvc?rev=953001view=rev
Log:
first cut at providing nexus upload support for Antlibs based on Antoine's work 
for Ant.  Will be tested by compress-antlib release someday

Added:
ant/antlibs/common/trunk/ivysettings-nexus.xml
  - copied unchanged from r952673, ant/core/trunk/release/ivysettings.xml
ant/antlibs/common/trunk/upload.xml
  - copied, changed from r952673, ant/core/trunk/release/upload.xml
Modified:
ant/antlibs/common/trunk/build.xml
ant/antlibs/common/trunk/ivy.xml

Modified: ant/antlibs/common/trunk/build.xml
URL: 
http://svn.apache.org/viewvc/ant/antlibs/common/trunk/build.xml?rev=953001r1=953000r2=953001view=diff
==
--- ant/antlibs/common/trunk/build.xml (original)
+++ ant/antlibs/common/trunk/build.xml Wed Jun  9 13:41:23 2010
@@ -34,6 +34,8 @@
 property name=build.classes value=${build}/classes/
 property name=build.testclasses value=${build}/test-classes/
 property name=build.lib value=${build}/lib/
+property name=build.javarepository
+  value=${build}/java-repository/
 property name=src.junit location=src/tests/junit/
 property name=src.antunit location=src/tests/antunit/
 
@@ -430,4 +432,36 @@
 
   target name=create-readable-documents
 depends=style-contributors,style-changes/
+
+  !-- uploading of releases --
+  import file=${common.basedir}/upload.xml/
+
+  target name=prepare-upload depends=bindist
+property name=upload.dir
+  
value=${build.javarepository}/org/apache/ant/${artifact.name}/${artifact.version}/
+mkdir dir=${upload.dir}/
+copy file=${jarname} todir=${upload.dir}/
+copy file=${target.pom} todir=${upload.dir}/
+  /target
+
+  target name=check-sigs depends=prepare-upload
+uptodate property=jar.sig.ok
+  srcfile=${upload.dir}/${artifact.stub}.jar
+  targetfile=${upload.dir}/${artifact.stub}.jar.asc/
+uptodate property=pom.sig.ok
+  srcfile=${upload.dir}/${artifact.stub}.pom
+  targetfile=${upload.dir}/${artifact.stub}.pom.asc/
+fail message=Your OpenPGP signature of the artifacts is too old or 
missing
+  condition
+not
+  and
+isset property=jar.sig.ok/
+isset property=pom.sig.ok/
+  /and
+/not
+  /condition
+/fail
+  /target
+
+  target name=upload depends=check-sigs,perform-nexus-upload/
 /project

Modified: ant/antlibs/common/trunk/ivy.xml
URL: 
http://svn.apache.org/viewvc/ant/antlibs/common/trunk/ivy.xml?rev=953001r1=953000r2=953001view=diff
==
--- ant/antlibs/common/trunk/ivy.xml (original)
+++ ant/antlibs/common/trunk/ivy.xml Wed Jun  9 13:41:23 2010
@@ -28,7 +28,7 @@
   !-- == --
   target name=ivy-init
   depends=setup
-property name=ivy.organization value=apache/
+property name=ivy.organization value=org/apache/
 property name=target.ivy.xml
   location=${build.lib}/${artifact.stub}-ivy.xml/
 tstamp
@@ -59,7 +59,7 @@
 echoxml file=${target.ivy.xml}
   ivy-module version=1.3
 info organization=${ivy.organization}
-  module=${artifact.name}
+  module=ant
   revision=${artifact.version}
   publication=${publication.datetime}
   license name=Apache Software License 2.0
@@ -67,6 +67,12 @@
   ivy-author name=Apache Ant Development Team
 url=http://ant.apache.org//
 /info
+publications  
+  artifact name=${artifact.name} type=pom ext=pom/
+  artifact name=${artifact.name} type=pom.asc ext=pom.asc/
+  artifact name=${artifact.name} type=jar ext=jar/
+  artifact name=${artifact.name} type=jar.asc ext=jar.asc/
+/publications
   /ivy-module
 /echoxml
   /target

Copied: ant/antlibs/common/trunk/upload.xml (from r952673, 
ant/core/trunk/release/upload.xml)
URL: 
http://svn.apache.org/viewvc/ant/antlibs/common/trunk/upload.xml?p2=ant/antlibs/common/trunk/upload.xmlp1=ant/core/trunk/release/upload.xmlr1=952673r2=953001rev=953001view=diff
==
--- ant/core/trunk/release/upload.xml (original)
+++ ant/antlibs/common/trunk/upload.xml Wed Jun  9 13:41:23 2010
@@ -1,3 +1,4 @@
+?xml version=1.0?
 !--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements.  See the NOTICE file distributed with
@@ -15,12 +16,25 @@
limitations under the License.
 --
 project name=upload xmlns:ivy=antlib:org.apache.ivy.ant
-  fail unless=upload.user message=supply upload.user on the command line/
-  fail unless=upload.password message=supply upload.password on the 
command line/
-  

svn commit: r953003 - /ant/antlibs/common/trunk/build.xml

2010-06-09 Thread bodewig
Author: bodewig
Date: Wed Jun  9 13:43:01 2010
New Revision: 953003

URL: http://svn.apache.org/viewvc?rev=953003view=rev
Log:
bad target name

Modified:
ant/antlibs/common/trunk/build.xml

Modified: ant/antlibs/common/trunk/build.xml
URL: 
http://svn.apache.org/viewvc/ant/antlibs/common/trunk/build.xml?rev=953003r1=953002r2=953003view=diff
==
--- ant/antlibs/common/trunk/build.xml (original)
+++ ant/antlibs/common/trunk/build.xml Wed Jun  9 13:43:01 2010
@@ -436,7 +436,7 @@
   !-- uploading of releases --
   import file=${common.basedir}/upload.xml/
 
-  target name=prepare-upload depends=bindist
+  target name=prepare-upload depends=bin-dist
 property name=upload.dir
   
value=${build.javarepository}/org/apache/ant/${artifact.name}/${artifact.version}/
 mkdir dir=${upload.dir}/




svn commit: r953004 - /ant/antlibs/antunit/trunk/changes.xml

2010-06-09 Thread bodewig
Author: bodewig
Date: Wed Jun  9 13:46:06 2010
New Revision: 953004

URL: http://svn.apache.org/viewvc?rev=953004view=rev
Log:
typo

Modified:
ant/antlibs/antunit/trunk/changes.xml

Modified: ant/antlibs/antunit/trunk/changes.xml
URL: 
http://svn.apache.org/viewvc/ant/antlibs/antunit/trunk/changes.xml?rev=953004r1=953003r2=953004view=diff
==
--- ant/antlibs/antunit/trunk/changes.xml (original)
+++ ant/antlibs/antunit/trunk/changes.xml Wed Jun  9 13:46:06 2010
@@ -40,7 +40,7 @@
   release version=1.2 date=not-released
 action type=add issue=49168
   It is now possible to pass references from the build file
-  containing the lt:antunitgt; task to the build files under
+  containing the lt;antunitgt; task to the build files under
   test.
 /action
 action type=add




svn commit: r953008 - /ant/antlibs/compress/trunk/project-template.ivy.xml

2010-06-09 Thread bodewig
Author: bodewig
Date: Wed Jun  9 13:52:48 2010
New Revision: 953008

URL: http://svn.apache.org/viewvc?rev=953008view=rev
Log:
Update template Ivy file with publications

Modified:
ant/antlibs/compress/trunk/project-template.ivy.xml

Modified: ant/antlibs/compress/trunk/project-template.ivy.xml
URL: 
http://svn.apache.org/viewvc/ant/antlibs/compress/trunk/project-template.ivy.xml?rev=953008r1=953007r2=953008view=diff
==
--- ant/antlibs/compress/trunk/project-template.ivy.xml (original)
+++ ant/antlibs/compress/trunk/project-template.ivy.xml Wed Jun  9 13:52:48 2010
@@ -19,7 +19,7 @@
 --
 ivy-module version=2.0
   info organization=${ivy.organization}
-module=compress-antlib
+module=ant
 revision=${artifact.version}
 publication=${publication.datetime}
 license name=Apache Software License 2.0
@@ -32,6 +32,12 @@
   Apache Commons Compress.
 /description
   /info
+  publications  
+artifact name=${artifact.name} type=pom ext=pom/
+artifact name=${artifact.name} type=pom.asc ext=pom.asc/
+artifact name=${artifact.name} type=jar ext=jar/
+artifact name=${artifact.name} type=jar.asc ext=jar.asc/
+  /publications
   dependencies
 dependency org=org.apache.ant name=ant revision=[1.8.0,)/
 dependency org=org.apache.commons name=commons-compress




svn commit: r953046 - in /ant/core/trunk/src: main/org/apache/tools/ant/DirectoryScanner.java tests/junit/org/apache/tools/ant/DirectoryScannerTest.java tests/junit/org/apache/tools/ant/types/selector

2010-06-09 Thread bodewig
Author: bodewig
Date: Wed Jun  9 15:44:46 2010
New Revision: 953046

URL: http://svn.apache.org/viewvc?rev=953046view=rev
Log:
some JUnit tests to verify/falsify 
http://mail-archives.apache.org/mod_mbox/ant-user/201006.mbox/%3c28829117.p...@talk.nabble.com%3e

Added:

ant/core/trunk/src/tests/junit/org/apache/tools/ant/types/selectors/TokenizedPatternTest.java
   (with props)
Modified:
ant/core/trunk/src/main/org/apache/tools/ant/DirectoryScanner.java

ant/core/trunk/src/tests/junit/org/apache/tools/ant/DirectoryScannerTest.java

Modified: ant/core/trunk/src/main/org/apache/tools/ant/DirectoryScanner.java
URL: 
http://svn.apache.org/viewvc/ant/core/trunk/src/main/org/apache/tools/ant/DirectoryScanner.java?rev=953046r1=953045r2=953046view=diff
==
--- ant/core/trunk/src/main/org/apache/tools/ant/DirectoryScanner.java 
(original)
+++ ant/core/trunk/src/main/org/apache/tools/ant/DirectoryScanner.java Wed Jun  
9 15:44:46 2010
@@ -1458,7 +1458,7 @@ public class DirectoryScanner
  * @param path the path to check.
  * @return whether all the specified directory's contents are excluded.
  */
-private boolean contentsExcluded(TokenizedPath path) {
+/* package */ boolean contentsExcluded(TokenizedPath path) {
 for (int i = 0; i  excludePatterns.length; i++) {
 if (excludePatterns[i].endsWith(SelectorUtils.DEEP_TREE_MATCH)
  excludePatterns[i].withoutLastToken()
@@ -1783,7 +1783,7 @@ public class DirectoryScanner
  *
  * @since Ant 1.6.3
  */
-private synchronized void ensureNonPatternSetsReady() {
+/* package */ synchronized void ensureNonPatternSetsReady() {
 if (!areNonPatternSetsReady) {
 includePatterns = fillNonPatternSet(includeNonPatterns, includes);
 excludePatterns = fillNonPatternSet(excludeNonPatterns, excludes);

Modified: 
ant/core/trunk/src/tests/junit/org/apache/tools/ant/DirectoryScannerTest.java
URL: 
http://svn.apache.org/viewvc/ant/core/trunk/src/tests/junit/org/apache/tools/ant/DirectoryScannerTest.java?rev=953046r1=953045r2=953046view=diff
==
--- 
ant/core/trunk/src/tests/junit/org/apache/tools/ant/DirectoryScannerTest.java 
(original)
+++ 
ant/core/trunk/src/tests/junit/org/apache/tools/ant/DirectoryScannerTest.java 
Wed Jun  9 15:44:46 2010
@@ -19,10 +19,10 @@
 package org.apache.tools.ant;
 
 import org.apache.tools.ant.taskdefs.condition.Os;
+import org.apache.tools.ant.types.selectors.TokenizedPath;
 import org.apache.tools.ant.util.FileUtils;
 import org.apache.tools.ant.util.SymbolicLinkUtils;
 
-
 import java.io.File;
 import java.io.IOException;
 import java.util.Arrays;
@@ -555,4 +555,15 @@ public class DirectoryScannerTest extend
files.contains(alpha/beta/gamma/gamma.xml
   .replace('/', File.separatorChar)));
 }
+
+public void testContentsExcluded() {
+DirectoryScanner ds = new DirectoryScanner();
+ds.setBasedir(new File(.));
+ds.setIncludes(new String[] {**});
+ds.addDefaultExcludes();
+ds.ensureNonPatternSetsReady();
+File f = new File(.svn);
+TokenizedPath p = new TokenizedPath(f.getAbsolutePath());
+assertTrue(ds.contentsExcluded(p));
+}
 }

Added: 
ant/core/trunk/src/tests/junit/org/apache/tools/ant/types/selectors/TokenizedPatternTest.java
URL: 
http://svn.apache.org/viewvc/ant/core/trunk/src/tests/junit/org/apache/tools/ant/types/selectors/TokenizedPatternTest.java?rev=953046view=auto
==
--- 
ant/core/trunk/src/tests/junit/org/apache/tools/ant/types/selectors/TokenizedPatternTest.java
 (added)
+++ 
ant/core/trunk/src/tests/junit/org/apache/tools/ant/types/selectors/TokenizedPatternTest.java
 Wed Jun  9 15:44:46 2010
@@ -0,0 +1,57 @@
+/*
+ *  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.
+ *
+ */
+
+package org.apache.tools.ant.types.selectors;
+
+import java.io.File;
+import junit.framework.TestCase;
+
+public class TokenizedPatternTest extends TestCase {
+ 

svn commit: r953111 - in /ant/ivy/core/trunk: ./ src/java/org/apache/ivy/core/cache/ src/java/org/apache/ivy/core/settings/ src/java/org/apache/ivy/plugins/parser/ src/java/org/apache/ivy/plugins/pars

2010-06-09 Thread maartenc
Author: maartenc
Date: Wed Jun  9 18:40:35 2010
New Revision: 953111

URL: http://svn.apache.org/viewvc?rev=953111view=rev
Log:
FIX: Namespace rules not properly applied to parent projects (IVY-1186)

Added:
ant/ivy/core/trunk/test/repositories/parentPom/ivysettings-namespace.xml   
(with props)
Modified:
ant/ivy/core/trunk/CHANGES.txt

ant/ivy/core/trunk/src/java/org/apache/ivy/core/cache/DefaultRepositoryCacheManager.java

ant/ivy/core/trunk/src/java/org/apache/ivy/core/cache/ParserSettingsMonitor.java
ant/ivy/core/trunk/src/java/org/apache/ivy/core/settings/IvySettings.java

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

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

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

ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorParser.java

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

ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/resolver/RepositoryResolver.java
ant/ivy/core/trunk/test/java/org/apache/ivy/core/resolve/ResolveTest.java

Modified: ant/ivy/core/trunk/CHANGES.txt
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/CHANGES.txt?rev=953111r1=953110r2=953111view=diff
==
--- ant/ivy/core/trunk/CHANGES.txt (original)
+++ ant/ivy/core/trunk/CHANGES.txt Wed Jun  9 18:40:35 2010
@@ -126,6 +126,7 @@ for detailed view of each issue, please 
 - IMPROVEMENT: Trace a message when a property file referenced from the 
settings doesn't exixts (IVY-1074)
 - IMPROVEMENT: use defaultconf in combination with defaultconfmapping 
(IVY-1135) (thanks to Jon Schneider)
 
+- FIX: Namespace rules not properly applied to parent projects (IVY-1186)
 - FIX: LatestVersionMatcher.needModuleDescriptor() does not honor custom 
statuses (IVY-1170) (thanks to Carl Quinn)
 - FIX: Proxy authentication could fail when using commons-httpclient 
 - FIX: Packager resolver always extracts all files from archives even when the 
packaging instructions contains include tags (IVY-1179) (thanks to Stefan De 
Boey)

Modified: 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/cache/DefaultRepositoryCacheManager.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/core/cache/DefaultRepositoryCacheManager.java?rev=953111r1=953110r2=953111view=diff
==
--- 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/cache/DefaultRepositoryCacheManager.java
 (original)
+++ 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/cache/DefaultRepositoryCacheManager.java
 Wed Jun  9 18:40:35 2010
@@ -52,6 +52,7 @@ import org.apache.ivy.plugins.repository
 import org.apache.ivy.plugins.repository.Resource;
 import org.apache.ivy.plugins.repository.ResourceDownloader;
 import org.apache.ivy.plugins.repository.ResourceHelper;
+import org.apache.ivy.plugins.resolver.AbstractResolver;
 import org.apache.ivy.plugins.resolver.DependencyResolver;
 import org.apache.ivy.plugins.resolver.util.ResolvedResource;
 import org.apache.ivy.util.Checks;
@@ -646,14 +647,16 @@ public class DefaultRepositoryCacheManag
 private class MyModuleDescriptorProvider implements 
ModuleDescriptorProvider {
 
 private final ModuleDescriptorParser mdParser;
+private final ParserSettings settings;
 
-public MyModuleDescriptorProvider(ModuleDescriptorParser mdParser) {
-this.mdParser = mdParser;
+public MyModuleDescriptorProvider(ModuleDescriptorParser mdParser, 
ParserSettings settings) {
+this.mdParser = mdParser;
+this.settings = settings;
 }
 
 public ModuleDescriptor provideModule(ParserSettings ivySettings, 
 File descriptorURL, boolean validate) throws ParseException, 
IOException {
-return mdParser.parseDescriptor(ivySettings, 
descriptorURL.toURI().toURL(), validate);
+return mdParser.parseDescriptor(settings, 
descriptorURL.toURI().toURL(), validate);
 }
 }
 
@@ -661,15 +664,15 @@ public class DefaultRepositoryCacheManag
 CacheMetadataOptions options, File ivyFile) 
 throws ParseException, IOException {
 ModuleDescriptorMemoryCache cache = getMemoryCache();
-ModuleDescriptorProvider mdProvider = new 
MyModuleDescriptorProvider(mdParser); 
+ModuleDescriptorProvider mdProvider = new 
MyModuleDescriptorProvider(mdParser, settings); 
 return cache.get(ivyFile, settings, options.isValidate(), mdProvider);
 }
 
 private ModuleDescriptor getStaledMd(ModuleDescriptorParser mdParser, 
-CacheMetadataOptions options, File 

svn commit: r953116 - /ant/ivy/core/trunk/build.xml

2010-06-09 Thread gscokart
Author: gscokart
Date: Wed Jun  9 19:03:35 2010
New Revision: 953116

URL: http://svn.apache.org/viewvc?rev=953116view=rev
Log:
Simplify the output of ant -p

Modified:
ant/ivy/core/trunk/build.xml

Modified: ant/ivy/core/trunk/build.xml
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/build.xml?rev=953116r1=953115r2=953116view=diff
==
--- ant/ivy/core/trunk/build.xml (original)
+++ ant/ivy/core/trunk/build.xml Wed Jun  9 19:03:35 2010
@@ -543,7 +543,8 @@
 /apply
 /target
 
-target name=checkstyle-internal depends=jar description=checks Ivy 
codebase according to ${checkstyle.src.dir}/checkstyle-config
+!-- Checks Ivy codebase according to 
${checkstyle.src.dir}/checkstyle-config  --
+target name=checkstyle-internal depends=jar
 ivy:cachepath organisation=checkstyle module=checkstyle 
revision=4.3
 inline=true conf=default pathid=checkstyle.classpath 
transitive=true 
log=download-only/




[jira] Commented: (IVY-1195) feature request: retrying resolver wrapper

2010-06-09 Thread Maarten Coene (JIRA)

[ 
https://issues.apache.org/jira/browse/IVY-1195?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=12877174#action_12877174
 ] 

Maarten Coene commented on IVY-1195:


I think this should be a feature of your buildserver that should not start 
building app if lib is currently being build (or queued for building).

 feature request: retrying resolver wrapper
 --

 Key: IVY-1195
 URL: https://issues.apache.org/jira/browse/IVY-1195
 Project: Ivy
  Issue Type: New Feature
  Components: Core
Affects Versions: 2.1.0
Reporter: Stepan Koltsov

 I'm requesting a retrying resolver.
 *description*
 Retrying resolver delegates resolution to configured child resolver. If child 
 resolver fails, if requests child to perform a resolution again after some 
 time.
 *example*
 {code}
 resolvers
   retry name=default timeout=5m start=10s exp=1.5
 svn .../
   /retry
 /resolvers
 {code}
 In the example above, default resolver will try call SVN resolver to 
 resolve dependencies, if SVN resolver fails, it will be called again after 
 10s, then after 15s, then after 27s, and so on, but not after 5 minutes after 
 resolver start.
 *motivation*
 We have build server, that builds projects right after commit. Projects 
 depend on concrete revisions of another projects, revisions are specified in 
 ivy.xml (say, app depends on lib). Sometimes developers commit to 
 dependent project  app immediately after commit to the base project lib. 
 And in this case there is a high chance, that base project lib is not yet 
 built (so artifact is not published) at the time of dependent project app 
 ivy:resolve task run. So build of dependent project app fails.
 Retry task could resolve this situation: dependent project app build start 
 will be delayed until completion of lib build.

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



svn commit: r953123 - in /ant/ivy/core/trunk/src/java/org/apache/ivy: ./ core/module/descriptor/ core/resolve/ core/sort/ plugins/parser/ plugins/parser/xml/ util/url/

2010-06-09 Thread gscokart
Author: gscokart
Date: Wed Jun  9 19:26:15 2010
New Revision: 953123

URL: http://svn.apache.org/viewvc?rev=953123view=rev
Log:
organize import automatically from eclipse, then manually to remove the one 
reported as unused by checkstyle (the classes used in the comment)

Modified:
ant/ivy/core/trunk/src/java/org/apache/ivy/Ivy.java

ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/descriptor/DefaultExtendsDescriptor.java
ant/ivy/core/trunk/src/java/org/apache/ivy/core/resolve/IvyNode.java
ant/ivy/core/trunk/src/java/org/apache/ivy/core/resolve/ResolveEngine.java
ant/ivy/core/trunk/src/java/org/apache/ivy/core/sort/SortEngine.java

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

ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorParser.java

ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorWriter.java
ant/ivy/core/trunk/src/java/org/apache/ivy/util/url/ApacheURLLister.java

Modified: ant/ivy/core/trunk/src/java/org/apache/ivy/Ivy.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/Ivy.java?rev=953123r1=953122r2=953123view=diff
==
--- ant/ivy/core/trunk/src/java/org/apache/ivy/Ivy.java (original)
+++ ant/ivy/core/trunk/src/java/org/apache/ivy/Ivy.java Wed Jun  9 19:26:15 2010
@@ -58,7 +58,6 @@ import org.apache.ivy.core.search.Search
 import org.apache.ivy.core.settings.IvySettings;
 import org.apache.ivy.core.sort.SortEngine;
 import org.apache.ivy.core.sort.SortOptions;
-import org.apache.ivy.plugins.circular.CircularDependencyException;
 import org.apache.ivy.plugins.matcher.PatternMatcher;
 import org.apache.ivy.plugins.repository.TransferEvent;
 import org.apache.ivy.plugins.repository.TransferListener;

Modified: 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/descriptor/DefaultExtendsDescriptor.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/descriptor/DefaultExtendsDescriptor.java?rev=953123r1=953122r2=953123view=diff
==
--- 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/descriptor/DefaultExtendsDescriptor.java
 (original)
+++ 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/descriptor/DefaultExtendsDescriptor.java
 Wed Jun  9 19:26:15 2010
@@ -1,10 +1,10 @@
 package org.apache.ivy.core.module.descriptor;
 
-import org.apache.ivy.core.module.id.ModuleRevisionId;
-
 import java.util.ArrayList;
 import java.util.List;
 
+import org.apache.ivy.core.module.id.ModuleRevisionId;
+
 public class DefaultExtendsDescriptor implements ExtendsDescriptor {
 
 private ModuleRevisionId parentRevisionId;

Modified: ant/ivy/core/trunk/src/java/org/apache/ivy/core/resolve/IvyNode.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/core/resolve/IvyNode.java?rev=953123r1=953122r2=953123view=diff
==
--- ant/ivy/core/trunk/src/java/org/apache/ivy/core/resolve/IvyNode.java 
(original)
+++ ant/ivy/core/trunk/src/java/org/apache/ivy/core/resolve/IvyNode.java Wed 
Jun  9 19:26:15 2010
@@ -51,7 +51,6 @@ import org.apache.ivy.core.module.id.Mod
 import org.apache.ivy.core.resolve.IvyNodeCallers.Caller;
 import org.apache.ivy.core.resolve.IvyNodeEviction.EvictionData;
 import org.apache.ivy.plugins.conflict.ConflictManager;
-import org.apache.ivy.plugins.conflict.LatestCompatibleConflictManager;
 import org.apache.ivy.plugins.matcher.MatcherHelper;
 import org.apache.ivy.plugins.resolver.DependencyResolver;
 import org.apache.ivy.util.Message;

Modified: 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/resolve/ResolveEngine.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/core/resolve/ResolveEngine.java?rev=953123r1=953122r2=953123view=diff
==
--- ant/ivy/core/trunk/src/java/org/apache/ivy/core/resolve/ResolveEngine.java 
(original)
+++ ant/ivy/core/trunk/src/java/org/apache/ivy/core/resolve/ResolveEngine.java 
Wed Jun  9 19:26:15 2010
@@ -57,7 +57,6 @@ import org.apache.ivy.core.report.Downlo
 import org.apache.ivy.core.report.DownloadStatus;
 import org.apache.ivy.core.report.ResolveReport;
 import org.apache.ivy.core.resolve.IvyNodeEviction.EvictionData;
-import org.apache.ivy.core.settings.IvySettings;
 import org.apache.ivy.core.sort.SortEngine;
 import org.apache.ivy.core.sort.SortOptions;
 import org.apache.ivy.plugins.conflict.ConflictManager;

Modified: ant/ivy/core/trunk/src/java/org/apache/ivy/core/sort/SortEngine.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/core/sort/SortEngine.java?rev=953123r1=953122r2=953123view=diff

svn commit: r953128 - in /ant/ivy/core/trunk/src/java/org/apache/ivy: core/event/ core/module/descriptor/ plugins/parser/xml/

2010-06-09 Thread gscokart
Author: gscokart
Date: Wed Jun  9 19:33:11 2010
New Revision: 953128

URL: http://svn.apache.org/viewvc?rev=953128view=rev
Log:
Remove checkstyle WhitespaceAfterCheck errors

Modified:
ant/ivy/core/trunk/src/java/org/apache/ivy/core/event/IvyEvent.java

ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/descriptor/DefaultExtendsDescriptor.java

ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/descriptor/DefaultModuleDescriptor.java

ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorParser.java

ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorUpdater.java

Modified: ant/ivy/core/trunk/src/java/org/apache/ivy/core/event/IvyEvent.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/core/event/IvyEvent.java?rev=953128r1=953127r2=953128view=diff
==
--- ant/ivy/core/trunk/src/java/org/apache/ivy/core/event/IvyEvent.java 
(original)
+++ ant/ivy/core/trunk/src/java/org/apache/ivy/core/event/IvyEvent.java Wed Jun 
 9 19:33:11 2010
@@ -66,7 +66,7 @@ public class IvyEvent {
 protected void addMridAttributes(ModuleRevisionId mrid) {
 addModuleIdAttributes(mrid.getModuleId());
 addAttribute(revision, mrid.getRevision());
-addAttribute(branch,mrid.getBranch());
+addAttribute(branch, mrid.getBranch());
 addAttributes(mrid.getQualifiedExtraAttributes());
 addAttributes(mrid.getExtraAttributes());
 }

Modified: 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/descriptor/DefaultExtendsDescriptor.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/descriptor/DefaultExtendsDescriptor.java?rev=953128r1=953127r2=953128view=diff
==
--- 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/descriptor/DefaultExtendsDescriptor.java
 (original)
+++ 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/descriptor/DefaultExtendsDescriptor.java
 Wed Jun  9 19:33:11 2010
@@ -37,7 +37,7 @@ public class DefaultExtendsDescriptor im
 }
 
 public String[] getExtendsTypes() {
-return (String[])extendsTypes.toArray(new String[extendsTypes.size()]);
+return (String[]) extendsTypes.toArray(new 
String[extendsTypes.size()]);
 }
 
 public boolean isAllInherited() {

Modified: 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/descriptor/DefaultModuleDescriptor.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/descriptor/DefaultModuleDescriptor.java?rev=953128r1=953127r2=953128view=diff
==
--- 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/descriptor/DefaultModuleDescriptor.java
 (original)
+++ 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/descriptor/DefaultModuleDescriptor.java
 Wed Jun  9 19:33:11 2010
@@ -389,7 +389,7 @@ public class DefaultModuleDescriptor imp
 }
 
 public ExtendsDescriptor[] getInheritedDescriptors() {
-return (ExtendsDescriptor[])inheritedDescriptors.toArray(
+return (ExtendsDescriptor[]) inheritedDescriptors.toArray(
 new ExtendsDescriptor[inheritedDescriptors.size()]);
 }
 

Modified: 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorParser.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorParser.java?rev=953128r1=953127r2=953128view=diff
==
--- 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorParser.java
 (original)
+++ 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorParser.java
 Wed Jun  9 19:33:11 2010
@@ -439,7 +439,7 @@ public class XmlModuleDescriptorParser e
 parent.getModuleRevisionId(),
 parent.getResolvedModuleRevisionId(),
 attributes.getValue(location),
-(String[])extendTypes.toArray(new 
String[extendTypes.size()]));
+(String[]) extendTypes.toArray(new 
String[extendTypes.size()]));
 getMd().addInheritedDescriptor(ed);
 
 mergeWithOtherModuleDescriptor(extendTypes, parent);
@@ -498,7 +498,8 @@ public class XmlModuleDescriptorParser e
 
 descriptor.setStatus(mergeValue(parent.getStatus(), 
descriptor.getStatus()));
 if (descriptor.getNamespace() == null  parent instanceof 
DefaultModuleDescriptor) {
-
descriptor.setNamespace(((DefaultModuleDescriptor)parent).getNamespace());
+Namespace parentNamespace = ( (DefaultModuleDescriptor) 
parent).getNamespace();
+

[jira] Commented: (IVY-1195) feature request: retrying resolver wrapper

2010-06-09 Thread Stepan Koltsov (JIRA)

[ 
https://issues.apache.org/jira/browse/IVY-1195?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=12877177#action_12877177
 ] 

Stepan Koltsov commented on IVY-1195:
-

* There are tons of build servers. Some people use simple cron + shell to build 
projects.

* Lib build may not be yet scheduled, because SVN is not checked for new 
version (but app is scheduled, because it lives in another SVN repository, 
that is checked at different schedule)

* Buildserver may be building another version of lib, and and this case build 
of app should not be delayed

* It build of next version if lib is scheduled, build of app should not be 
postponed

 feature request: retrying resolver wrapper
 --

 Key: IVY-1195
 URL: https://issues.apache.org/jira/browse/IVY-1195
 Project: Ivy
  Issue Type: New Feature
  Components: Core
Affects Versions: 2.1.0
Reporter: Stepan Koltsov

 I'm requesting a retrying resolver.
 *description*
 Retrying resolver delegates resolution to configured child resolver. If child 
 resolver fails, if requests child to perform a resolution again after some 
 time.
 *example*
 {code}
 resolvers
   retry name=default timeout=5m start=10s exp=1.5
 svn .../
   /retry
 /resolvers
 {code}
 In the example above, default resolver will try call SVN resolver to 
 resolve dependencies, if SVN resolver fails, it will be called again after 
 10s, then after 15s, then after 27s, and so on, but not after 5 minutes after 
 resolver start.
 *motivation*
 We have build server, that builds projects right after commit. Projects 
 depend on concrete revisions of another projects, revisions are specified in 
 ivy.xml (say, app depends on lib). Sometimes developers commit to 
 dependent project  app immediately after commit to the base project lib. 
 And in this case there is a high chance, that base project lib is not yet 
 built (so artifact is not published) at the time of dependent project app 
 ivy:resolve task run. So build of dependent project app fails.
 Retry task could resolve this situation: dependent project app build start 
 will be delayed until completion of lib build.

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



svn commit: r953130 - in /ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/descriptor: DefaultExtendsDescriptor.java ExtendsDescriptor.java

2010-06-09 Thread gscokart
Author: gscokart
Date: Wed Jun  9 19:41:47 2010
New Revision: 953130

URL: http://svn.apache.org/viewvc?rev=953130view=rev
Log:
add missing headers.  The files come from a patch of IVY-742

Modified:

ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/descriptor/DefaultExtendsDescriptor.java

ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/descriptor/ExtendsDescriptor.java

Modified: 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/descriptor/DefaultExtendsDescriptor.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/descriptor/DefaultExtendsDescriptor.java?rev=953130r1=953129r2=953130view=diff
==
--- 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/descriptor/DefaultExtendsDescriptor.java
 (original)
+++ 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/descriptor/DefaultExtendsDescriptor.java
 Wed Jun  9 19:41:47 2010
@@ -1,3 +1,20 @@
+/*
+ *  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.
+ *
+ */
 package org.apache.ivy.core.module.descriptor;
 
 import java.util.ArrayList;

Modified: 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/descriptor/ExtendsDescriptor.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/descriptor/ExtendsDescriptor.java?rev=953130r1=953129r2=953130view=diff
==
--- 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/descriptor/ExtendsDescriptor.java
 (original)
+++ 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/descriptor/ExtendsDescriptor.java
 Wed Jun  9 19:41:47 2010
@@ -1,3 +1,20 @@
+/*
+ *  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.
+ *
+ */
 package org.apache.ivy.core.module.descriptor;
 
 import org.apache.ivy.core.module.id.ModuleRevisionId;




svn commit: r953137 - in /ant/ivy/core/trunk/src/java/org/apache/ivy: core/resolve/ResolveData.java core/search/SearchEngine.java plugins/parser/xml/XmlModuleDescriptorUpdater.java

2010-06-09 Thread gscokart
Author: gscokart
Date: Wed Jun  9 20:02:06 2010
New Revision: 953137

URL: http://svn.apache.org/viewvc?rev=953137view=rev
Log:
Remove EmptyForIteratorPadCheck checkstyle errors

Modified:
ant/ivy/core/trunk/src/java/org/apache/ivy/core/resolve/ResolveData.java
ant/ivy/core/trunk/src/java/org/apache/ivy/core/search/SearchEngine.java

ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorUpdater.java

Modified: 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/resolve/ResolveData.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/core/resolve/ResolveData.java?rev=953137r1=953136r2=953137view=diff
==
--- ant/ivy/core/trunk/src/java/org/apache/ivy/core/resolve/ResolveData.java 
(original)
+++ ant/ivy/core/trunk/src/java/org/apache/ivy/core/resolve/ResolveData.java 
Wed Jun  9 20:02:06 2010
@@ -214,7 +214,7 @@ public class ResolveData {
 // search again, now ignore the extra attributes
 // TODO: maybe we should search the node that has at least the 
 // same attributes as mrid
-for (Iterator it = visitData.entrySet().iterator(); it.hasNext(); 
) {
+for (Iterator it = visitData.entrySet().iterator(); it.hasNext();) 
{
 Map.Entry entry = (Entry) it.next();
 ModuleRevisionId current = (ModuleRevisionId) entry.getKey();
 if (current.getModuleId().equals(mrid.getModuleId())

Modified: 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/search/SearchEngine.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/core/search/SearchEngine.java?rev=953137r1=953136r2=953137view=diff
==
--- ant/ivy/core/trunk/src/java/org/apache/ivy/core/search/SearchEngine.java 
(original)
+++ ant/ivy/core/trunk/src/java/org/apache/ivy/core/search/SearchEngine.java 
Wed Jun  9 20:02:06 2010
@@ -229,7 +229,7 @@ public class SearchEngine {
 List ret = new ArrayList();
 
 Map criteria = new HashMap();
-for (Iterator it = moduleCrit.getAttributes().entrySet().iterator(); 
it.hasNext(); ) {
+for (Iterator it = moduleCrit.getAttributes().entrySet().iterator(); 
it.hasNext();) {
 Map.Entry entry = (Entry) it.next();
 addMatcher(matcher, (String) entry.getValue(), criteria, (String) 
entry.getKey());
 }
@@ -247,7 +247,8 @@ public class SearchEngine {
 String rev = (String) 
moduleIdAsMap[i].get(IvyPatternHelper.REVISION_KEY);
 
 Map foundExtraAtts = new HashMap();
-for (Iterator iter2 = 
moduleCrit.getQualifiedExtraAttributes().keySet().iterator(); iter2.hasNext(); 
) {
+Set qualAttributes = 
moduleCrit.getQualifiedExtraAttributes().keySet();
+for (Iterator iter2 = qualAttributes.iterator(); 
iter2.hasNext();) {
 String qualifiedKey = (String) iter2.next();
 String value = null;
 int colonIndex = qualifiedKey.indexOf(':');
@@ -284,7 +285,7 @@ public class SearchEngine {
 public ModuleRevisionId[] listModules(
 DependencyResolver resolver, ModuleRevisionId moduleCrit, 
PatternMatcher matcher) {
 Map criteria = new HashMap();
-for (Iterator it = moduleCrit.getAttributes().entrySet().iterator(); 
it.hasNext(); ) {
+for (Iterator it = moduleCrit.getAttributes().entrySet().iterator(); 
it.hasNext();) {
 Map.Entry entry = (Entry) it.next();
 addMatcher(matcher, (String) entry.getValue(), criteria, (String) 
entry.getKey());
 }
@@ -301,7 +302,8 @@ public class SearchEngine {
 String rev = (String) 
moduleIdAsMap[i].get(IvyPatternHelper.REVISION_KEY);
 
 Map foundExtraAtts = new HashMap();
-for (Iterator iter2 = 
moduleCrit.getQualifiedExtraAttributes().keySet().iterator(); iter2.hasNext(); 
) {
+Set qualExtraAttributes = 
moduleCrit.getQualifiedExtraAttributes().keySet();
+for (Iterator iter2 = qualExtraAttributes.iterator(); 
iter2.hasNext();) {
 String qualifiedKey = (String) iter2.next();
 String value = null;
 int colonIndex = qualifiedKey.indexOf(':');

Modified: 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorUpdater.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorUpdater.java?rev=953137r1=953136r2=953137view=diff
==
--- 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorUpdater.java
 (original)
+++ 

[jira] Commented: (IVY-1195) feature request: retrying resolver wrapper

2010-06-09 Thread Maarten Coene (JIRA)

[ 
https://issues.apache.org/jira/browse/IVY-1195?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=12877184#action_12877184
 ] 

Maarten Coene commented on IVY-1195:


ok fair enough, although I'm not convinced yet this should be a standard Ivy 
resolver. I think the use-case is too limited for it at the moment.

But luckily, Ivy is very extensible and allows custom resolvers to be plugged 
in very easily.
So maybe you could try to write such a resolver yourself? And if you think 
others could find it useful as well, attach it to this issue or start a project 
on sourceforge, googlecode, ... to share this resolver with the community (like 
there is a similar project for an SVN resolver for instance)

 feature request: retrying resolver wrapper
 --

 Key: IVY-1195
 URL: https://issues.apache.org/jira/browse/IVY-1195
 Project: Ivy
  Issue Type: New Feature
  Components: Core
Affects Versions: 2.1.0
Reporter: Stepan Koltsov

 I'm requesting a retrying resolver.
 *description*
 Retrying resolver delegates resolution to configured child resolver. If child 
 resolver fails, if requests child to perform a resolution again after some 
 time.
 *example*
 {code}
 resolvers
   retry name=default timeout=5m start=10s exp=1.5
 svn .../
   /retry
 /resolvers
 {code}
 In the example above, default resolver will try call SVN resolver to 
 resolve dependencies, if SVN resolver fails, it will be called again after 
 10s, then after 15s, then after 27s, and so on, but not after 5 minutes after 
 resolver start.
 *motivation*
 We have build server, that builds projects right after commit. Projects 
 depend on concrete revisions of another projects, revisions are specified in 
 ivy.xml (say, app depends on lib). Sometimes developers commit to 
 dependent project  app immediately after commit to the base project lib. 
 And in this case there is a high chance, that base project lib is not yet 
 built (so artifact is not published) at the time of dependent project app 
 ivy:resolve task run. So build of dependent project app fails.
 Retry task could resolve this situation: dependent project app build start 
 will be delayed until completion of lib build.

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



svn commit: r953139 - /ant/ivy/core/trunk/src/java/org/apache/ivy/util/url/BasicURLHandler.java

2010-06-09 Thread gscokart
Author: gscokart
Date: Wed Jun  9 20:10:21 2010
New Revision: 953139

URL: http://svn.apache.org/viewvc?rev=953139view=rev
Log:
Remove EmptyBlockCheck checkstyle error

Modified:
ant/ivy/core/trunk/src/java/org/apache/ivy/util/url/BasicURLHandler.java

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=953139r1=953138r2=953139view=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 Jun  9 20:10:21 2010
@@ -242,6 +242,9 @@ public class BasicURLHandler extends Abs
 }
 }
 
+/** 
+ * Read and ignore the response body. 
+ */
 private void readResponseBody(HttpURLConnection conn) {
 byte[] buffer = new byte[BUFFER_SIZE];
 
@@ -249,6 +252,7 @@ public class BasicURLHandler extends Abs
 try {
 inStream = conn.getInputStream();
 while (inStream.read(buffer)  0) {
+//Skip content
 }
 } catch (IOException e) {
 // ignore
@@ -266,6 +270,7 @@ public class BasicURLHandler extends Abs
 if (errStream != null) {
 try {
 while (errStream.read(buffer)  0) {
+//Skip content
 }
 } catch (IOException e) {
 // ignore




svn commit: r953143 - in /ant/ivy/core/trunk/src/java/org/apache/ivy: core/module/id/ModuleRevisionId.java plugins/parser/xml/XmlModuleDescriptorParser.java plugins/parser/xml/XmlModuleDescriptorUpdat

2010-06-09 Thread gscokart
Author: gscokart
Date: Wed Jun  9 20:14:47 2010
New Revision: 953143

URL: http://svn.apache.org/viewvc?rev=953143view=rev
Log:
remove ParenPadCheck checkstyle errors

Modified:

ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/id/ModuleRevisionId.java

ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorParser.java

ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorUpdater.java

Modified: 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/id/ModuleRevisionId.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/id/ModuleRevisionId.java?rev=953143r1=953142r2=953143view=diff
==
--- 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/id/ModuleRevisionId.java 
(original)
+++ 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/id/ModuleRevisionId.java 
Wed Jun  9 20:14:47 2010
@@ -343,7 +343,7 @@ public class ModuleRevisionId extends Un
  * characters. Cfr. http://docs.codehaus.org/x/IGU
  */
 private static String normalizeRevision(String revision) {
-if (revision.startsWith([)  revision.endsWith(])  
revision.indexOf(',') == -1 ) {
+if (revision.startsWith([)  revision.endsWith(])  
revision.indexOf(',') == -1) {
 if 
(IvyPatternHelper.getTokenString(IvyPatternHelper.REVISION_KEY).equals(revision))
 {
 // this is the case when listing dynamic revions
 return revision;

Modified: 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorParser.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorParser.java?rev=953143r1=953142r2=953143view=diff
==
--- 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorParser.java
 (original)
+++ 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorParser.java
 Wed Jun  9 20:14:47 2010
@@ -498,7 +498,7 @@ public class XmlModuleDescriptorParser e
 
 descriptor.setStatus(mergeValue(parent.getStatus(), 
descriptor.getStatus()));
 if (descriptor.getNamespace() == null  parent instanceof 
DefaultModuleDescriptor) {
-Namespace parentNamespace = ( (DefaultModuleDescriptor) 
parent).getNamespace();
+Namespace parentNamespace = ((DefaultModuleDescriptor) 
parent).getNamespace();
 descriptor.setNamespace(parentNamespace);
 }
 }

Modified: 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorUpdater.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorUpdater.java?rev=953143r1=953142r2=953143view=diff
==
--- 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorUpdater.java
 (original)
+++ 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorUpdater.java
 Wed Jun  9 20:14:47 2010
@@ -679,7 +679,7 @@ public final class XmlModuleDescriptorUp
 //TODO: should namespace be added to ModuleDescriptor 
interface, so we don't
 // have to do this kind of check?
 if (merged instanceof DefaultModuleDescriptor) {
-Namespace ns = ( (DefaultModuleDescriptor) 
merged).getNamespace();
+Namespace ns = ((DefaultModuleDescriptor) 
merged).getNamespace();
 if (ns != null) {
 namespace = ns.getName();
 }




svn commit: r953144 - in /ant/ivy/core/trunk/src/java/org/apache/ivy: core/retrieve/RetrieveEngine.java plugins/parser/m2/PomModuleDescriptorBuilder.java plugins/repository/sftp/SFTPRepository.java

2010-06-09 Thread gscokart
Author: gscokart
Date: Wed Jun  9 20:25:32 2010
New Revision: 953144

URL: http://svn.apache.org/viewvc?rev=953144view=rev
Log:
Some more spaces for checkstyle validation

Modified:
ant/ivy/core/trunk/src/java/org/apache/ivy/core/retrieve/RetrieveEngine.java

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

ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/repository/sftp/SFTPRepository.java

Modified: 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/retrieve/RetrieveEngine.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/core/retrieve/RetrieveEngine.java?rev=953144r1=953143r2=953144view=diff
==
--- 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/retrieve/RetrieveEngine.java 
(original)
+++ 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/retrieve/RetrieveEngine.java 
Wed Jun  9 20:25:32 2010
@@ -357,9 +357,9 @@ public class RetrieveEngine {
 for (int i = artifactsList.size() - 2; i = 0; i--) {
 ArtifactDownloadReport current = (ArtifactDownloadReport) 
artifactsList.get(i);
 if 
(winnerMD.equals(current.getArtifact().getModuleRevisionId())) {
-throw new RuntimeException(Multiple artifacts of the 
module  + winnerMD +
- are retrieved to the same file! Update the 
retrieve pattern  +
-to fix this error.);
+throw new RuntimeException(Multiple artifacts of the 
module  + winnerMD
++  are retrieved to the same file! Update the 
retrieve pattern 
++  to fix this error.);
 }
 }
 

Modified: 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/m2/PomModuleDescriptorBuilder.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/m2/PomModuleDescriptorBuilder.java?rev=953144r1=953143r2=953144view=diff
==
--- 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/m2/PomModuleDescriptorBuilder.java
 (original)
+++ 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/m2/PomModuleDescriptorBuilder.java
 Wed Jun  9 20:25:32 2010
@@ -193,6 +193,9 @@ public class PomModuleDescriptorBuilder 
 
 private ParserSettings parserSettings;
 
+private static final String WRONG_NUMBER_OF_PARTS_MSG = what seemed to be 
a dependency 
++ management extra info exclusion had the wrong number of parts 
(should have 2) ;
+
 
 public PomModuleDescriptorBuilder(
 ModuleDescriptorParser parser, Resource res, ParserSettings 
ivySettings) {
@@ -362,7 +365,7 @@ public class PomModuleDescriptorBuilder 
 dep.getGroupId(), dep.getArtifactId());
 ivyModuleDescriptor.addExtraInfo(scopeKey, dep.getScope());
 }
-if(!dep.getExcludedModules().isEmpty()) {
+if (!dep.getExcludedModules().isEmpty()) {
 final String exclusionPrefix = 
getDependencyMgtExtraInfoPrefixForExclusion(
 dep.getGroupId(), dep.getArtifactId());
 int index = 0;
@@ -488,9 +491,9 @@ public class PomModuleDescriptorBuilder 
 if (key.startsWith(exclusionPrefix)) {
 final String full_exclusion = (String) ent.getValue();
 final String[] exclusion_parts = 
full_exclusion.split(EXTRA_INFO_DELIMITER);
-if(exclusion_parts.length != 2) {
-Message.error(what seemed to be a dependency management 
extra info exclusion  +
-had the wrong number of parts (should have 2)  + 
exclusion_parts.length +  :  + full_exclusion);
+if (exclusion_parts.length != 2) {
+Message.error(WRONG_NUMBER_OF_PARTS_MSG + 
exclusion_parts.length +  : 
++ full_exclusion);
 continue;
 }
 exclusionIds.add(ModuleId.newInstance(exclusion_parts[0], 
exclusion_parts[1]));

Modified: 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/repository/sftp/SFTPRepository.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/repository/sftp/SFTPRepository.java?rev=953144r1=953143r2=953144view=diff
==
--- 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/repository/sftp/SFTPRepository.java
 (original)
+++ 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/repository/sftp/SFTPRepository.java
 Wed Jun  9 20:25:32 2010
@@ -206,7 +206,7 @@ public class SFTPRepository extends Abst
 Collection r = c.ls(path);
 if (r != null) {
 if 

DO NOT REPLY [Bug 48621] Allow fileset with multiple base directories

2010-06-09 Thread bugzilla
https://issues.apache.org/bugzilla/show_bug.cgi?id=48621

--- Comment #11 from Matt Benson mben...@apache.org 2010-06-09 16:27:24 EDT 
---
http://ant.apache.org/manual/Tasks/augment.html is the manual page.  The way
you could accumulate FileSets using augment would be:

- set up a path or union with an id
- iterate over your basedirs using e.g. antcontrib for
- for each basedir, augment your id'd path|union from step 1 by adding a
fileset whose dir is the currently iterated member

HTH,
Matt

-- 
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: r953149 - /ant/ivy/core/trunk/src/java/org/apache/ivy/core/retrieve/RetrieveOptions.java

2010-06-09 Thread gscokart
Author: gscokart
Date: Wed Jun  9 20:34:13 2010
New Revision: 953149

URL: http://svn.apache.org/viewvc?rev=953149view=rev
Log:
thanks to checkstyle for mentioning this as an error.

Modified:

ant/ivy/core/trunk/src/java/org/apache/ivy/core/retrieve/RetrieveOptions.java

Modified: 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/retrieve/RetrieveOptions.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/core/retrieve/RetrieveOptions.java?rev=953149r1=953148r2=953149view=diff
==
--- 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/retrieve/RetrieveOptions.java 
(original)
+++ 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/retrieve/RetrieveOptions.java 
Wed Jun  9 20:34:13 2010
@@ -27,10 +27,10 @@ import org.apache.ivy.util.filter.Filter
  * @see RetrieveEngine
  */
 public class RetrieveOptions extends LogOptions {
-public static String OVERWRITEMODE_NEVER = never;
-public static String OVERWRITEMODE_ALWAYS = always;
-public static String OVERWRITEMODE_NEWER = newer;
-public static String OVERWRITEMODE_DIFFERENT = different;
+public static final String OVERWRITEMODE_NEVER = never;
+public static final String OVERWRITEMODE_ALWAYS = always;
+public static final String OVERWRITEMODE_NEWER = newer;
+public static final String OVERWRITEMODE_DIFFERENT = different;
 
 /**
  * The names of configurations to retrieve. If the array consists only of 
'*', then all




svn commit: r953152 - /ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorUpdater.java

2010-06-09 Thread gscokart
Author: gscokart
Date: Wed Jun  9 20:38:00 2010
New Revision: 953152

URL: http://svn.apache.org/viewvc?rev=953152view=rev
Log:
Fix ConstantNameCheck checkstyle error

Modified:

ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorUpdater.java

Modified: 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorUpdater.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorUpdater.java?rev=953152r1=953151r2=953152view=diff
==
--- 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorUpdater.java
 (original)
+++ 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorUpdater.java
 Wed Jun  9 20:38:00 2010
@@ -162,21 +162,21 @@ public final class XmlModuleDescriptorUp
 private static class UpdaterHandler extends DefaultHandler implements 
LexicalHandler {
 
 /** standard attributes of ivy-module/info */
-private static final Collection stdAtts = Arrays.asList(new String[] 
{organisation, module, branch,
-revision, status, publication, namespace});
+private static final Collection STD_ATTS = Arrays.asList(new String[] 
{organisation,
+module, branch, revision, status, publication, 
namespace});
 
 /** elements that may appear inside ivy-module, in expected order */
-private static final List moduleElements = Arrays.asList(new String[] {
+private static final List MODULE_ELEMENTS = Arrays.asList(new String[] 
{
 info, configurations, publications, dependencies, 
conflicts
 });
 /** element position of configurations inside ivy-module */
-private static final int CONFIGURATIONS_POSITION = 
moduleElements.indexOf(configurations);
+private static final int CONFIGURATIONS_POSITION = 
MODULE_ELEMENTS.indexOf(configurations);
 /** element position of dependencies inside ivy-module */
-private static final int DEPENDENCIES_POSITION = 
moduleElements.indexOf(dependencies);
+private static final int DEPENDENCIES_POSITION = 
MODULE_ELEMENTS.indexOf(dependencies);
 
 /** elements that may appear inside of ivy-module/info */
-private static final Collection infoElements = Arrays.asList(new 
String[]{
-extends, ivyauthor, license, repository, description 
});
+private static final Collection INFO_ELEMENTS = Arrays.asList(new 
String[] {extends,
+ivyauthor, license, repository, description});
 
 private final ParserSettings settings;
 
@@ -354,7 +354,7 @@ public final class XmlModuleDescriptorUp
 //if the descriptor already contains a description, 
don't bother printing
 //the merged version.
 hasDescription = true;
-} else if (!infoElements.contains(qName)) {
+} else if (!INFO_ELEMENTS.contains(qName)) {
 //according to the XSD, we should write description 
after all of the other
 //standard info elements but before any extended 
elements.
 writeInheritedDescription(merged);
@@ -699,7 +699,7 @@ public final class XmlModuleDescriptorUp
 extraAttributes = new LinkedHashMap(attributes.getLength());
 for (int i = 0; i  attributes.getLength(); i++) {
 String qname = attributes.getQName(i);
-if (!stdAtts.contains(qname)) {
+if (!STD_ATTS.contains(qname)) {
 extraAttributes.put(qname, substitute(settings, 
attributes.getValue(i)));
 }
 }
@@ -1047,8 +1047,8 @@ public final class XmlModuleDescriptorUp
  !(mergedConfigurations  mergedDependencies)) {
 
 //calculate the position of the element in ivy-module
-int position = moduleElement == null ? moduleElements.size()
-: moduleElements.indexOf(moduleElement);
+int position = moduleElement == null ? MODULE_ELEMENTS.size()
+: MODULE_ELEMENTS.indexOf(moduleElement);
 
 ModuleDescriptor merged = options.getMergedDescriptor();
 




svn commit: r953157 - /ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/m2/PomModuleDescriptorBuilder.java

2010-06-09 Thread gscokart
Author: gscokart
Date: Wed Jun  9 20:55:19 2010
New Revision: 953157

URL: http://svn.apache.org/viewvc?rev=953157view=rev
Log:
full_exclusion and exclusion_parts are reported as checkstyle error, and I 
don't see the purpose of all final used for local variable

Modified:

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

Modified: 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/m2/PomModuleDescriptorBuilder.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/m2/PomModuleDescriptorBuilder.java?rev=953157r1=953156r2=953157view=diff
==
--- 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/m2/PomModuleDescriptorBuilder.java
 (original)
+++ 
ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/parser/m2/PomModuleDescriptorBuilder.java
 Wed Jun  9 20:55:19 2010
@@ -478,25 +478,25 @@ public class PomModuleDescriptorBuilder 
 }
 
 private static List /*ModuleId*/ getDependencyMgtExclusions(
-final ModuleDescriptor descriptor,
-final String groupId,
-final String artifactId) {
-final String exclusionPrefix = 
getDependencyMgtExtraInfoPrefixForExclusion(
+ModuleDescriptor descriptor,
+String groupId,
+String artifactId) {
+String exclusionPrefix = getDependencyMgtExtraInfoPrefixForExclusion(
 groupId, artifactId);
-final List /*ModuleId*/ exclusionIds = new LinkedList /*ModuleId*/ 
();
-final Map /*String,String*/ extras = descriptor.getExtraInfo();
+List /*ModuleId*/ exclusionIds = new LinkedList /*ModuleId*/ ();
+Map /*String,String*/ extras = descriptor.getExtraInfo();
 for (final Iterator entIter = extras.entrySet().iterator(); 
entIter.hasNext();) {
-final Map.Entry /*String,String*/ ent = (Map.Entry) 
entIter.next();
-final String key = (String) ent.getKey();
+Map.Entry /*String,String*/ ent = (Map.Entry) entIter.next();
+String key = (String) ent.getKey();
 if (key.startsWith(exclusionPrefix)) {
-final String full_exclusion = (String) ent.getValue();
-final String[] exclusion_parts = 
full_exclusion.split(EXTRA_INFO_DELIMITER);
-if (exclusion_parts.length != 2) {
-Message.error(WRONG_NUMBER_OF_PARTS_MSG + 
exclusion_parts.length +  : 
-+ full_exclusion);
+String fullExclusion = (String) ent.getValue();
+String[] exclusionParts = 
fullExclusion.split(EXTRA_INFO_DELIMITER);
+if (exclusionParts.length != 2) {
+Message.error(WRONG_NUMBER_OF_PARTS_MSG + 
exclusionParts.length +  : 
++ fullExclusion);
 continue;
 }
-exclusionIds.add(ModuleId.newInstance(exclusion_parts[0], 
exclusion_parts[1]));
+exclusionIds.add(ModuleId.newInstance(exclusionParts[0], 
exclusionParts[1]));
 }
 }
 




svn commit: r953158 - /ant/ivy/core/trunk/src/java/org/apache/ivy/core/cache/DefaultRepositoryCacheManager.java

2010-06-09 Thread gscokart
Author: gscokart
Date: Wed Jun  9 20:57:32 2010
New Revision: 953158

URL: http://svn.apache.org/viewvc?rev=953158view=rev
Log:
Fix FinalClassCheck checkstyle validation

Modified:

ant/ivy/core/trunk/src/java/org/apache/ivy/core/cache/DefaultRepositoryCacheManager.java

Modified: 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/cache/DefaultRepositoryCacheManager.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/core/cache/DefaultRepositoryCacheManager.java?rev=953158r1=953157r2=953158view=diff
==
--- 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/cache/DefaultRepositoryCacheManager.java
 (original)
+++ 
ant/ivy/core/trunk/src/java/org/apache/ivy/core/cache/DefaultRepositoryCacheManager.java
 Wed Jun  9 20:57:32 2010
@@ -1168,7 +1168,7 @@ public class DefaultRepositoryCacheManag
 Message.debug(\t\tchangingMatcher:  + getChangingMatcherName());
 }
 
-private class BackupResourceDownloader implements ResourceDownloader {
+private final class BackupResourceDownloader implements ResourceDownloader 
{
 
 private ResourceDownloader delegate;
 private File backup;




svn commit: r953162 - in /ant/ivy/core/trunk: ./ doc/use/ src/java/org/apache/ivy/ant/ src/java/org/apache/ivy/core/deliver/ src/java/org/apache/ivy/core/resolve/ test/java/org/apache/ivy/core/resolve

2010-06-09 Thread maartenc
Author: maartenc
Date: Wed Jun  9 21:14:51 2010
New Revision: 953162

URL: http://svn.apache.org/viewvc?rev=953162view=rev
Log:
FIX: Resolved Ivy properties written to cache during ivy:resolve incorrectly 
represents forced revisions (IVY-1159)

Added:
ant/ivy/core/trunk/test/repositories/IVY-1159/

ant/ivy/core/trunk/test/repositories/IVY-1159/ivy-depsorder_modA_then_modB.xml  
 (with props)

ant/ivy/core/trunk/test/repositories/IVY-1159/ivy-depsorder_modB_then_modA.xml  
 (with props)
ant/ivy/core/trunk/test/repositories/IVY-1159/ivysettings.xml   (with props)
ant/ivy/core/trunk/test/repositories/IVY-1159/myorg/
ant/ivy/core/trunk/test/repositories/IVY-1159/myorg/modA/
ant/ivy/core/trunk/test/repositories/IVY-1159/myorg/modA/1/
ant/ivy/core/trunk/test/repositories/IVY-1159/myorg/modA/1/ivy.xml   (with 
props)
ant/ivy/core/trunk/test/repositories/IVY-1159/myorg/modA/1/modA.jar   (with 
props)
ant/ivy/core/trunk/test/repositories/IVY-1159/myorg/modB/
ant/ivy/core/trunk/test/repositories/IVY-1159/myorg/modB/1/
ant/ivy/core/trunk/test/repositories/IVY-1159/myorg/modB/1/ivy.xml   (with 
props)
ant/ivy/core/trunk/test/repositories/IVY-1159/myorg/modB/1/modB.jar   (with 
props)
Modified:
ant/ivy/core/trunk/CHANGES.txt
ant/ivy/core/trunk/doc/use/deliver.html
ant/ivy/core/trunk/src/java/org/apache/ivy/ant/IvyDeliver.java
ant/ivy/core/trunk/src/java/org/apache/ivy/core/deliver/DeliverEngine.java
ant/ivy/core/trunk/src/java/org/apache/ivy/core/deliver/DeliverOptions.java
ant/ivy/core/trunk/src/java/org/apache/ivy/core/resolve/ResolveEngine.java
ant/ivy/core/trunk/test/java/org/apache/ivy/core/resolve/ResolveTest.java

Modified: ant/ivy/core/trunk/CHANGES.txt
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/CHANGES.txt?rev=953162r1=953161r2=953162view=diff
==
--- ant/ivy/core/trunk/CHANGES.txt (original)
+++ ant/ivy/core/trunk/CHANGES.txt Wed Jun  9 21:14:51 2010
@@ -126,6 +126,7 @@ for detailed view of each issue, please 
 - IMPROVEMENT: Trace a message when a property file referenced from the 
settings doesn't exixts (IVY-1074)
 - IMPROVEMENT: use defaultconf in combination with defaultconfmapping 
(IVY-1135) (thanks to Jon Schneider)
 
+- FIX: Resolved Ivy properties written to cache during ivy:resolve incorrectly 
represents forced revisions (IVY-1159)
 - FIX: Namespace rules not properly applied to parent projects (IVY-1186)
 - FIX: LatestVersionMatcher.needModuleDescriptor() does not honor custom 
statuses (IVY-1170) (thanks to Carl Quinn)
 - FIX: Proxy authentication could fail when using commons-httpclient 

Modified: ant/ivy/core/trunk/doc/use/deliver.html
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/doc/use/deliver.html?rev=953162r1=953161r2=953162view=diff
==
--- ant/ivy/core/trunk/doc/use/deliver.html (original)
+++ ant/ivy/core/trunk/doc/use/deliver.html Wed Jun  9 21:14:51 2010
@@ -97,8 +97,10 @@ It can also be useful if you want to tri
 tdNo. No recursive delivery is done by default/td/tr
 trtdvalidate/tdtdtrue to force ivy files validation against 
ivy.xsd, false to force no validation/td
 tdNo. Defaults to default ivy value (as configured in configuration 
file)/td/tr
-trtdreplacedynamicrev/tdtdtrue to replace dynmic revisions by 
static ones in the delivered file, false to avoid this replacement span 
class=since(since 1.3)/span/td
+trtdreplacedynamicrev/tdtdtrue to replace dynamic revisions by 
static ones in the delivered file, false to avoid this replacement span 
class=since(since 1.3)/span/td
 tdNo. Defaults to true/td/tr
+trtdreplaceForcedRev/tdtdtrue to replace revisions (static or 
dynamic) by the revision of the resolver in a 
href=../settings/resolvers.html#commonforced mode/a, false to avoid this 
replacement span class=since(since 2.2)/span/td
+tdNo. Defaults to false/td/tr
 trtdmerge/tdtdif a descriptor a 
href=../ivyfile/extends.htmlextends/a a parent, merge the inherited 
information directly into the delivered descriptor.  The iextends/i element 
itself will be commented out in the delivered descriptor. span 
class=since(since 2.2)/span/td
 tdNo. Defaults to true./td/tr
trtdsettingsRef/tdtdA reference to the ivy settings that must 
be used by this task span class=since(since 2.0)/span/td

Modified: ant/ivy/core/trunk/src/java/org/apache/ivy/ant/IvyDeliver.java
URL: 
http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/ant/IvyDeliver.java?rev=953162r1=953161r2=953162view=diff
==
--- ant/ivy/core/trunk/src/java/org/apache/ivy/ant/IvyDeliver.java (original)
+++ ant/ivy/core/trunk/src/java/org/apache/ivy/ant/IvyDeliver.java Wed Jun  9 
21:14:51 2010
@@ -198,6 +198,8 @@ public class 

[jira] Resolved: (IVY-1159) Resolved Ivy Properties written to cache during ivy:resolve incorrectly represents transitive evictions

2010-06-09 Thread Maarten Coene (JIRA)

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

Maarten Coene resolved IVY-1159.


Resolution: Fixed

 Resolved Ivy Properties written to cache during ivy:resolve incorrectly 
 represents transitive evictions 
 

 Key: IVY-1159
 URL: https://issues.apache.org/jira/browse/IVY-1159
 Project: Ivy
  Issue Type: Bug
  Components: Core
Affects Versions: trunk
Reporter: Ed Burcher
 Fix For: 2.2.0-RC1

 Attachments: IVY1159.tar.gz


 In ResolveEngine.resolve the code that writes the properties file appears to 
 be incorrect. 
 When the dependencies collection includes two or more entries for the same 
 dependency (one from the root ivy file and the others being transitives), the 
 properties file will always only ever be populated with the information from 
 the IvyNode that belongs to the root ivy file (effectively the comment states 
 this, so it certainly appears intentional).
 This produces the following bugs / undesirable effects:
  * incorrect delivered descriptor in some situations (where a dependency is 
 both directly and transitively imported)
  * order of declaration of dependencies alters behaviour
 These are pretty major problems because (as demonstrated below) a 
 delivered/published ivy descriptor can identify completely bogus revisions 
 for the dynamic-static replacements, which are not to the actual revisions 
 used when compiling etc 
 Set up
 module *one* has no dependencies and has been published (as rev = 1, say)
 module *two* has a dependency on module one (only) and has been published (as 
 rev = 1, also)
 module *three* has dependencies on both modules one and two and *lists them 
 in the order two,one*
 In the module three descriptor the revisions mentioned for two and one do not 
 actually exist (two=0  one=0 say - repository only contains rev=1 of both)
 Ivy settings (attached) has a resolver that refers to a local repo, and has 
 force=true and local=true set. 
 Problem Case - use case: publishing module 3
 1) ivy:resolve on module three, using refresh=true, transitive=true. 
 Otherwise nothing special here.
 then
 2) ivy:deliver (status=reelase, pubdate=now, deliverpattern supplied, 
 pubrevision supplied (rev=1))
 3) (lastly, the ivy:publish step woud happen here, but is not relevant to the 
 problem)
 Expected outcome:
 Because the primary resolver has force=true, rev 1 of both module 
 dependencies of 'three' should be selected [Because rev=1 publications are 
 the only ones present in the repository] when resolving three's declared deps 
 (both of which declare a dep on rev=0). 
 Actual outcome: 
 Delivered descriptor correctly names two as being resolved to rev=1. 
 Incorrectly names module one as being resolved to rev=0 (which doesn't exist 
 - and never has!)
 Workaround:
 Reverse the order of the declared dependencies in three's ivy descriptor (i.e 
 new order is one, two) - problem does not occur.
 Diagnosis:
 Logs for resolve appear to show everything is fine (the eviction is noted, 
 the generated report xml shows the declared direct dependency (one, rev=0) 
 being evicted by the transitive dependency (one, rev=1 as declared in two's 
 published ivy descriptor)
 However, debugging DeliverEngine.java and ResolveEngine.java - it is apparent 
 that the 'resolved ivy properties file' is used to drive the replacement of 
 dynamic revisions with static ones during deliver. In the error case, the 
 properties file shows this:
 +revision\:\...@\#\:+0\:\...@\#\:+module\:\...@\#\:+one\:  snip :=0 ?
 +revision\:\...@\#\:+0\:\...@\#\:+module\:\...@\#\:+two\:   snip :=1 release
 The '?' is put there because the IvyNode that represented the direct 
 dependency has no descriptor (correctly, because it has been evicted). 
 Because the real selected revision is not put into the properties file, the 
 ivy:deliver task is doomed to produce wrong results.
 The correct behaviour in this case would be for the EvictionInfo stored 
 against the evicted IvyNode to be inspected to find the appropriate revision 
 information. I have attached a pretty ugly example of how this could be 
 achieved.
 Just before the comment (The evicted modules have no description, so we 
 can't put their status)
 {code}
 if (depDescriptor == null) {
   EvictionData ed = null;
   for (int j=0; jconfs.length  ed == null; 
 j++) {
 ed = dependencies[i].getEvictedData(confs[j]);
   }
   if (ed != null) {
 Collection selected = ed.getSelected();
 if (selected != null) {
   

[jira] Commented: (IVY-1159) Resolved Ivy Properties written to cache during ivy:resolve incorrectly represents transitive evictions

2010-06-09 Thread Maarten Coene (JIRA)

[ 
https://issues.apache.org/jira/browse/IVY-1159?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=12877218#action_12877218
 ] 

Maarten Coene commented on IVY-1159:


I think such a change would be too big to make it into the next release.

So I've fixed it like this:
- the replaceDynamicRev=true setting will replace dynamic revisions (not 
static ones) with the resolved revision
- a new replaceForcedRev=true setting will update static/dynamic revisions 
with the forced revision (defaults to 'false' for backward compatibility)

the replacement of static evicted revisions as I suggested earlier isn't 
possible because this depends on the configurations being resolved.

So in your case, you should call ivy:deliver like this:
{code}
ivy:deliver replaceDynamicRev=true replaceForcedRev=true ... /
{code}

Hope this solves your problem.
Maarten

 Resolved Ivy Properties written to cache during ivy:resolve incorrectly 
 represents transitive evictions 
 

 Key: IVY-1159
 URL: https://issues.apache.org/jira/browse/IVY-1159
 Project: Ivy
  Issue Type: Bug
  Components: Core
Affects Versions: trunk
Reporter: Ed Burcher
 Fix For: 2.2.0-RC1

 Attachments: IVY1159.tar.gz


 In ResolveEngine.resolve the code that writes the properties file appears to 
 be incorrect. 
 When the dependencies collection includes two or more entries for the same 
 dependency (one from the root ivy file and the others being transitives), the 
 properties file will always only ever be populated with the information from 
 the IvyNode that belongs to the root ivy file (effectively the comment states 
 this, so it certainly appears intentional).
 This produces the following bugs / undesirable effects:
  * incorrect delivered descriptor in some situations (where a dependency is 
 both directly and transitively imported)
  * order of declaration of dependencies alters behaviour
 These are pretty major problems because (as demonstrated below) a 
 delivered/published ivy descriptor can identify completely bogus revisions 
 for the dynamic-static replacements, which are not to the actual revisions 
 used when compiling etc 
 Set up
 module *one* has no dependencies and has been published (as rev = 1, say)
 module *two* has a dependency on module one (only) and has been published (as 
 rev = 1, also)
 module *three* has dependencies on both modules one and two and *lists them 
 in the order two,one*
 In the module three descriptor the revisions mentioned for two and one do not 
 actually exist (two=0  one=0 say - repository only contains rev=1 of both)
 Ivy settings (attached) has a resolver that refers to a local repo, and has 
 force=true and local=true set. 
 Problem Case - use case: publishing module 3
 1) ivy:resolve on module three, using refresh=true, transitive=true. 
 Otherwise nothing special here.
 then
 2) ivy:deliver (status=reelase, pubdate=now, deliverpattern supplied, 
 pubrevision supplied (rev=1))
 3) (lastly, the ivy:publish step woud happen here, but is not relevant to the 
 problem)
 Expected outcome:
 Because the primary resolver has force=true, rev 1 of both module 
 dependencies of 'three' should be selected [Because rev=1 publications are 
 the only ones present in the repository] when resolving three's declared deps 
 (both of which declare a dep on rev=0). 
 Actual outcome: 
 Delivered descriptor correctly names two as being resolved to rev=1. 
 Incorrectly names module one as being resolved to rev=0 (which doesn't exist 
 - and never has!)
 Workaround:
 Reverse the order of the declared dependencies in three's ivy descriptor (i.e 
 new order is one, two) - problem does not occur.
 Diagnosis:
 Logs for resolve appear to show everything is fine (the eviction is noted, 
 the generated report xml shows the declared direct dependency (one, rev=0) 
 being evicted by the transitive dependency (one, rev=1 as declared in two's 
 published ivy descriptor)
 However, debugging DeliverEngine.java and ResolveEngine.java - it is apparent 
 that the 'resolved ivy properties file' is used to drive the replacement of 
 dynamic revisions with static ones during deliver. In the error case, the 
 properties file shows this:
 +revision\:\...@\#\:+0\:\...@\#\:+module\:\...@\#\:+one\:  snip :=0 ?
 +revision\:\...@\#\:+0\:\...@\#\:+module\:\...@\#\:+two\:   snip :=1 release
 The '?' is put there because the IvyNode that represented the direct 
 dependency has no descriptor (correctly, because it has been evicted). 
 Because the real selected revision is not put into the properties file, the 
 ivy:deliver task is doomed to produce wrong results.
 The correct behaviour in this case would be for the EvictionInfo stored 
 against the evicted IvyNode to be inspected to find the 

[jira] Assigned: (IVY-1159) Resolved Ivy Properties written to cache during ivy:resolve incorrectly represents transitive evictions

2010-06-09 Thread Maarten Coene (JIRA)

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

Maarten Coene reassigned IVY-1159:
--

Assignee: Maarten Coene

 Resolved Ivy Properties written to cache during ivy:resolve incorrectly 
 represents transitive evictions 
 

 Key: IVY-1159
 URL: https://issues.apache.org/jira/browse/IVY-1159
 Project: Ivy
  Issue Type: Bug
  Components: Core
Affects Versions: trunk
Reporter: Ed Burcher
Assignee: Maarten Coene
 Fix For: 2.2.0-RC1

 Attachments: IVY1159.tar.gz


 In ResolveEngine.resolve the code that writes the properties file appears to 
 be incorrect. 
 When the dependencies collection includes two or more entries for the same 
 dependency (one from the root ivy file and the others being transitives), the 
 properties file will always only ever be populated with the information from 
 the IvyNode that belongs to the root ivy file (effectively the comment states 
 this, so it certainly appears intentional).
 This produces the following bugs / undesirable effects:
  * incorrect delivered descriptor in some situations (where a dependency is 
 both directly and transitively imported)
  * order of declaration of dependencies alters behaviour
 These are pretty major problems because (as demonstrated below) a 
 delivered/published ivy descriptor can identify completely bogus revisions 
 for the dynamic-static replacements, which are not to the actual revisions 
 used when compiling etc 
 Set up
 module *one* has no dependencies and has been published (as rev = 1, say)
 module *two* has a dependency on module one (only) and has been published (as 
 rev = 1, also)
 module *three* has dependencies on both modules one and two and *lists them 
 in the order two,one*
 In the module three descriptor the revisions mentioned for two and one do not 
 actually exist (two=0  one=0 say - repository only contains rev=1 of both)
 Ivy settings (attached) has a resolver that refers to a local repo, and has 
 force=true and local=true set. 
 Problem Case - use case: publishing module 3
 1) ivy:resolve on module three, using refresh=true, transitive=true. 
 Otherwise nothing special here.
 then
 2) ivy:deliver (status=reelase, pubdate=now, deliverpattern supplied, 
 pubrevision supplied (rev=1))
 3) (lastly, the ivy:publish step woud happen here, but is not relevant to the 
 problem)
 Expected outcome:
 Because the primary resolver has force=true, rev 1 of both module 
 dependencies of 'three' should be selected [Because rev=1 publications are 
 the only ones present in the repository] when resolving three's declared deps 
 (both of which declare a dep on rev=0). 
 Actual outcome: 
 Delivered descriptor correctly names two as being resolved to rev=1. 
 Incorrectly names module one as being resolved to rev=0 (which doesn't exist 
 - and never has!)
 Workaround:
 Reverse the order of the declared dependencies in three's ivy descriptor (i.e 
 new order is one, two) - problem does not occur.
 Diagnosis:
 Logs for resolve appear to show everything is fine (the eviction is noted, 
 the generated report xml shows the declared direct dependency (one, rev=0) 
 being evicted by the transitive dependency (one, rev=1 as declared in two's 
 published ivy descriptor)
 However, debugging DeliverEngine.java and ResolveEngine.java - it is apparent 
 that the 'resolved ivy properties file' is used to drive the replacement of 
 dynamic revisions with static ones during deliver. In the error case, the 
 properties file shows this:
 +revision\:\...@\#\:+0\:\...@\#\:+module\:\...@\#\:+one\:  snip :=0 ?
 +revision\:\...@\#\:+0\:\...@\#\:+module\:\...@\#\:+two\:   snip :=1 release
 The '?' is put there because the IvyNode that represented the direct 
 dependency has no descriptor (correctly, because it has been evicted). 
 Because the real selected revision is not put into the properties file, the 
 ivy:deliver task is doomed to produce wrong results.
 The correct behaviour in this case would be for the EvictionInfo stored 
 against the evicted IvyNode to be inspected to find the appropriate revision 
 information. I have attached a pretty ugly example of how this could be 
 achieved.
 Just before the comment (The evicted modules have no description, so we 
 can't put their status)
 {code}
 if (depDescriptor == null) {
   EvictionData ed = null;
   for (int j=0; jconfs.length  ed == null; 
 j++) {
 ed = dependencies[i].getEvictedData(confs[j]);
   }
   if (ed != null) {
 Collection selected = ed.getSelected();
  

DO NOT REPLY [Bug 49418] New: Add support for non-ASCII encoding to junitreport task

2010-06-09 Thread bugzilla
https://issues.apache.org/bugzilla/show_bug.cgi?id=49418

   Summary: Add support for non-ASCII encoding to junitreport
task
   Product: Ant
   Version: unspecified
  Platform: PC
OS/Version: Linux
Status: NEW
  Keywords: PatchAvailable, XSLTBug
  Severity: normal
  Priority: P2
 Component: Optional Tasks
AssignedTo: notifications@ant.apache.org
ReportedBy: matsuba...@gmail.com


The current implementation of junitreport has no support for JUnit testcases
with  non-ASCII strings in their assertion targets or system outputs.  When
non-ASCII strings are used, the rendered summary will have inappropriate
encoding specification and can be unreadable.

This (possible) bug is caused by the fact that the current implementation of
junitreport always specifies the encoding of the generated summary as
US-ASCII.  This is hard-coded in the stylesheets, src/etc/junit-frames.xsl
and src/etc/junit-noframes.xsl.

Attached patch adds an optional attribute named 'encoding' to junitreport
task.  The default value for this attribute is set to US-ASCII so that we can
keep the current behaiviour if we don't use this option.  This patch is for Ant
rev. 952676 (https://svn.apache.org/repos/asf/ant/core/tr...@952676)

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


DO NOT REPLY [Bug 49418] Add support for non-ASCII encoding to junitreport task

2010-06-09 Thread bugzilla
https://issues.apache.org/bugzilla/show_bug.cgi?id=49418

--- Comment #1 from Yusuke Matsubara matsuba...@gmail.com 2010-06-09 20:57:11 
EDT ---
Created an attachment (id=25571)
 -- (https://issues.apache.org/bugzilla/attachment.cgi?id=25571)
a sample build.xml and a JUnit testcase to reproduce the problem of non-ASCII
strings in a junitreport task

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


DO NOT REPLY [Bug 49418] Add support for non-ASCII encoding to junitreport task

2010-06-09 Thread bugzilla
https://issues.apache.org/bugzilla/show_bug.cgi?id=49418

--- Comment #2 from Yusuke Matsubara matsuba...@gmail.com 2010-06-09 20:59:46 
EDT ---
Created an attachment (id=25572)
 -- (https://issues.apache.org/bugzilla/attachment.cgi?id=25572)
proposed patch to add an option to specify encoding in a junitreport task

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