You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@airavata.apache.org by SmashRod Alfredo <sm...@hotmail.it> on 2015/04/29 11:42:50 UTC

If statement workflow example

Hi everybody,
Is there any example of a workflow using the IF statement in X-Baya (release 0.14)? If it's not can someone please explain to me the necessary constraint to build up this kind of workflow?

My use case is the following:

I've registered an application interface wrapper (namely "my_process" )doing some processing and giving a feeback output (mapped in the airavata interface as integer) of the succesful execution of the application execution.

Based on the feeback i want to simply execute an echo application (with specific feedback inputs)

I try to build up the workflow but with this elements 

-> 4 inputs fields (2 for my application interface wrapper), and 2 for the final echoed feedback
-> An application interface wrapper ("my_process") instance
-> An if statement (taking the output from my_process interface
-> 2 application interface of echo instances (connected respectivetly with the two trigger of if statement)
-> and EndIf statement (taking the 2 output of "echo" instances)
-> a final output instance getting the output from endif statment.


Running this kind of workflow makes XBaya to freeze and I cannot do anything.

The airavata-server trace is the following:

Id:TestComplex_f8f41f5a-eda1-45b4-b21b-727fee6fc642 : Created new experiment with experiment name TestComplex
[INFO] Client session timed out, have not heard from server in 4066ms for sessionid 0x14d0474ae880002, closing socket connection and attempting reconnect
[INFO] Client session timed out, have not heard from server in 4067ms for sessionid 0x14d0474ae880000, closing socket connection and attempting reconnect
[WARN] caught end of stream exception
EndOfStreamException: Unable to read additional data from client sessionid 0x14d0474ae880002, likely client has closed socket
    at org.apache.zookeeper.server.NIOServerCnxn.doIO(NIOServerCnxn.java:220)
    at org.apache.zookeeper.server.NIOServerCnxnFactory.run(NIOServerCnxnFactory.java:224)
    at java.lang.Thread.run(Thread.java:745)
[INFO] Disconnected
[INFO] Initiating client connection, connectString=localhost:2181 sessionTimeout=6000 watcher=org.apache.airavata.api.server.AiravataAPIServer@5bfde7cb
[INFO] Opening socket connection to server /0:0:0:0:0:0:0:1:2181
[INFO] Opening socket connection to server /127.0.0.1:2181
[INFO] Closed socket connection for client /0:0:0:0:0:0:0:1:39607 which had sessionid 0x14d0474ae880002
[INFO] Disconnected
[INFO] Socket connection established to localhost/127.0.0.1:2181, initiating session
[WARN] caught end of stream exception
EndOfStreamException: Unable to read additional data from client sessionid 0x14d0474ae880000, likely client has closed socket
    at org.apache.zookeeper.server.NIOServerCnxn.doIO(NIOServerCnxn.java:220)
    at org.apache.zookeeper.server.NIOServerCnxnFactory.run(NIOServerCnxnFactory.java:224)
    at java.lang.Thread.run(Thread.java:745)
[INFO] Socket connection established to localhost/0:0:0:0:0:0:0:1:2181, initiating session
[INFO] Initiating client connection, connectString=localhost:2181 sessionTimeout=6000 watcher=org.apache.airavata.gfac.server.GfacServerHandler@47fc1d97
[INFO] Opening socket connection to server /127.0.0.1:2181
[INFO] Expiring session 0x14d0474ae880002, timeout of 6000ms exceeded
[INFO] Socket connection established to localhost/127.0.0.1:2181, initiating session
[INFO] Closed socket connection for client /127.0.0.1:32915 which had sessionid 0x14d0474ae880000
[INFO] Opening socket connection to server /127.0.0.1:2181
[INFO] Expiring session 0x14d0474ae880000, timeout of 6000ms exceeded
[INFO] Accepted socket connection from /0:0:0:0:0:0:0:1:39629
[INFO] Processed session termination for sessionid: 0x14d0474ae880002
[INFO] Accepted socket connection from /127.0.0.1:32940
[INFO] Client session timed out, have not heard from server in 4002ms for sessionid 0x14d0474ae880001, closing socket connection and attempting reconnect
[INFO] Socket connection established to localhost/127.0.0.1:2181, initiating session
[INFO] Client attempting to renew session 0x14d0474ae880000 at /0:0:0:0:0:0:0:1:39629
[INFO] Processed session termination for sessionid: 0x14d0474ae880000
[INFO] Invalid session 0x14d0474ae880000 for client /0:0:0:0:0:0:0:1:39629, probably expired
[INFO] Accepted socket connection from /127.0.0.1:32941
[WARN] caught end of stream exception
EndOfStreamException: Unable to read additional data from client sessionid 0x14d0474ae880001, likely client has closed socket
    at org.apache.zookeeper.server.NIOServerCnxn.doIO(NIOServerCnxn.java:220)
    at org.apache.zookeeper.server.NIOServerCnxnFactory.run(NIOServerCnxnFactory.java:224)
    at java.lang.Thread.run(Thread.java:745)
[INFO] Closed socket connection for client /127.0.0.1:32916 which had sessionid 0x14d0474ae880001
[INFO] Client attempting to renew session 0x14d0474ae880002 at /127.0.0.1:32940
[INFO] Invalid session 0x14d0474ae880002 for client /127.0.0.1:32940, probably expired
[INFO] Unable to reconnect to ZooKeeper service, session 0x14d0474ae880002 has expired, closing socket connection
[INFO] Unable to reconnect to ZooKeeper service, session 0x14d0474ae880000 has expired, closing socket connection
[INFO] Closed socket connection for client /127.0.0.1:32940 which had sessionid 0x14d0474ae880002
[INFO] Opening socket connection to server /0:0:0:0:0:0:0:1:2181
[INFO] Socket connection established to localhost/0:0:0:0:0:0:0:1:2181, initiating session
[INFO] Closed socket connection for client /0:0:0:0:0:0:0:1:39629 which had sessionid 0x14d0474ae880000
[ERROR] Unexpected Exception: 
java.nio.channels.CancelledKeyException
    at sun.nio.ch.SelectionKeyImpl.ensureValid(SelectionKeyImpl.java:73)
    at sun.nio.ch.SelectionKeyImpl.interestOps(SelectionKeyImpl.java:77)
    at org.apache.zookeeper.server.NIOServerCnxn.sendBuffer(NIOServerCnxn.java:153)
    at org.apache.zookeeper.server.NIOServerCnxn.sendResponse(NIOServerCnxn.java:1075)
    at org.apache.zookeeper.server.FinalRequestProcessor.processRequest(FinalRequestProcessor.java:179)
    at org.apache.zookeeper.server.SyncRequestProcessor.flush(SyncRequestProcessor.java:165)
    at org.apache.zookeeper.server.SyncRequestProcessor.run(SyncRequestProcessor.java:101)
[INFO] Client session timed out, have not heard from server in 4333ms for sessionid 0x0, closing socket connection and attempting reconnect
[WARN] Ignoring unexpected runtime exception
java.lang.NullPointerException
    at org.apache.zookeeper.server.NIOServerCnxn.doIO(NIOServerCnxn.java:295)
    at org.apache.zookeeper.server.NIOServerCnxnFactory.run(NIOServerCnxnFactory.java:224)
    at java.lang.Thread.run(Thread.java:745)
[INFO] Client attempting to establish new session at /127.0.0.1:32941
[INFO] Accepted socket connection from /127.0.0.1:32942
[INFO] Accepted socket connection from /0:0:0:0:0:0:0:1:39633
[INFO] Client attempting to establish new session at /127.0.0.1:32942
[INFO] Established session 0x14d0474ae880003 with negotiated timeout 6000 for client /127.0.0.1:32941
[WARN] caught end of stream exception
EndOfStreamException: Unable to read additional data from client sessionid 0x14d0474ae880003, likely client has closed socket
    at org.apache.zookeeper.server.NIOServerCnxn.doIO(NIOServerCnxn.java:220)
    at org.apache.zookeeper.server.NIOServerCnxnFactory.run(NIOServerCnxnFactory.java:224)
    at java.lang.Thread.run(Thread.java:745)
[INFO] Established session 0x14d0474ae880004 with negotiated timeout 6000 for client /127.0.0.1:32942
[INFO] Closed socket connection for client /127.0.0.1:32941 which had sessionid 0x14d0474ae880003
[INFO] Session establishment complete on server localhost/127.0.0.1:2181, sessionid = 0x14d0474ae880004, negotiated timeout = 6000
[INFO] Opening socket connection to server /0:0:0:0:0:0:0:1:2181
[INFO] Socket connection established to localhost/0:0:0:0:0:0:0:1:2181, initiating session
[INFO] Accepted socket connection from /0:0:0:0:0:0:0:1:39635
[INFO] Client attempting to establish new session at /0:0:0:0:0:0:0:1:39635
[INFO] Established session 0x14d0474ae880005 with negotiated timeout 6000 for client /0:0:0:0:0:0:0:1:39635
[INFO] Session establishment complete on server localhost/0:0:0:0:0:0:0:1:2181, sessionid = 0x14d0474ae880005, negotiated timeout = 6000
[INFO] Initiating client connection, connectString=localhost:2181 sessionTimeout=6000 watcher=org.apache.airavata.orchestrator.server.OrchestratorServerHandler@3a347f7f
[INFO] Opening socket connection to server /0:0:0:0:0:0:0:1:2181
[INFO] Accepted socket connection from /0:0:0:0:0:0:0:1:39636
[INFO] Socket connection established to localhost/0:0:0:0:0:0:0:1:2181, initiating session
[INFO] Client attempting to establish new session at /0:0:0:0:0:0:0:1:39636
[INFO] Session establishment complete on server localhost/0:0:0:0:0:0:0:1:2181, sessionid = 0x14d0474ae880006, negotiated timeout = 6000
[INFO] Established session 0x14d0474ae880006 with negotiated timeout 6000 for client /0:0:0:0:0:0:0:1:39636
[INFO] Expiring session 0x14d0474ae880001, timeout of 6000ms exceeded
[INFO] Processed session termination for sessionid: 0x14d0474ae880001
[INFO] Client attempting to renew session 0x14d0474ae880001 at /0:0:0:0:0:0:0:1:39633
[INFO] Invalid session 0x14d0474ae880001 for client /0:0:0:0:0:0:0:1:39633, probably expired
[INFO] Closed socket connection for client /0:0:0:0:0:0:0:1:39633 which had sessionid 0x14d0474ae880001
[INFO] Client session timed out, have not heard from server in 8274ms for sessionid 0x14d0474ae880001, closing socket connection and attempting reconnect
[INFO] Expiring session 0x14d0474ae880003, timeout of 6000ms exceeded
[INFO] Processed session termination for sessionid: 0x14d0474ae880003
[INFO] Opening socket connection to server localhost/127.0.0.1:2181
[INFO] Socket connection established to localhost/127.0.0.1:2181, initiating session
[INFO] Accepted socket connection from /127.0.0.1:32947
[INFO] Client attempting to renew session 0x14d0474ae880001 at /127.0.0.1:32947
[INFO] Invalid session 0x14d0474ae880001 for client /127.0.0.1:32947, probably expired
[INFO] Unable to reconnect to ZooKeeper service, session 0x14d0474ae880001 has expired, closing socket connection
[INFO] Closed socket connection for client /127.0.0.1:32947 which had sessionid 0x14d0474ae880001
[INFO] Validation of org.apache.airavata.orchestrator.core.validator.impl.SimpleAppDataValidator is SUCCESSFUL
[INFO] Validation of org.apache.airavata.orchestrator.core.validator.impl.ExperimentStatusValidator is SUCCESSFUL


Thanks for you attention

Alfredo