Grokbase Groups Ant user May 2015
FAQ
Hi,

I have a main class which I want to run using an ant script.
(I have attached the project, which includes this main class:
WebsocketLocalClient; and the ant script I'm referring to)

This main class executes fully, when I'm running it through the command
line.

But when I run it using the ant script, it executes upto,
*System.out.println("Starting Websocket-local publisher");*

but does not execute beyond the line:
*client.connectToServer(new WebsocketLocalEndpoint(), cec, new
URI(socketServerUrl));*

Ant output is given in attachment-1.
It does not execute anything after printing the log '[java] Starting
Websocket-local publisher'

It seems that,
ant does not return after
calling org.glassfish.tyrus.client.ClientManager.connectToServer() method.

Any clues as to why this is happening?

Appreciate any help.
Thanks,
Dilini

Attachment-1:
dilini@dilini-Latitude-E6540:~/github/product-cep/modules/samples/producers/websocket-local-client$
ant
Buildfile:
/home/dilini/github/product-cep/modules/samples/producers/websocket-local-client/build.xml

init:

compile:
     [javac]
/home/dilini/github/product-cep/modules/samples/producers/websocket-local-client/build.xml:58:
warning: 'includeantruntime' was not set, defaulting to
build.sysclasspath=last; set to false for repeatable builds
      [copy] Copying 1 file to
/home/dilini/github/product-cep/modules/samples/producers/websocket-local-client/temp/classes

run:
      [echo] Configure -Durl=xxxx -Dtopic=xxxx and (-DfilePath=xxxx and/or
-Dsn='sample number')
      [java] Starting Websocket-local publisher

Search Discussions

  • Antoine Levy Lambert at May 18, 2015 at 2:21 am
    Hi,

    I did not take a look at the attached zip file.

    How does ant call WebsocketLocalClient ? I would assume using the java task.

    The java task has fork and spawn attributes. I think that if WebsocketLocalClient is a long running process you should start it with fork=“true” and spawn=“true”. This starts another java process and ant’s execution thread goes further immediately after spawning thisi process.

    Regards,

    Antoine
    On May 9, 2015, at 5:45 AM, Dilini Asanga wrote:

    <websocket-local-client.zip>

    ---------------------------------------------------------------------
    To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
    For additional commands, e-mail: user-help@ant.apache.org

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupuser @
categoriesant
postedMay 9, '15 at 9:45a
activeMay 18, '15 at 2:21a
posts2
users2
websiteant.apache.org

People

Translate

site design / logo © 2018 Grokbase