You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ant.apache.org by bu...@apache.org on 2015/10/04 04:32:07 UTC

[Bug 58478] New: Ant EXEC tasks randomly hangs while executing set of java based application commands.

https://bz.apache.org/bugzilla/show_bug.cgi?id=58478

            Bug ID: 58478
           Summary: Ant EXEC tasks randomly hangs while executing set of
                    java based application commands.
           Product: Ant
           Version: 1.9.6
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: blocker
          Priority: P2
         Component: Core tasks
          Assignee: notifications@ant.apache.org
          Reporter: rahulhraut@gmail.com

Created attachment 33160
  --> https://bz.apache.org/bugzilla/attachment.cgi?id=33160&action=edit
Ant Script which is failing inconsistently.

I am using a Ant scripts which loads a xml files located at pre-defined paths
into a Java Application (WEB N-Tier Architecture) using Application based
API's. the ant scripts pick the xml files using loop tasks and then fire a
command to load a file. The loading using ant scripts most of the time hang in
between. Sometime it loads all the files. the ratio of success is 1 in every 3
attempts. I am attaching a load file along with this case.

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 58478] Ant EXEC tasks randomly hangs while executing set of java based application commands.

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=58478

--- Comment #6 from Eugène Adell <eu...@gmail.com> ---
(In reply to Gintas Grigelionis from comment #5)
> It looks like the problem is with third party code which uses
> FileUtils.copyFile(), but the failure occurs after copyFile() is called? in
> undisclosed code?

Since this bug was opened ( 2015-10-04 ), the commons-IO which provides
FileUtils.copyFile() had the following Release Notes that could maybe be linked
to this issue. I assume that the user was using Commons IO 2.4 or earlier.

Apache Commons IO Version 2.5
(https://commons.apache.org/proper/commons-io/upgradeto2_5.html)
IO-385:  FileUtils.doCopyFile can potentially loop for ever
                             Exit loop if no data to copy

Apache Commons IO 2.6
(https://commons.apache.org/proper/commons-io/upgradeto2_6.html)
IO-502: Exceptions are suppressed incorrectly when copying files.
                    Thanks to Christian Schulte.


The user could change his application then the file copy would be done by ANT
instead of the ReportLoader.java on which we have no way to debug (or at least
outside of our scope).

I think this bug could be closed.

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 58478] Ant EXEC tasks randomly hangs while executing set of java based application commands.

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=58478

J.M. (Martijn) Kruithof <jk...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |INVALID
             Status|NEEDINFO                    |RESOLVED

--- Comment #7 from J.M. (Martijn) Kruithof <jk...@apache.org> ---
Assuming Eugene is right, please reopen if problem still exists and seems to
originate from ant, and not from the command called.

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 58478] Ant EXEC tasks randomly hangs while executing set of java based application commands.

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=58478

--- Comment #4 from rahulraut <ra...@gmail.com> ---
Correcting the last sentence in the description:

I am attaching a build* file along with this case.

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 58478] Ant EXEC tasks randomly hangs while executing set of java based application commands.

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=58478

--- Comment #2 from rahulraut <ra...@gmail.com> ---
Note that I have already tried inputstring="" in exec task.

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 58478] Ant EXEC tasks randomly hangs while executing set of java based application commands.

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=58478

Eugène Adell <eu...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |eugene.adell@gmail.com

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 58478] Ant EXEC tasks randomly hangs while executing set of java based application commands.

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=58478

Gintas Grigelionis <gi...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |NEEDINFO

--- Comment #5 from Gintas Grigelionis <gi...@apache.org> ---
It looks like the problem is with third party code which uses
FileUtils.copyFile(), but the failure occurs after copyFile() is called? in
undisclosed code?

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 58478] Ant EXEC tasks randomly hangs while executing set of java based application commands.

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=58478

--- Comment #3 from rahulraut <ra...@gmail.com> ---
Some additional information which may help.
Almost all the time whenever the Ant build hangs while running (using EXEC) a
command (java code) is after

(ReportLoader.java)

File dtdx20 = new
File(WTProperties.getServerProperties().getProperty("wt.home") +
windchillDirectorySeperator +"loadXMLFiles" + windchillDirectorySeperator+
"standardX20.dtd");
File copiedDtdx20 =  new File(tempLocation+"standardX20.dtd"); 
FileUtils.copyFile(dtdx20, copiedDtdx20);

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 58478] Ant EXEC tasks randomly hangs while executing set of java based application commands.

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=58478

rahulraut <ra...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |rahulhraut@gmail.com

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 58478] Ant EXEC tasks randomly hangs while executing set of java based application commands.

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=58478

--- Comment #1 from rahulraut <ra...@gmail.com> ---
The command I am using to execute the ant script is ant -f
$WT_HOME/build_loader.xml -DsprintName=37 -Dwt.username=xxx -Dwt.password=xxx
all
JDK version is 1.7_51

-- 
You are receiving this mail because:
You are the assignee for the bug.