svn commit: r741464 - in /commons/sandbox/monitoring/branches/modules: core/pom.xml instrumentation/pom.xml reporting/pom.xml spring/pom.xml

2009-02-05 Thread nicolas
Author: nicolas
Date: Fri Feb  6 07:50:53 2009
New Revision: 741464

URL: http://svn.apache.org/viewvc?rev=741464&view=rev
Log:
rename "core" module to commons-monitoring-core to avoid conflict with earlier 
snapshots

Modified:
commons/sandbox/monitoring/branches/modules/core/pom.xml
commons/sandbox/monitoring/branches/modules/instrumentation/pom.xml
commons/sandbox/monitoring/branches/modules/reporting/pom.xml
commons/sandbox/monitoring/branches/modules/spring/pom.xml

Modified: commons/sandbox/monitoring/branches/modules/core/pom.xml
URL: 
http://svn.apache.org/viewvc/commons/sandbox/monitoring/branches/modules/core/pom.xml?rev=741464&r1=741463&r2=741464&view=diff
==
--- commons/sandbox/monitoring/branches/modules/core/pom.xml (original)
+++ commons/sandbox/monitoring/branches/modules/core/pom.xml Fri Feb  6 
07:50:53 2009
@@ -24,7 +24,7 @@
 commons-monitoring-parent
 1.0-SNAPSHOT
   
-  commons-monitoring
+  commons-monitoring-core
   jar
   Commons Monitoring (Sandbox) core package
   

Modified: commons/sandbox/monitoring/branches/modules/instrumentation/pom.xml
URL: 
http://svn.apache.org/viewvc/commons/sandbox/monitoring/branches/modules/instrumentation/pom.xml?rev=741464&r1=741463&r2=741464&view=diff
==
--- commons/sandbox/monitoring/branches/modules/instrumentation/pom.xml 
(original)
+++ commons/sandbox/monitoring/branches/modules/instrumentation/pom.xml Fri Feb 
 6 07:50:53 2009
@@ -9,29 +9,29 @@
   commons-monitoring-instrumentation
   1.0-SNAPSHOT
   
-   
-   org.apache.commons.monitoring
-   commons-monitoring
-   1.0-SNAPSHOT
-   
-   
-   org.apache.commons
-   commons-proxy
-   1.0
-   true
-   
-   
-   aopalliance
-   aopalliance
-   1.0
-   true
-   
-   
-   javax.servlet
-   servlet-api
-   2.3
-   provided
-   true
-   
+
+org.apache.commons.monitoring
+commons-monitoring-core
+${project.version}
+
+
+  org.apache.commons
+  commons-proxy
+  1.0
+  true
+
+
+  aopalliance
+  aopalliance
+  1.0
+  true
+
+
+  javax.servlet
+  servlet-api
+  2.3
+  provided
+  true
+
   
 
\ No newline at end of file

Modified: commons/sandbox/monitoring/branches/modules/reporting/pom.xml
URL: 
http://svn.apache.org/viewvc/commons/sandbox/monitoring/branches/modules/reporting/pom.xml?rev=741464&r1=741463&r2=741464&view=diff
==
--- commons/sandbox/monitoring/branches/modules/reporting/pom.xml (original)
+++ commons/sandbox/monitoring/branches/modules/reporting/pom.xml Fri Feb  6 
07:50:53 2009
@@ -7,16 +7,16 @@
   4.0.0
   commons-monitoring-reporting
   
-   
-   org.apache.commons.monitoring
-   commons-monitoring
-   ${project.version}
-   
-   
-   junit
-   junit
-   4.5
-   test
-   
+
+  org.apache.commons.monitoring
+  commons-monitoring-core
+  ${project.version}
+
+
+  junit
+  junit
+  4.5
+  test
+
   
 
\ No newline at end of file

Modified: commons/sandbox/monitoring/branches/modules/spring/pom.xml
URL: 
http://svn.apache.org/viewvc/commons/sandbox/monitoring/branches/modules/spring/pom.xml?rev=741464&r1=741463&r2=741464&view=diff
==
--- commons/sandbox/monitoring/branches/modules/spring/pom.xml (original)
+++ commons/sandbox/monitoring/branches/modules/spring/pom.xml Fri Feb  6 
07:50:53 2009
@@ -7,40 +7,44 @@
   4.0.0
   org.apache.commons.monitoring
   commons-monitoring-spring
-  1.0-SNAPSHOT
   
-   
-   org.springframework
-   spring-context
-   2.5.5
-   
-   
-   org.springframework
-   spring-beans
-   2.5.5
-   
-   
-   org.apache.commons.monitoring
-   commons-monitoring-instrumentation
-   1.0-SNAPSHOT
-   
-   
-   org.springframework
-   spring-aop
-   2.5.5
-   
-   
-   org.springframework
-   spring-web
-   2.5.5
-   true
-   
-   
-   javax.servlet
-   servlet-api
-   2.3
-   provided
-   true
-   
+
+  org.springframework
+  spring-context
+  2.5.5
+
+
+  org.springframework
+  spring-beans
+  2.5.5
+
+
+  org.apache.commons.monitoring
+ 

svn commit: r741462 - /commons/proper/cli/tags/cli-1.2-RC1/

2009-02-05 Thread bayard
Author: bayard
Date: Fri Feb  6 07:41:12 2009
New Revision: 741462

URL: http://svn.apache.org/viewvc?rev=741462&view=rev
Log:
Tagging rc1 of the release

Added:
commons/proper/cli/tags/cli-1.2-RC1/
  - copied from r741461, commons/proper/cli/branches/cli-1.x/



svn commit: r741461 - /commons/proper/cli/branches/cli-1.x/pom.xml

2009-02-05 Thread bayard
Author: bayard
Date: Fri Feb  6 07:40:43 2009
New Revision: 741461

URL: http://svn.apache.org/viewvc?rev=741461&view=rev
Log:
First attempt at release. Using 'deploy' rather than release plugin because 
site is separate

Modified:
commons/proper/cli/branches/cli-1.x/pom.xml

Modified: commons/proper/cli/branches/cli-1.x/pom.xml
URL: 
http://svn.apache.org/viewvc/commons/proper/cli/branches/cli-1.x/pom.xml?rev=741461&r1=741460&r2=741461&view=diff
==
--- commons/proper/cli/branches/cli-1.x/pom.xml (original)
+++ commons/proper/cli/branches/cli-1.x/pom.xml Fri Feb  6 07:40:43 2009
@@ -24,7 +24,7 @@
   4.0.0
   commons-cli
   commons-cli
-  1.2-SNAPSHOT
+  1.2
   Commons CLI
 
   2002




svn commit: r741458 - /commons/proper/cli/branches/cli-1.x/src/test/org/apache/commons/cli/ApplicationTest.java

2009-02-05 Thread bayard
Author: bayard
Date: Fri Feb  6 07:32:48 2009
New Revision: 741458

URL: http://svn.apache.org/viewvc?rev=741458&view=rev
Log:
Removing @author from method and making it just 'author' as javadoc does not 
like the @author there

Modified:

commons/proper/cli/branches/cli-1.x/src/test/org/apache/commons/cli/ApplicationTest.java

