File tree Expand file tree Collapse file tree
src/main/java/com/openfin/desktop/demo Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -54,6 +54,12 @@ public static void teardown() throws Exception {
5454
5555 private static void setupDesktopConnection () throws Exception {
5656 CountDownLatch openFinConnectedLatch = new CountDownLatch (1 );
57+ // if RVM needs to download the version of Runtime specified, waitTime may need to be increased for slow download
58+ int waitTime = 60 ;
59+ String swaiTime = java .lang .System .getProperty ("com.openfin.demo.runtime.connect.wait.time" );
60+ if (swaiTime != null ) {
61+ waitTime = Integer .parseInt (swaiTime );
62+ }
5763
5864 desktopConnection = null ;
5965 desktopConnection = new DesktopConnection (DESKTOP_UUID );
@@ -85,10 +91,10 @@ public void onMessage(String message) {
8591 public void onOutgoingMessage (String message ) {
8692 printf ("openfin outgoing message: %s" , message );
8793 }
88- }, 60000 );//this timeout (in 4.40.2.9) is ignored
94+ }, waitTime );//this timeout (in 4.40.2.9) is ignored
8995
9096 printf ("waiting for desktop to connect" );
91- openFinConnectedLatch .await (20 , TimeUnit .SECONDS );
97+ openFinConnectedLatch .await (waitTime , TimeUnit .SECONDS );
9298
9399 if (desktopConnection .isConnected ()) {
94100 printf ("desktop connected" );
You can’t perform that action at this time.
0 commit comments