Modified: 
commons/proper/cli/branches/cli-1.x/src/test/org/apache/commons/cli/ApplicationTest.java
URL: 
http://svn.apache.org/viewvc/commons/proper/cli/branches/cli-1.x/src/test/org/apache/commons/cli/ApplicationTest.java?rev=741458&r1=741457&r2=741458&view=diff
==
--- 
commons/proper/cli/branches/cli-1.x/src/test/org/apache/commons/cli/ApplicationTest.java
 (original)
+++ 
commons/proper/cli/branches/cli-1.x/src/test/org/apache/commons/cli/ApplicationTest.java
 Fri Feb  6 07:32:48 2009
@@ -171,7 +171,7 @@
 }
 
 /**
- * @author Slawek Zachcial
+ * author Slawek Zachcial
  */
 public void testMan()
 {




svn commit: r741447 - /commons/proper/cli/branches/cli-1.x/pom.xml

2009-02-05 Thread bayard
Author: bayard
Date: Fri Feb  6 07:18:30 2009
New Revision: 741447

URL: http://svn.apache.org/viewvc?rev=741447&view=rev
Log:
Making it look like the output of the release plugin

Modified:
commons/proper/cli/branches/cli-1.x/pom.xml

Modified: commons/proper/cli/branches/cli-1.x/pom.xml
URL: 
http://svn.apache.org/viewvc/commons/proper/cli/branches/cli-1.x/pom.xml?rev=741447&r1=741446&r2=741447&view=diff
==
--- commons/proper/cli/branches/cli-1.x/pom.xml (original)
+++ commons/proper/cli/branches/cli-1.x/pom.xml Fri Feb  6 07:18:30 2009
@@ -134,7 +134,7 @@
 1.2
 
commons-cli-${commons.release.version}
 
org.apache.commons.cli
-
+
 CLI
 12310463
 




svn commit: r741446 - /commons/proper/cli/branches/cli-1.x/pom.xml

2009-02-05 Thread bayard
Author: bayard
Date: Fri Feb  6 07:18:03 2009
New Revision: 741446

URL: http://svn.apache.org/viewvc?rev=741446&view=rev
Log:
Folding empty xml tag in

Modified:
commons/proper/cli/branches/cli-1.x/pom.xml

Modified: commons/proper/cli/branches/cli-1.x/pom.xml
URL: 
http://svn.apache.org/viewvc/commons/proper/cli/branches/cli-1.x/pom.xml?rev=741446&r1=741445&r2=741446&view=diff
==
--- commons/proper/cli/branches/cli-1.x/pom.xml (original)
+++ commons/proper/cli/branches/cli-1.x/pom.xml Fri Feb  6 07:18:03 2009
@@ -134,7 +134,7 @@
 1.2
 
commons-cli-${commons.release.version}
 
org.apache.commons.cli
-
+
 CLI
 12310463
 




svn commit: r741437 - /commons/proper/cli/trunk/xdocs/changes.xml

2009-02-05 Thread bayard
Author: bayard
Date: Fri Feb  6 06:54:18 2009
New Revision: 741437

URL: http://svn.apache.org/viewvc?rev=741437&view=rev
Log:
Updating with latest changes

Modified:
commons/proper/cli/trunk/xdocs/changes.xml

Modified: commons/proper/cli/trunk/xdocs/changes.xml
URL: 
http://svn.apache.org/viewvc/commons/proper/cli/trunk/xdocs/changes.xml?rev=741437&r1=741436&r2=741437&view=diff
==
--- commons/proper/cli/trunk/xdocs/changes.xml (original)
+++ commons/proper/cli/trunk/xdocs/changes.xml Fri Feb  6 06:54:18 2009
@@ -23,6 +23,9 @@
   
 
 
+  
+Ant build system removed. 
+  
   
 Incomplete usage documentation about Java property option.
   




svn commit: r741436 - /commons/proper/cli/trunk/xdocs/changes.xml

2009-02-05 Thread bayard
Author: bayard
Date: Fri Feb  6 06:53:40 2009
New Revision: 741436

URL: http://svn.apache.org/viewvc?rev=741436&view=rev
Log:
Updating with latest changes

Modified:
commons/proper/cli/trunk/xdocs/changes.xml

Modified: commons/proper/cli/trunk/xdocs/changes.xml
URL: 
http://svn.apache.org/viewvc/commons/proper/cli/trunk/xdocs/changes.xml?rev=741436&r1=741435&r2=741436&view=diff
==
--- commons/proper/cli/trunk/xdocs/changes.xml (original)
+++ commons/proper/cli/trunk/xdocs/changes.xml Fri Feb  6 06:53:40 2009
@@ -23,6 +23,18 @@
   
 
 
+  
+Incomplete usage documentation about Java property option.
+  
+  
+TypeHandler prints messages to stderr.
+  
+  
+TypeHandler prints messages to stderr.
+  
+  
+Infinite loop in the wrapping code of HelpFormatter.
+  
   
 Fixing some minor javadoc issues.
   




svn commit: r741432 - /commons/proper/cli/branches/cli-1.x/README.txt

2009-02-05 Thread bayard
Author: bayard
Date: Fri Feb  6 06:37:07 2009
New Revision: 741432

URL: http://svn.apache.org/viewvc?rev=741432&view=rev
Log:
Ant gone

Modified:
commons/proper/cli/branches/cli-1.x/README.txt

Modified: commons/proper/cli/branches/cli-1.x/README.txt
URL: 
http://svn.apache.org/viewvc/commons/proper/cli/branches/cli-1.x/README.txt?rev=741432&r1=741431&r2=741432&view=diff
==
--- commons/proper/cli/branches/cli-1.x/README.txt (original)
+++ commons/proper/cli/branches/cli-1.x/README.txt Fri Feb  6 06:37:07 2009
@@ -1,28 +1,12 @@
 Apache Commons CLI
 ===
 
-Welcome to the CLI component of the Apache Commons project.
+Welcome to the CLI 1.x component of the Apache Commons project.
 
 The information in this file is relevant if you have
 downloaded a CLI source distribution.
 
-For testing the project, you will need JUnit (if you use
-Maven this will be automatically installed and configured
-for you):
-
-  http://www.junit.org
-
-There are two ways to build CLI, either with Ant or Maven 2.
-
-Ant can be found here :
-
-  http://ant.apache.org
-
-and to build and test the system use:
-
-  ant dist
-
-Maven 2 can be found here :
+CLI is built with Maven 2, which can be found here:
 
   http://maven.apache.org
 




svn commit: r741427 - /commons/proper/cli/branches/cli-1.x/src/test/org/apache/commons/cli/PatternOptionBuilderTest.java

2009-02-05 Thread bayard
Author: bayard
Date: Fri Feb  6 06:11:37 2009
New Revision: 741427

URL: http://svn.apache.org/viewvc?rev=741427&view=rev
Log:
Fixing test message

Modified:

commons/proper/cli/branches/cli-1.x/src/test/org/apache/commons/cli/PatternOptionBuilderTest.java

Modified: 
commons/proper/cli/branches/cli-1.x/src/test/org/apache/commons/cli/PatternOptionBuilderTest.java
URL: 
http://svn.apache.org/viewvc/commons/proper/cli/branches/cli-1.x/src/test/org/apache/commons/cli/PatternOptionBuilderTest.java?rev=741427&r1=741426&r2=741427&view=diff
==
--- 
commons/proper/cli/branches/cli-1.x/src/test/org/apache/commons/cli/PatternOptionBuilderTest.java
 (original)
+++ 
commons/proper/cli/branches/cli-1.x/src/test/org/apache/commons/cli/PatternOptionBuilderTest.java
 Fri Feb  6 06:11:37 2009
@@ -20,8 +20,8 @@
 import java.io.File;
 import java.net.URL;
 import java.util.Calendar;
-import java.util.Vector;
 import java.util.Date;
+import java.util.Vector;
 
 import junit.framework.TestCase;
 
@@ -71,7 +71,7 @@
 
 // DATES NOT SUPPORTED YET
 try {
-assertEquals("number flag z", new Date(1023400137276L), 
line.getOptionObject('z'));
+assertEquals("date flag z", new Date(1023400137276L), 
line.getOptionObject('z'));
 fail("Date is not supported yet, should have failed");
 } catch(UnsupportedOperationException uoe) {
 // expected




svn commit: r741426 - /commons/proper/cli/branches/cli-1.x/src/test/org/apache/commons/cli/PatternOptionBuilderTest.java

2009-02-05 Thread bayard
Author: bayard
Date: Fri Feb  6 06:11:09 2009
New Revision: 741426

URL: http://svn.apache.org/viewvc?rev=741426&view=rev
Log:
Testing the two UnsupportedOperationException method calls

Modified:

commons/proper/cli/branches/cli-1.x/src/test/org/apache/commons/cli/PatternOptionBuilderTest.java

Modified: 
commons/proper/cli/branches/cli-1.x/src/test/org/apache/commons/cli/PatternOptionBuilderTest.java
URL: 
http://svn.apache.org/viewvc/commons/proper/cli/branches/cli-1.x/src/test/org/apache/commons/cli/PatternOptionBuilderTest.java?rev=741426&r1=741425&r2=741426&view=diff
==
--- 
commons/proper/cli/branches/cli-1.x/src/test/org/apache/commons/cli/PatternOptionBuilderTest.java
 (original)
+++ 
commons/proper/cli/branches/cli-1.x/src/test/org/apache/commons/cli/PatternOptionBuilderTest.java
 Fri Feb  6 06:11:09 2009
@@ -21,6 +21,7 @@
 import java.net.URL;
 import java.util.Calendar;
 import java.util.Vector;
+import java.util.Date;
 
 import junit.framework.TestCase;
 
@@ -33,8 +34,8 @@
 {
 public void testSimplePattern() throws Exception
 {
-Options options = 
PatternOptionBuilder.parsePattern("a:b...@cde>f+n%t/");
-String[] args = new String[]{"-c", "-a", "foo", "-b", 
"java.util.Vector", "-e", "build.xml", "-f", "java.util.Calendar", "-n", "4.5", 
"-t", "http://commons.apache.org"};
+Options options = 
PatternOptionBuilder.parsePattern("a:b...@cde>f+n%t/m*z#");
+String[] args = new String[] {"-c", "-a", "foo", "-b", 
"java.util.Vector", "-e", "build.xml", "-f", "java.util.Calendar", "-n", "4.5", 
"-t", "http://commons.apache.org";, "-z", "Thu Jun 06 17:48:57 EDT 2002", "-m", 
"test*"};
 
 CommandLineParser parser = new PosixParser();
 CommandLine line = parser.parse(options, args);
@@ -60,9 +61,21 @@
 assertEquals("number flag n", new Double(4.5), 
line.getOptionObject('n'));
 assertEquals("url flag t", new URL("http://commons.apache.org";), 
line.getOptionObject('t'));
 
-/// DATES NOT SUPPORTED YET.
-//  assertEquals("number flag t", new Date(1023400137276L), 
line.getOptionObject('z'));
-// input is:  "Thu Jun 06 17:48:57 EDT 2002"
+// FILES NOT SUPPORTED YET
+try {
+assertEquals("files flag m", new File[0], 
line.getOptionObject('m'));
+fail("Multiple files are not supported yet, should have failed");
+} catch(UnsupportedOperationException uoe) {
+// expected
+}
+
+// DATES NOT SUPPORTED YET
+try {
+assertEquals("number flag z", new Date(1023400137276L), 
line.getOptionObject('z'));
+fail("Date is not supported yet, should have failed");
+} catch(UnsupportedOperationException uoe) {
+// expected
+}
 }
 
 public void testEmptyPattern() throws Exception




svn commit: r741425 - /commons/proper/cli/branches/cli-1.x/src/java/org/apache/commons/cli/TypeHandler.java

2009-02-05 Thread bayard
Author: bayard
Date: Fri Feb  6 06:10:54 2009
New Revision: 741425

URL: http://svn.apache.org/viewvc?rev=741425&view=rev
Log:
Changing the Files parameter of '*' from a return null to throwing 
UnsupportedOperationException. 

Modified:

commons/proper/cli/branches/cli-1.x/src/java/org/apache/commons/cli/TypeHandler.java

Modified: 
commons/proper/cli/branches/cli-1.x/src/java/org/apache/commons/cli/TypeHandler.java
URL: 
http://svn.apache.org/viewvc/commons/proper/cli/branches/cli-1.x/src/java/org/apache/commons/cli/TypeHandler.java?rev=741425&r1=741424&r2=741425&view=diff
==
--- 
commons/proper/cli/branches/cli-1.x/src/java/org/apache/commons/cli/TypeHandler.java
 (original)
+++ 
commons/proper/cli/branches/cli-1.x/src/java/org/apache/commons/cli/TypeHandler.java
 Fri Feb  6 06:10:54 2009
@@ -241,6 +241,6 @@
 {
 // to implement/port:
 //return FileW.findFiles(str);
-return null;
+throw new UnsupportedOperationException("Not yet implemented");
 }
 }




svn commit: r741421 - in /commons/proper/cli/branches/cli-1.x: build.properties build.xml

2009-02-05 Thread bayard
Author: bayard
Date: Fri Feb  6 05:55:47 2009
New Revision: 741421

URL: http://svn.apache.org/viewvc?rev=741421&view=rev
Log:
Removing the Ant build. Given that it's generated from Maven1, and we no longer 
have that, I don't see any reason to spend time trying to keep it synced with 
the Maven2 pom.xml. 

Removed:
commons/proper/cli/branches/cli-1.x/build.properties
commons/proper/cli/branches/cli-1.x/build.xml



svn commit: r741420 - /commons/proper/cli/branches/cli-1.x/src/conf/checkstyle.xml

2009-02-05 Thread bayard
Author: bayard
Date: Fri Feb  6 05:53:10 2009
New Revision: 741420

URL: http://svn.apache.org/viewvc?rev=741420&view=rev
Log:
Adding AL 2.0 header to checkstyle.xml to satisfy RAT

Modified:
commons/proper/cli/branches/cli-1.x/src/conf/checkstyle.xml

Modified: commons/proper/cli/branches/cli-1.x/src/conf/checkstyle.xml
URL: 
http://svn.apache.org/viewvc/commons/proper/cli/branches/cli-1.x/src/conf/checkstyle.xml?rev=741420&r1=741419&r2=741420&view=diff
==
--- commons/proper/cli/branches/cli-1.x/src/conf/checkstyle.xml (original)
+++ commons/proper/cli/branches/cli-1.x/src/conf/checkstyle.xml Fri Feb  6 
05:53:10 2009
@@ -1,4 +1,21 @@
 
+
+
 http://www.puppycrawl.com/dtds/configuration_1_1.dtd";>




svn commit: r741419 - in /commons/proper/cli/branches/cli-1.x/src/java/org/apache/commons/cli: overview.html package.html

2009-02-05 Thread bayard
Author: bayard
Date: Fri Feb  6 05:52:19 2009
New Revision: 741419

URL: http://svn.apache.org/viewvc?rev=741419&view=rev
Log:
Adding Apache license headers to html to satisfy RAT

Modified:

commons/proper/cli/branches/cli-1.x/src/java/org/apache/commons/cli/overview.html

commons/proper/cli/branches/cli-1.x/src/java/org/apache/commons/cli/package.html

Modified: 
commons/proper/cli/branches/cli-1.x/src/java/org/apache/commons/cli/overview.html
URL: 
http://svn.apache.org/viewvc/commons/proper/cli/branches/cli-1.x/src/java/org/apache/commons/cli/overview.html?rev=741419&r1=741418&r2=741419&view=diff
==
--- 
commons/proper/cli/branches/cli-1.x/src/java/org/apache/commons/cli/overview.html
 (original)
+++ 
commons/proper/cli/branches/cli-1.x/src/java/org/apache/commons/cli/overview.html
 Fri Feb  6 05:52:19 2009
@@ -1,4 +1,19 @@
-
+
 
 
 Commons CLI -- version 1.2

Modified: 
commons/proper/cli/branches/cli-1.x/src/java/org/apache/commons/cli/package.html
URL: 
http://svn.apache.org/viewvc/commons/proper/cli/branches/cli-1.x/src/java/org/apache/commons/cli/package.html?rev=741419&r1=741418&r2=741419&view=diff
==
--- 
commons/proper/cli/branches/cli-1.x/src/java/org/apache/commons/cli/package.html
 (original)
+++ 
commons/proper/cli/branches/cli-1.x/src/java/org/apache/commons/cli/package.html
 Fri Feb  6 05:52:19 2009
@@ -1,4 +1,19 @@
+
 
 
 Commons CLI 1.2




svn commit: r741413 - in /commons/proper/cli: branches/cli-1.x/CLI2Converter.java branches/cli-1.x/CLI2ConverterTest.java trunk/CLI2Converter.java trunk/CLI2ConverterTest.java

2009-02-05 Thread bayard
Author: bayard
Date: Fri Feb  6 05:03:30 2009
New Revision: 741413

URL: http://svn.apache.org/viewvc?rev=741413&view=rev
Log:
Moving the CLI1->2 converter into CLI2 as it would require dependency on both 
and 1 doesn't care about 2's existence. 

Added:
commons/proper/cli/trunk/CLI2Converter.java
  - copied unchanged from r741411, 
commons/proper/cli/branches/cli-1.x/CLI2Converter.java
commons/proper/cli/trunk/CLI2ConverterTest.java
  - copied unchanged from r741411, 
commons/proper/cli/branches/cli-1.x/CLI2ConverterTest.java
Removed:
commons/proper/cli/branches/cli-1.x/CLI2Converter.java
commons/proper/cli/branches/cli-1.x/CLI2ConverterTest.java



svn commit: r741353 - in /commons/sandbox/xml/trunk: ./ src/ src/main/ src/main/java/ src/main/java/org/ src/main/java/org/apache/ src/main/java/org/apache/commons/ src/main/java/org/apache/commons/xm

2009-02-05 Thread jukka
Author: jukka
Date: Fri Feb  6 00:21:24 2009
New Revision: 741353

URL: http://svn.apache.org/viewvc?rev=741353&view=rev
Log:
xml: Added initial Maven 2 build

Added:
commons/sandbox/xml/trunk/pom.xml   (with props)
commons/sandbox/xml/trunk/src/
commons/sandbox/xml/trunk/src/main/
commons/sandbox/xml/trunk/src/main/java/
commons/sandbox/xml/trunk/src/main/java/org/
commons/sandbox/xml/trunk/src/main/java/org/apache/
commons/sandbox/xml/trunk/src/main/java/org/apache/commons/
commons/sandbox/xml/trunk/src/main/java/org/apache/commons/xml/
commons/sandbox/xml/trunk/src/test/
commons/sandbox/xml/trunk/src/test/java/
commons/sandbox/xml/trunk/src/test/java/org/
commons/sandbox/xml/trunk/src/test/java/org/apache/
commons/sandbox/xml/trunk/src/test/java/org/apache/commons/
commons/sandbox/xml/trunk/src/test/java/org/apache/commons/xml/
Modified:
commons/sandbox/xml/trunk/   (props changed)

Propchange: commons/sandbox/xml/trunk/
--
--- svn:ignore (added)
+++ svn:ignore Fri Feb  6 00:21:24 2009
@@ -0,0 +1,5 @@
+target
+.*
+*.iml
+*.ipr
+*.iws

Added: commons/sandbox/xml/trunk/pom.xml
URL: 
http://svn.apache.org/viewvc/commons/sandbox/xml/trunk/pom.xml?rev=741353&view=auto
==
--- commons/sandbox/xml/trunk/pom.xml (added)
+++ commons/sandbox/xml/trunk/pom.xml Fri Feb  6 00:21:24 2009
@@ -0,0 +1,64 @@
+
+
+
+
+http://maven.apache.org/POM/4.0.0";
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
+ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
+ http://maven.apache.org/maven-v4_0_0.xsd";>
+  4.0.0
+
+  
+org.apache.commons
+commons-sandbox-parent
+7
+  
+
+  commons-xml
+  1.0-SNAPSHOT
+  Commons XML (Sandbox)
+  2009
+  
+Library of reusable utility code for working with JAXP.
+  
+
+  http://commons.apache.org/sandbox/xml/
+
+  
+
+  scm:svn:http://svn.apache.org/repos/asf/commons/sandbox/xml/trunk/
+
+
+  scm:svn:https://svn.apache.org/repos/asf/commons/sandbox/xml/trunk/
+
+
+  http://svn.apache.org/viewvc/commons/sandbox/xml/trunk/
+
+  
+
+  
+
+  people.apache.org
+  Commons XML
+  
+
${commons.deployment.protocol}://people.apache.org/www/commons.apache.org/sandbox/xml
+  
+
+  
+
+

Propchange: commons/sandbox/xml/trunk/pom.xml
--
svn:eol-style = native




svn commit: r741351 - /commons/sandbox/xml/trunk/README.txt

2009-02-05 Thread jukka
Author: jukka
Date: Fri Feb  6 00:12:04 2009
New Revision: 741351

URL: http://svn.apache.org/viewvc?rev=741351&view=rev
Log:
xml: Added a README file.

Added:
commons/sandbox/xml/trunk/README.txt   (with props)

Added: commons/sandbox/xml/trunk/README.txt
URL: 
http://svn.apache.org/viewvc/commons/sandbox/xml/trunk/README.txt?rev=741351&view=auto
==
--- commons/sandbox/xml/trunk/README.txt (added)
+++ commons/sandbox/xml/trunk/README.txt Fri Feb  6 00:12:04 2009
@@ -0,0 +1,43 @@
+==
+Welcome to Commons XML
+==
+
+Apache Commons XML is an experimental sandbox component of Apache Commons.
+See the PROPOSAL.txt for the rationale and background of this component.
+
+Mailing Lists
+=
+
+Discussion about Commons XML takes place on the d...@commons.apache.org
+mailing list. This mailing lists are open to anyone and publicly archived.
+You can subscribe this list by sending a message to
+dev-subscr...@commons.apache.org.
+
+Please use the [xml] subject prefix when discussing Commons XML on the
+mailing list.
+
+Issue Tracker
+=
+
+There is currently no dedicated issue tracker for the Commons XML component.
+Please use the mailing list to report any issues or to suggest improvements.
+
+License (see also LICENSE.txt)
+==
+
+Collective work: Copyright 2009 The Apache Software Foundation.
+
+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.

Propchange: commons/sandbox/xml/trunk/README.txt
--
svn:eol-style = native




svn commit: r741349 - /commons/sandbox/xml/trunk/PROPOSAL.txt

2009-02-05 Thread jukka
Author: jukka
Date: Fri Feb  6 00:04:45 2009
New Revision: 741349

URL: http://svn.apache.org/viewvc?rev=741349&view=rev
Log:
xml: Added the PROPOSAL file. (I assume .txt is fine)

Added:
commons/sandbox/xml/trunk/PROPOSAL.txt   (with props)

Added: commons/sandbox/xml/trunk/PROPOSAL.txt
URL: 
http://svn.apache.org/viewvc/commons/sandbox/xml/trunk/PROPOSAL.txt?rev=741349&view=auto
==
--- commons/sandbox/xml/trunk/PROPOSAL.txt (added)
+++ commons/sandbox/xml/trunk/PROPOSAL.txt Fri Feb  6 00:04:45 2009
@@ -0,0 +1,67 @@
+
+Proposal for the Commons XML Package
+
+
+0. Rationale
+
+
+Many Apache projects have implemented utility classes for working with
+XML documents and the Java API for XML Processing (JAXP) interfaces. These
+classes can encapsulate years of experience with XML processing, but they
+can be hard to find and reuse outside the originating project. It would be
+beneficial to have a well maintained shared library of such code.
+
+Various Apache projects like Xerces and Cocoon have been suggested as
+appropriate places where such a shared library could be developed and
+maintained. No clear consensus has however been reached on this matter.
+For now the plan is to just start collecting initial code and interested
+contributors in the Commons sandbox. We can revisit the question of the
+eventual location of this codebase once it is clearer what code will be
+included and who are most interested in developing and maintaining the code.
+
+1. Scope of the Package
+
+
+The Commons XML package will contain utility code designed to make
+working with JAXP easier. The goal is to work with the existing JAXP
+infrastructure instead of trying to come up with an alternative.
+
+1.5 Interaction With Other Packages
+
+The Commons XML package will depend only on the Java 5 platform and the JAXP
+interfaces included in it. No external dependencies or configuration files
+will be used.
+
+2. Initial Source of the Package
+
+
+The initial code of the Commmons XML package will be collected from
+various Apache projects like Tika, Cocoon and Jackrabbit.
+
+The code will be placed within the org.apache.commons.xml package.
+Subpackages for specific types of code like SAX or DOM utilities will
+be created as appropriate.
+
+3. Required Commons Resources
+-
+
+Version Control
+  The Commons XML codebase is located in the "xml" directory
+  inside the Commons Sandbox tree. The codebase can be found at:
+  https://svn.apache.org/repos/asf/commons/sandbox/xml/trunk/
+
+Mailing List
+  Discussions about the Commons XML package will take place on the
+  d...@commons.apache.org mailing list. The subject lines of related
+  messages should prefixed with [xml].
+
+Issue Tracker
+  No issue tracker will be set up for now. We can decide where and
+  how to track issues once the future location of the package becomes
+  clearer.
+
+4. Initial Committers
+-
+
+The proposal is currently being driven by Jukka Zitting, but any
+Apache committer is welcome to join the effort.

Propchange: commons/sandbox/xml/trunk/PROPOSAL.txt
--
svn:eol-style = native




svn commit: r741332 - in /commons/sandbox/xml/trunk: LICENSE.txt NOTICE.txt

2009-02-05 Thread jukka
Author: jukka
Date: Thu Feb  5 22:44:51 2009
New Revision: 741332

URL: http://svn.apache.org/viewvc?rev=741332&view=rev
Log:
xml: Added LICENSE and NOTICE files

Added:
commons/sandbox/xml/trunk/LICENSE.txt
  - copied unchanged from r741326, 
infrastructure/site/trunk/xdocs/licenses/LICENSE-2.0.txt
commons/sandbox/xml/trunk/NOTICE.txt   (with props)

Added: commons/sandbox/xml/trunk/NOTICE.txt
URL: 
http://svn.apache.org/viewvc/commons/sandbox/xml/trunk/NOTICE.txt?rev=741332&view=auto
==
--- commons/sandbox/xml/trunk/NOTICE.txt (added)
+++ commons/sandbox/xml/trunk/NOTICE.txt Thu Feb  5 22:44:51 2009
@@ -0,0 +1,5 @@
+Apache Commons XML
+Copyright 2009 The Apache Software Foundation
+
+This product includes software developed by
+The Apache Software Foundation (http://www.apache.org/).

Propchange: commons/sandbox/xml/trunk/NOTICE.txt
--
svn:eol-style = native




svn commit: r741321 - in /commons/sandbox/xml: branches/ tags/ trunk/

2009-02-05 Thread jukka
Author: jukka
Date: Thu Feb  5 22:36:12 2009
New Revision: 741321

URL: http://svn.apache.org/viewvc?rev=741321&view=rev
Log:
xml: Created the trunk,branches,tags structure for the proposed Commons XML 
component.

Added:
commons/sandbox/xml/branches/
commons/sandbox/xml/tags/
commons/sandbox/xml/trunk/



svn commit: r741320 - /commons/sandbox/xml/

2009-02-05 Thread jukka
Author: jukka
Date: Thu Feb  5 22:34:39 2009
New Revision: 741320

URL: http://svn.apache.org/viewvc?rev=741320&view=rev
Log:
xml: Create a folder for the proposed Commons XML component.

Added:
commons/sandbox/xml/



svn commit: r741319 - in /commons/proper/net/branches/NET_2_0/src: main/java/org/apache/commons/net/ftp/FTPSServerSocketFactory.java test/java/org/apache/commons/net/SubnetUtilsTest.java

2009-02-05 Thread rwinston
Author: rwinston
Date: Thu Feb  5 22:27:47 2009
New Revision: 741319

URL: http://svn.apache.org/viewvc?rev=741319&view=rev
Log:
Cleanup and add test TODO

Modified:

commons/proper/net/branches/NET_2_0/src/main/java/org/apache/commons/net/ftp/FTPSServerSocketFactory.java

commons/proper/net/branches/NET_2_0/src/test/java/org/apache/commons/net/SubnetUtilsTest.java

Modified: 
commons/proper/net/branches/NET_2_0/src/main/java/org/apache/commons/net/ftp/FTPSServerSocketFactory.java
URL: 
http://svn.apache.org/viewvc/commons/proper/net/branches/NET_2_0/src/main/java/org/apache/commons/net/ftp/FTPSServerSocketFactory.java?rev=741319&r1=741318&r2=741319&view=diff
==
--- 
commons/proper/net/branches/NET_2_0/src/main/java/org/apache/commons/net/ftp/FTPSServerSocketFactory.java
 (original)
+++ 
commons/proper/net/branches/NET_2_0/src/main/java/org/apache/commons/net/ftp/FTPSServerSocketFactory.java
 Thu Feb  5 22:27:47 2009
@@ -17,12 +17,10 @@
 
 package org.apache.commons.net.ftp;
 
-import java.io.BufferedReader;
-package org.apache.commons.net.ftp;
-
 import java.io.IOException;
 import java.net.InetAddress;
 import java.net.ServerSocket;
+
 import javax.net.ServerSocketFactory;
 import javax.net.ssl.SSLContext;
 import javax.net.ssl.SSLServerSocket;

Modified: 
commons/proper/net/branches/NET_2_0/src/test/java/org/apache/commons/net/SubnetUtilsTest.java
URL: 
http://svn.apache.org/viewvc/commons/proper/net/branches/NET_2_0/src/test/java/org/apache/commons/net/SubnetUtilsTest.java?rev=741319&r1=741318&r2=741319&view=diff
==
--- 
commons/proper/net/branches/NET_2_0/src/test/java/org/apache/commons/net/SubnetUtilsTest.java
 (original)
+++ 
commons/proper/net/branches/NET_2_0/src/test/java/org/apache/commons/net/SubnetUtilsTest.java
 Thu Feb  5 22:27:47 2009
@@ -46,6 +46,7 @@
 }
 }
 
+// TODO Lower address test
 public void testAddresses() {
 SubnetUtils utils = new SubnetUtils("192.168.0.1/29");
 SubnetInfo info = utils.getInfo();




svn commit: r741226 - in /commons/proper/cli/branches/cli-1.x: pom.xml src/assembly/src.xml

2009-02-05 Thread sgoeschl
Author: sgoeschl
Date: Thu Feb  5 18:38:24 2009
New Revision: 741226

URL: http://svn.apache.org/viewvc?rev=741226&view=rev
Log:
Preparing the release according to 
http://wiki.apache.org/commons/CreatingReleases

Modified:
commons/proper/cli/branches/cli-1.x/pom.xml
commons/proper/cli/branches/cli-1.x/src/assembly/src.xml

Modified: commons/proper/cli/branches/cli-1.x/pom.xml
URL: 
http://svn.apache.org/viewvc/commons/proper/cli/branches/cli-1.x/pom.xml?rev=741226&r1=741225&r2=741226&view=diff
==
--- commons/proper/cli/branches/cli-1.x/pom.xml (original)
+++ commons/proper/cli/branches/cli-1.x/pom.xml Thu Feb  5 18:38:24 2009
@@ -137,6 +137,8 @@
 
 CLI
 12310463
+
+RC1
   
 
   
@@ -232,6 +234,17 @@
 
   
 
+
+  rc
+  
+
+
+  apache.website
+  Apache Commons Release Candidate Staging Site
+  
${commons.deployment.protocol}://people.apache.org/www/people.apache.org/builds/commons/${commons.componentid}/${commons.release.version}/${commons.rc.version}/site
+
+  
+
   
 
 

Modified: commons/proper/cli/branches/cli-1.x/src/assembly/src.xml
URL: 
http://svn.apache.org/viewvc/commons/proper/cli/branches/cli-1.x/src/assembly/src.xml?rev=741226&r1=741225&r2=741226&view=diff
==
--- commons/proper/cli/branches/cli-1.x/src/assembly/src.xml (original)
+++ commons/proper/cli/branches/cli-1.x/src/assembly/src.xml Thu Feb  5 
18:38:24 2009
@@ -20,7 +20,7 @@
 tar.gz
 zip
 
-${project.artifactId}-${project.version}-src
+
${project.artifactId}-${commons.release.version}-src
 
 
 




svn commit: r741217 - in /commons/proper/net/trunk/src/java/org/apache/commons/net: SocketClient.java telnet/TelnetClient.java

2009-02-05 Thread rwinston
Author: rwinston
Date: Thu Feb  5 18:18:21 2009
New Revision: 741217

URL: http://svn.apache.org/viewvc?rev=741217&view=rev
Log:
NET-232 Add null check before disconnect

Modified:
commons/proper/net/trunk/src/java/org/apache/commons/net/SocketClient.java

commons/proper/net/trunk/src/java/org/apache/commons/net/telnet/TelnetClient.java

Modified: 
commons/proper/net/trunk/src/java/org/apache/commons/net/SocketClient.java
URL: 
http://svn.apache.org/viewvc/commons/proper/net/trunk/src/java/org/apache/commons/net/SocketClient.java?rev=741217&r1=741216&r2=741217&view=diff
==
--- commons/proper/net/trunk/src/java/org/apache/commons/net/SocketClient.java 
(original)
+++ commons/proper/net/trunk/src/java/org/apache/commons/net/SocketClient.java 
Thu Feb  5 18:18:21 2009
@@ -264,9 +264,9 @@
  */
 public void disconnect() throws IOException
 {
-_socket_.close();
-_input_.close();
-_output_.close();
+if(_socket_ != null) _socket_.close();
+if(_input_ != null) _input_.close();
+if(_output_ != null) _output_.close();
 _socket_ = null;
 _input_ = null;
 _output_ = null;

Modified: 
commons/proper/net/trunk/src/java/org/apache/commons/net/telnet/TelnetClient.java
URL: 
http://svn.apache.org/viewvc/commons/proper/net/trunk/src/java/org/apache/commons/net/telnet/TelnetClient.java?rev=741217&r1=741216&r2=741217&view=diff
==
--- 
commons/proper/net/trunk/src/java/org/apache/commons/net/telnet/TelnetClient.java
 (original)
+++ 
commons/proper/net/trunk/src/java/org/apache/commons/net/telnet/TelnetClient.java
 Thu Feb  5 18:18:21 2009
@@ -75,11 +75,11 @@
 
 void _flushOutputStream() throws IOException
 {
-_output_.flush();
+if(_output_ != null) _output_.flush();
 }
 void _closeOutputStream() throws IOException
 {
-_output_.close();
+   if(_output_ != null) _output_.close();
 }
 
 /***
@@ -123,8 +123,8 @@
  ***/
 public void disconnect() throws IOException
 {
-__input.close();
-__output.close();
+if(__input != null) __input.close();
+if(__output != null) __output.close();
 super.disconnect();
 }
 




svn commit: r741184 - /commons/proper/email/trunk/src/java/org/apache/commons/mail/EmailUtils.java

2009-02-05 Thread sgoeschl
Author: sgoeschl
Date: Thu Feb  5 17:13:01 2009
New Revision: 741184

URL: http://svn.apache.org/viewvc?rev=741184&view=rev
Log:
When writing a MimeMessage to a file create the required directory if its not 
already there.

Modified:
commons/proper/email/trunk/src/java/org/apache/commons/mail/EmailUtils.java

Modified: 
commons/proper/email/trunk/src/java/org/apache/commons/mail/EmailUtils.java
URL: 
http://svn.apache.org/viewvc/commons/proper/email/trunk/src/java/org/apache/commons/mail/EmailUtils.java?rev=741184&r1=741183&r2=741184&view=diff
==
--- commons/proper/email/trunk/src/java/org/apache/commons/mail/EmailUtils.java 
(original)
+++ commons/proper/email/trunk/src/java/org/apache/commons/mail/EmailUtils.java 
Thu Feb  5 17:13:01 2009
@@ -249,6 +249,11 @@
 throw new IllegalArgumentException( "resulFile is null");
 }
 
+if(resultFile.getParentFile() != null)
+{
+resultFile.getParentFile().mkdirs();
+}
+
 try
 {
 fos = new FileOutputStream(resultFile);




svn commit: r741101 - /commons/sandbox/monitoring/branches/modules/reporting/src/main/java/org/apache/commons/monitoring/reporting/AbstractPeriodicLogger.java

2009-02-05 Thread nicolas
Author: nicolas
Date: Thu Feb  5 13:36:12 2009
New Revision: 741101

URL: http://svn.apache.org/viewvc?rev=741101&view=rev
Log:
configurable startup delay - defautls to period

Modified:

commons/sandbox/monitoring/branches/modules/reporting/src/main/java/org/apache/commons/monitoring/reporting/AbstractPeriodicLogger.java

Modified: 
commons/sandbox/monitoring/branches/modules/reporting/src/main/java/org/apache/commons/monitoring/reporting/AbstractPeriodicLogger.java
URL: 
http://svn.apache.org/viewvc/commons/sandbox/monitoring/branches/modules/reporting/src/main/java/org/apache/commons/monitoring/reporting/AbstractPeriodicLogger.java?rev=741101&r1=741100&r2=741101&view=diff
==
--- 
commons/sandbox/monitoring/branches/modules/reporting/src/main/java/org/apache/commons/monitoring/reporting/AbstractPeriodicLogger.java
 (original)
+++ 
commons/sandbox/monitoring/branches/modules/reporting/src/main/java/org/apache/commons/monitoring/reporting/AbstractPeriodicLogger.java
 Thu Feb  5 13:36:12 2009
@@ -43,6 +43,9 @@
 /** The interval for periodic logging of monitored state */
 private int period;
 
+/** The initial delay */
+private int delay;
+
 /**
  * @param period the period (in ms) to log the monitoring state
  * @param repository the observed repository
@@ -52,6 +55,7 @@
 this();
 this.repository = repository;
 this.period = period;
+this.delay = period;
 }
 
 public AbstractPeriodicLogger()
@@ -77,7 +81,7 @@
 Repository observed = observeRepositoryForPeriod();
 log( observed );
 }
-}, period, period, TimeUnit.MILLISECONDS );
+}, delay, period, TimeUnit.MILLISECONDS );
 }
 
 private Repository observeRepositoryForPeriod()
@@ -120,4 +124,9 @@
 {
 this.period = period;
 }
+
+public void setDelay( int delay )
+{
+this.delay = delay;
+}
 }




svn commit: r741095 - in /commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers: ArchiveStreamFactory.java cpio/CpioArchiveEntry.java cpio/CpioArchiveOutputStream.java jar

2009-02-05 Thread bodewig
Author: bodewig
Date: Thu Feb  5 13:00:07 2009
New Revision: 741095

URL: http://svn.apache.org/viewvc?rev=741095&view=rev
Log:
fix some findbugs issues - SANDBOX-246

Modified:

commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/ArchiveStreamFactory.java

commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/cpio/CpioArchiveEntry.java

commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/cpio/CpioArchiveOutputStream.java

commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/jar/JarArchiveEntry.java

commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/ZipArchiveEntry.java

Modified: 
commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/ArchiveStreamFactory.java
URL: 
http://svn.apache.org/viewvc/commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/ArchiveStreamFactory.java?rev=741095&r1=741094&r2=741095&view=diff
==
--- 
commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/ArchiveStreamFactory.java
 (original)
+++ 
commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/ArchiveStreamFactory.java
 Thu Feb  5 13:00:07 2009
@@ -80,8 +80,9 @@
 
final byte[] signature = new byte[12];
input.mark(signature.length);
-   input.read(signature);
+   int signatureLength = input.read(signature);
// TODO if reset is not supported pass on the IOException or 
return null?
+// TODO, what if we failed to read 12 bytes?
input.reset();
 
if(ZipArchiveInputStream.matches(signature)) {

Modified: 
commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/cpio/CpioArchiveEntry.java
URL: 
http://svn.apache.org/viewvc/commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/cpio/CpioArchiveEntry.java?rev=741095&r1=741094&r2=741095&view=diff
==
--- 
commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/cpio/CpioArchiveEntry.java
 (original)
+++ 
commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/cpio/CpioArchiveEntry.java
 Thu Feb  5 13:00:07 2009
@@ -535,7 +535,11 @@
 case C_ISNWK:
 break;
 default:
-new IllegalArgumentException("Unknown mode");
+// FIXME: testCpioUnarchive fails if I change the line to
+//actually throw the excpetion
+new IllegalArgumentException("Unknown mode (full mode: "
+   + mode + ", masked mode: "
+   + (mode & S_IFMT));
 }
 
 this.mode = mode;

Modified: 
commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/cpio/CpioArchiveOutputStream.java
URL: 
http://svn.apache.org/viewvc/commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/cpio/CpioArchiveOutputStream.java?rev=741095&r1=741094&r2=741095&view=diff
==
--- 
commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/cpio/CpioArchiveOutputStream.java
 (original)
+++ 
commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/cpio/CpioArchiveOutputStream.java
 Thu Feb  5 13:00:07 2009
@@ -121,7 +121,9 @@
 throw new IllegalArgumentException("Unknown header type");
 
 }
-this.entryFormat = format;
+synchronized (this) {
+this.entryFormat = format;
+}
 }
 
 /**
@@ -135,7 +137,7 @@
  * @throws IOException if an I/O error has occurred or if a CPIO file 
error has
  * occurred
  */
-public void putNextEntry(final CpioArchiveEntry e) throws IOException {
+public synchronized void putNextEntry(final CpioArchiveEntry e) throws 
IOException {
 ensureOpen();
 if (this.cpioEntry != null) {
 closeEntry(); // close previous entry
@@ -233,7 +235,7 @@
  * @throws IOException if an I/O error has occurred or if a CPIO file 
error has
  * occurred
  */
-public void closeEntry() throws IOException {
+public synchronized void closeEntry() throws IOException {
 ensureOpen();
 
 if (this.cpioEntry.getSize() != this.written) {
@@ -251,9 +253,7 @@
 throw new IOException("CRC Error");
 }
 }
-if (this.cpioEntry != null) {
-this.cpioEntry = null;
-}
+this.cpioEntry = null;
 this.crc = 0;
 

svn commit: r741092 - in /commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress: archivers/tar/ archivers/zip/ compressors/bzip2/

2009-02-05 Thread bodewig
Author: bodewig
Date: Thu Feb  5 12:45:23 2009
New Revision: 741092

URL: http://svn.apache.org/viewvc?rev=741092&view=rev
Log:
merge revision 741089 from Ant trunk - fix for various findbugs issues - 
[SANDBOX-246]

Modified:

commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/tar/
   (props changed)

commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/tar/TarInputStream.java

commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/tar/TarOutputStream.java

commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/
   (props changed)

commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/AsiExtraField.java

commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/UnrecognizedExtraField.java

commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/ZipFile.java
   (contents, props changed)

commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/ZipLong.java

commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/ZipShort.java

commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/compressors/bzip2/BZip2CompressorOutputStream.java
   (contents, props changed)

Propchange: 
commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/tar/
--
svn:mergeinfo = /ant/core/trunk/src/main/org/apache/tools/tar:741089

Modified: 
commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/tar/TarInputStream.java
URL: 
http://svn.apache.org/viewvc/commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/tar/TarInputStream.java?rev=741092&r1=741091&r2=741092&view=diff
==
--- 
commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/tar/TarInputStream.java
 (original)
+++ 
commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/tar/TarInputStream.java
 Thu Feb  5 12:45:23 2009
@@ -218,8 +218,13 @@
 + numToSkip + " bytes");
 }
 
-if (numToSkip > 0) {
-skip(numToSkip);
+while (numToSkip > 0) {
+long skipped = skip(numToSkip);
+if (skipped <= 0) {
+throw new RuntimeException("failed to skip current tar"
+   + " entry");
+}
+numToSkip -= skipped;
 }
 
 readBuf = null;

Modified: 
commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/tar/TarOutputStream.java
URL: 
http://svn.apache.org/viewvc/commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/tar/TarOutputStream.java?rev=741092&r1=741091&r2=741092&view=diff
==
--- 
commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/tar/TarOutputStream.java
 (original)
+++ 
commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/tar/TarOutputStream.java
 Thu Feb  5 12:45:23 2009
@@ -305,7 +305,7 @@
 
 wOffset += numToWrite;
 assemLen += numToWrite;
-numToWrite -= numToWrite;
+numToWrite = 0;
 }
 }
 

Propchange: 
commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/
--
--- svn:mergeinfo (original)
+++ svn:mergeinfo Thu Feb  5 12:45:23 2009
@@ -1 +1 @@
-/ant/core/trunk/src/main/org/apache/tools/zip:738844,739300
+/ant/core/trunk/src/main/org/apache/tools/zip:738844,739300,741089

Modified: 
commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/AsiExtraField.java
URL: 
http://svn.apache.org/viewvc/commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/AsiExtraField.java?rev=741092&r1=741091&r2=741092&view=diff
==
--- 
commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/AsiExtraField.java
 (original)
+++ 
commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/AsiExtraField.java
 Thu Feb  5 12:45:23 2009
@@ -334,4 +334,14 @@
 return type | (mode & PERM_MASK);
 }
 
+public Object clone() {
+try {
+AsiExtraField cloned = (AsiExtraField) super.clone();
+cloned.crc = new CRC32();
+return cloned;
+} catch (CloneNotSupport

svn commit: r741075 - in /commons/sandbox/compress/trunk: pom.xml src/main/java/org/apache/commons/compress/archivers/zip/ZipArchiveInputStream.java src/main/java/org/apache/commons/compress/compresso

2009-02-05 Thread bodewig
Author: bodewig
Date: Thu Feb  5 11:01:35 2009
New Revision: 741075

URL: http://svn.apache.org/viewvc?rev=741075&view=rev
Log:
some indentation changes and add myself to the POM

Modified:
commons/sandbox/compress/trunk/pom.xml

commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/ZipArchiveInputStream.java

commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/compressors/bzip2/BZip2CompressorOutputStream.java

Modified: commons/sandbox/compress/trunk/pom.xml
URL: 
http://svn.apache.org/viewvc/commons/sandbox/compress/trunk/pom.xml?rev=741075&r1=741074&r2=741075&view=diff
==
--- commons/sandbox/compress/trunk/pom.xml (original)
+++ commons/sandbox/compress/trunk/pom.xml Thu Feb  5 11:01:35 2009
@@ -51,6 +51,11 @@
   bayard
   bayard at apache.org
 
+
+  Stefan Bodewig
+  bodewig
+  bodewig at apache.org
+
   
 
   

Modified: 
commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/ZipArchiveInputStream.java
URL: 
http://svn.apache.org/viewvc/commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/ZipArchiveInputStream.java?rev=741075&r1=741074&r2=741075&view=diff
==
--- 
commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/ZipArchiveInputStream.java
 (original)
+++ 
commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/ZipArchiveInputStream.java
 Thu Feb  5 11:01:35 2009
@@ -27,11 +27,11 @@
 
 public class ZipArchiveInputStream extends ArchiveInputStream {
 
-   private final ZipInputStream input;
+private final ZipInputStream input;
 
-   public ZipArchiveInputStream(InputStream inputStream) {
-   input = new ZipInputStream(inputStream);
-   }
+public ZipArchiveInputStream(InputStream inputStream) {
+input = new ZipInputStream(inputStream);
+}
 
 public ArchiveEntry getNextEntry() throws IOException {
java.util.zip.ZipEntry entry = input.getNextEntry();

Modified: 
commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/compressors/bzip2/BZip2CompressorOutputStream.java
URL: 
http://svn.apache.org/viewvc/commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/compressors/bzip2/BZip2CompressorOutputStream.java?rev=741075&r1=741074&r2=741075&view=diff
==
--- 
commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/compressors/bzip2/BZip2CompressorOutputStream.java
 (original)
+++ 
commons/sandbox/compress/trunk/src/main/java/org/apache/commons/compress/compressors/bzip2/BZip2CompressorOutputStream.java
 Thu Feb  5 11:01:35 2009
@@ -28,7 +28,7 @@
  * header chars) into another stream. TODO: Update to BZip2 1.0.1
  */
 public class BZip2CompressorOutputStream extends CompressorOutputStream 
implements BZip2Constants {
-   protected static final int SETMASK = (1 << 21);
+protected static final int SETMASK = (1 << 21);
 protected static final int CLEARMASK = (~SETMASK);
 protected static final int GREATER_ICOST = 15;
 protected static final int LESSER_ICOST = 0;