Details

    • Type: Bug Bug
    • Status: Closed (View Workflow)
    • Priority: Critical Critical
    • Resolution: Out of Date Out of Date
    • Affects Version/s: 3.3.0.Beta3
    • Fix Version/s: 3.3.0.Beta3
    • Component/s: openshift
    • Labels:
      None
    • Steps to Reproduce:
      Hide
      1. launch OpenShift Express Application Wizard
      2. log in, choose application name & type
      3. hit *Finish"

      Result:
      You get the following error:

      !STACK 0
      com.openshift.express.client.OpenShiftException: NOT SUPPORTED FOR GENERIC APPLICATION
      at com.openshift.express.internal.client.Application.getHealthCheckUrl(Application.java:145)
      at com.openshift.express.internal.client.Application.waitForAccessible(Application.java:222)
      at org.jboss.tools.openshift.express.internal.ui.wizard.OpenShiftExpressApplicationWizardModel.waitForAccessible(OpenShiftExpressApplicationWizardModel.java:349)
      at org.jboss.tools.openshift.express.internal.ui.wizard.OpenShiftExpressApplicationWizardModel.access$0(OpenShiftExpressApplicationWizardModel.java:346)
      at org.jboss.tools.openshift.express.internal.ui.wizard.OpenShiftExpressApplicationWizardModel$1.call(OpenShiftExpressApplicationWizardModel.java:374)
      at org.jboss.tools.openshift.express.internal.ui.wizard.OpenShiftExpressApplicationWizardModel$1.call(OpenShiftExpressApplicationWizardModel.java:1)
      at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
      at java.util.concurrent.FutureTask.run(FutureTask.java:138)
      at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
      at java.lang.Thread.run(Thread.java:662)

      !ENTRY org.jboss.tools.openshift.express.ui 4 0 2012-04-02 11:35:43.382
      !MESSAGE Could not create application "as3"
      !STACK 0
      com.openshift.express.client.OpenShiftException: Failed to create application: NOT SUPPORTED FOR GENERIC APPLICATION
      at org.jboss.tools.openshift.express.internal.ui.wizard.OpenShiftExpressApplicationWizardModel.createApplication(OpenShiftExpressApplicationWizardModel.java:390)
      at org.jboss.tools.openshift.express.internal.ui.wizard.OpenShiftExpressApplicationWizardModel.createApplication(OpenShiftExpressApplicationWizardModel.java:398)
      at org.jboss.tools.openshift.express.internal.ui.wizard.OpenShiftExpressApplicationWizard$3.run(OpenShiftExpressApplicationWizard.java:179)
      at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)

      The application is created though.

      Show
      launch OpenShift Express Application Wizard log in, choose application name & type hit *Finish" Result: You get the following error: !STACK 0 com.openshift.express.client.OpenShiftException: NOT SUPPORTED FOR GENERIC APPLICATION at com.openshift.express.internal.client.Application.getHealthCheckUrl(Application.java:145) at com.openshift.express.internal.client.Application.waitForAccessible(Application.java:222) at org.jboss.tools.openshift.express.internal.ui.wizard.OpenShiftExpressApplicationWizardModel.waitForAccessible(OpenShiftExpressApplicationWizardModel.java:349) at org.jboss.tools.openshift.express.internal.ui.wizard.OpenShiftExpressApplicationWizardModel.access$0(OpenShiftExpressApplicationWizardModel.java:346) at org.jboss.tools.openshift.express.internal.ui.wizard.OpenShiftExpressApplicationWizardModel$1.call(OpenShiftExpressApplicationWizardModel.java:374) at org.jboss.tools.openshift.express.internal.ui.wizard.OpenShiftExpressApplicationWizardModel$1.call(OpenShiftExpressApplicationWizardModel.java:1) at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303) at java.util.concurrent.FutureTask.run(FutureTask.java:138) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) at java.lang.Thread.run(Thread.java:662) !ENTRY org.jboss.tools.openshift.express.ui 4 0 2012-04-02 11:35:43.382 !MESSAGE Could not create application "as3" !STACK 0 com.openshift.express.client.OpenShiftException: Failed to create application: NOT SUPPORTED FOR GENERIC APPLICATION at org.jboss.tools.openshift.express.internal.ui.wizard.OpenShiftExpressApplicationWizardModel.createApplication(OpenShiftExpressApplicationWizardModel.java:390) at org.jboss.tools.openshift.express.internal.ui.wizard.OpenShiftExpressApplicationWizardModel.createApplication(OpenShiftExpressApplicationWizardModel.java:398) at org.jboss.tools.openshift.express.internal.ui.wizard.OpenShiftExpressApplicationWizard$3.run(OpenShiftExpressApplicationWizard.java:179) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54) The application is created though.
    • Similar Issues:
      Show 10 results 

      Description

      When creating a new application with the current tooling against the current production server of OpemShift you get the following error:

        Gliffy Diagrams

          Activity

          Hide
          Andre Dietisheim added a comment - - edited

          The changes that lead to this problem we authored by Bill DeCoste of the OpenShift team. I'll ask him to correct the bug since I dont know what lead him to do those changes.
          I mailed bill de coste of the OpenShift team today:

          Hi Bill

          I included the latest jars in our tooling last friday. When we tried to create news applications with our tooling this morning (CET) we faced the following issue:

          https://issues.jboss.org/browse/JBIDE-11445

          When looking into the code I found the following:
          Application:

              public String getHealthCheckUrl() throws OpenShiftException {
                  throw new OpenShiftException("NOT SUPPORTED FOR GENERIC APPLICATION");
              }
             
              public String getHealthCheckResponse() throws OpenShiftException {
                  throw new OpenShiftException("NOT SUPPORTED FOR GENERIC APPLICATION");
              }
          

          This is the reason for the error we get.

          Subclasses offer a method to check for the health of an application:

          JBossASApplication:

              public String getHealthCheckUrl() throws OpenShiftException {
                  return getApplicationUrl() + "/health";
              }
             
              public String getHealthCheckResponse() throws OpenShiftException {
                  return "1";
              }
          

          I dont really understand why you changed this and why you're relying on fixed paths here.
          Let me try to line out how things were supposed to work before:

          1) When creating a new application, the legacy service reported an URL at which we could check for the application health:

          ApplicationResponseUnmarshaller:

              protected IApplication createOpenShiftObject(ModelNode node) {
                  ...
                  String healthCheckPath = getDataNodeProperty(IOpenShiftJsonConstants.PROPERTY_HEALTH_CHECK_PATH, node);
                  ...
                 
                  if (cartridge instanceof JBossCartridge) {
                      return new JBossASApplication(applicationName, uuid, creationLog, healthCheckPath, cartridge, user, service);
          

          The application was reporting this health check path in Application#getHealthCheckUrl:

          public String getHealthCheckUrl() throws OpenShiftException {
               return getApplicationUrl() + '/' + healthCheckPath;
          

          2.) You'd only have the health check url if you were in the (user-) session that had created the application. I double checked with the libra team (Mike McGrath) backthen if the health url could not be provided later on. They were telling me that this was the way it should be. They were telling me that the healt-check url was not responding to requests after a while, it was only reliable to check it when creating the application.
          The old code would most likely not work in this latter usecase, it was afaik trying to check if the application was responding with 200 on its application-url (web-url). This might be the problem you were solving when chaning the code.

          To me there are 2 problems with the current code:
          1) Is it correct to use a fixed health check path now?
          2) most likely there is a problem when creating an Application instance from the json-response. In my issue I was trying to create a jboss-as application and was obviously getting a Application whereas I should have got a JBossAsApplication so that I would get the right #getHealthCheckUrl

          Show
          Andre Dietisheim added a comment - - edited The changes that lead to this problem we authored by Bill DeCoste of the OpenShift team. I'll ask him to correct the bug since I dont know what lead him to do those changes. I mailed bill de coste of the OpenShift team today: Hi Bill I included the latest jars in our tooling last friday. When we tried to create news applications with our tooling this morning (CET) we faced the following issue: https://issues.jboss.org/browse/JBIDE-11445 When looking into the code I found the following: Application: public String getHealthCheckUrl() throws OpenShiftException { throw new OpenShiftException("NOT SUPPORTED FOR GENERIC APPLICATION"); } public String getHealthCheckResponse() throws OpenShiftException { throw new OpenShiftException("NOT SUPPORTED FOR GENERIC APPLICATION"); } This is the reason for the error we get. Subclasses offer a method to check for the health of an application: JBossASApplication: public String getHealthCheckUrl() throws OpenShiftException { return getApplicationUrl() + "/health"; } public String getHealthCheckResponse() throws OpenShiftException { return "1"; } I dont really understand why you changed this and why you're relying on fixed paths here. Let me try to line out how things were supposed to work before: 1) When creating a new application, the legacy service reported an URL at which we could check for the application health: ApplicationResponseUnmarshaller: protected IApplication createOpenShiftObject(ModelNode node) { ... String healthCheckPath = getDataNodeProperty(IOpenShiftJsonConstants.PROPERTY_HEALTH_CHECK_PATH, node); ... if (cartridge instanceof JBossCartridge) { return new JBossASApplication(applicationName, uuid, creationLog, healthCheckPath, cartridge, user, service); The application was reporting this health check path in Application#getHealthCheckUrl: public String getHealthCheckUrl() throws OpenShiftException { return getApplicationUrl() + '/' + healthCheckPath; 2.) You'd only have the health check url if you were in the (user-) session that had created the application. I double checked with the libra team (Mike McGrath) backthen if the health url could not be provided later on. They were telling me that this was the way it should be. They were telling me that the healt-check url was not responding to requests after a while, it was only reliable to check it when creating the application. The old code would most likely not work in this latter usecase, it was afaik trying to check if the application was responding with 200 on its application-url (web-url). This might be the problem you were solving when chaning the code. To me there are 2 problems with the current code: 1) Is it correct to use a fixed health check path now? 2) most likely there is a problem when creating an Application instance from the json-response. In my issue I was trying to create a jboss-as application and was obviously getting a Application whereas I should have got a JBossAsApplication so that I would get the right #getHealthCheckUrl
          Hide
          Andre Dietisheim added a comment -

          Bill responsed:

          Hi Andre,

          I see where I went wrong, but the health URL is not valid in the latest build(s). JSON is returning "health" for the health_check_path but the URL is failing. I'm looking into what is wrong on the server side.

          Thanks -Bill

          Show
          Andre Dietisheim added a comment - Bill responsed: Hi Andre, I see where I went wrong, but the health URL is not valid in the latest build(s). JSON is returning "health" for the health_check_path but the URL is failing. I'm looking into what is wrong on the server side. Thanks -Bill
          Hide
          Andre Dietisheim added a comment -

          So we should get a new fixed client jar pretty soon.

          Show
          Andre Dietisheim added a comment - So we should get a new fixed client jar pretty soon.
          Hide
          Andre Dietisheim added a comment -

          committed new client jar (1.2.1) to our svn.

          Show
          Andre Dietisheim added a comment - committed new client jar (1.2.1) to our svn.
          Hide
          Andre Dietisheim added a comment -

          with the new client jar I still have issues when creating applications:

          In the log I see the following:

          com.openshift.express.client.OpenShiftEndpointException: Could not configure application "as2" at "https://openshift.redhat.com/broker/cartridge"
          at com.openshift.express.client.OpenShiftService.sendRequest(OpenShiftService.java:526)
          at com.openshift.express.client.OpenShiftService.requestApplicationAction(OpenShiftService.java:435)
          at com.openshift.express.client.OpenShiftService.createApplication(OpenShiftService.java:290)
          at com.openshift.express.client.OpenShiftService.createApplication(OpenShiftService.java:191)
          at com.openshift.express.internal.client.InternalUser.createApplication(InternalUser.java:197)
          at org.jboss.tools.openshift.express.internal.core.console.UserDelegate.createApplication(UserDelegate.java:117)
          at org.jboss.tools.openshift.express.internal.ui.wizard.OpenShiftExpressApplicationWizardModel$1.call(OpenShiftExpressApplicationWizardModel.java:370)
          at org.jboss.tools.openshift.express.internal.ui.wizard.OpenShiftExpressApplicationWizardModel$1.call(OpenShiftExpressApplicationWizardModel.java:1)
          at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
          at java.util.concurrent.FutureTask.run(FutureTask.java:138)
          at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
          at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
          at java.lang.Thread.run(Thread.java:662)
          Caused by: java.net.SocketTimeoutException: Read timed out
          at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
          at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
          at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
          at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
          at sun.net.www.protocol.http.HttpURLConnection$6.run(HttpURLConnection.java:1491)
          at java.security.AccessController.doPrivileged(Native Method)
          at sun.net.www.protocol.http.HttpURLConnection.getChainedException(HttpURLConnection.java:1485)
          at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1139)
          at java.net.HttpURLConnection.getResponseCode(HttpURLConnection.java:379)
          at sun.net.www.protocol.https.HttpsURLConnectionImpl.getResponseCode(HttpsURLConnectionImpl.java:318)
          at com.openshift.express.internal.client.httpclient.UrlConnectionHttpClient.createException(UrlConnectionHttpClient.java:103)
          at com.openshift.express.internal.client.httpclient.UrlConnectionHttpClient.post(UrlConnectionHttpClient.java:75)
          at com.openshift.express.client.OpenShiftService.sendRequest(OpenShiftService.java:517)
          ... 12 more
          Caused by: java.net.SocketTimeoutException: Read timed out
          at java.net.SocketInputStream.socketRead0(Native Method)
          at java.net.SocketInputStream.read(SocketInputStream.java:129)
          at com.sun.net.ssl.internal.ssl.InputRecord.readFully(InputRecord.java:293)
          at com.sun.net.ssl.internal.ssl.InputRecord.read(InputRecord.java:331)
          at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:798)
          at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readDataRecord(SSLSocketImpl.java:755)
          at com.sun.net.ssl.internal.ssl.AppInputStream.read(AppInputStream.java:75)
          at java.io.BufferedInputStream.fill(BufferedInputStream.java:218)
          at java.io.BufferedInputStream.read1(BufferedInputStream.java:258)
          at java.io.BufferedInputStream.read(BufferedInputStream.java:317)
          at sun.net.www.http.HttpClient.parseHTTPHeader(HttpClient.java:695)
          at sun.net.www.http.HttpClient.parseHTTP(HttpClient.java:640)
          at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1195)
          at sun.net.www.protocol.https.HttpsURLConnectionImpl.getInputStream(HttpsURLConnectionImpl.java:234)
          at com.openshift.express.internal.client.httpclient.UrlConnectionHttpClient.post(UrlConnectionHttpClient.java:70)
          ... 13 more

          !ENTRY org.jboss.tools.openshift.express.ui 4 0 2012-04-03 12:35:57.721
          !MESSAGE Could not create application "as2"
          !STACK 0
          com.openshift.express.client.OpenShiftException: Failed to create application: Could not configure application "as2" at "https://openshift.redhat.com/broker/cartridge"
          at org.jboss.tools.openshift.express.internal.ui.wizard.OpenShiftExpressApplicationWizardModel.createApplication(OpenShiftExpressApplicationWizardModel.java:390)
          at org.jboss.tools.openshift.express.internal.ui.wizard.OpenShiftExpressApplicationWizardModel.createApplication(OpenShiftExpressApplicationWizardModel.java:398)
          at org.jboss.tools.openshift.express.internal.ui.wizard.OpenShiftExpressApplicationWizard$3.run(OpenShiftExpressApplicationWizard.java:179)
          at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)

          To me there's now an issue with the way timeouts are reported. They dont make it to the UI any longer. We need to fix that.

          Show
          Andre Dietisheim added a comment - with the new client jar I still have issues when creating applications: In the log I see the following: com.openshift.express.client.OpenShiftEndpointException: Could not configure application "as2" at "https://openshift.redhat.com/broker/cartridge" at com.openshift.express.client.OpenShiftService.sendRequest(OpenShiftService.java:526) at com.openshift.express.client.OpenShiftService.requestApplicationAction(OpenShiftService.java:435) at com.openshift.express.client.OpenShiftService.createApplication(OpenShiftService.java:290) at com.openshift.express.client.OpenShiftService.createApplication(OpenShiftService.java:191) at com.openshift.express.internal.client.InternalUser.createApplication(InternalUser.java:197) at org.jboss.tools.openshift.express.internal.core.console.UserDelegate.createApplication(UserDelegate.java:117) at org.jboss.tools.openshift.express.internal.ui.wizard.OpenShiftExpressApplicationWizardModel$1.call(OpenShiftExpressApplicationWizardModel.java:370) at org.jboss.tools.openshift.express.internal.ui.wizard.OpenShiftExpressApplicationWizardModel$1.call(OpenShiftExpressApplicationWizardModel.java:1) at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303) at java.util.concurrent.FutureTask.run(FutureTask.java:138) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) at java.lang.Thread.run(Thread.java:662) Caused by: java.net.SocketTimeoutException: Read timed out at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) at java.lang.reflect.Constructor.newInstance(Constructor.java:513) at sun.net.www.protocol.http.HttpURLConnection$6.run(HttpURLConnection.java:1491) at java.security.AccessController.doPrivileged(Native Method) at sun.net.www.protocol.http.HttpURLConnection.getChainedException(HttpURLConnection.java:1485) at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1139) at java.net.HttpURLConnection.getResponseCode(HttpURLConnection.java:379) at sun.net.www.protocol.https.HttpsURLConnectionImpl.getResponseCode(HttpsURLConnectionImpl.java:318) at com.openshift.express.internal.client.httpclient.UrlConnectionHttpClient.createException(UrlConnectionHttpClient.java:103) at com.openshift.express.internal.client.httpclient.UrlConnectionHttpClient.post(UrlConnectionHttpClient.java:75) at com.openshift.express.client.OpenShiftService.sendRequest(OpenShiftService.java:517) ... 12 more Caused by: java.net.SocketTimeoutException: Read timed out at java.net.SocketInputStream.socketRead0(Native Method) at java.net.SocketInputStream.read(SocketInputStream.java:129) at com.sun.net.ssl.internal.ssl.InputRecord.readFully(InputRecord.java:293) at com.sun.net.ssl.internal.ssl.InputRecord.read(InputRecord.java:331) at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:798) at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readDataRecord(SSLSocketImpl.java:755) at com.sun.net.ssl.internal.ssl.AppInputStream.read(AppInputStream.java:75) at java.io.BufferedInputStream.fill(BufferedInputStream.java:218) at java.io.BufferedInputStream.read1(BufferedInputStream.java:258) at java.io.BufferedInputStream.read(BufferedInputStream.java:317) at sun.net.www.http.HttpClient.parseHTTPHeader(HttpClient.java:695) at sun.net.www.http.HttpClient.parseHTTP(HttpClient.java:640) at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1195) at sun.net.www.protocol.https.HttpsURLConnectionImpl.getInputStream(HttpsURLConnectionImpl.java:234) at com.openshift.express.internal.client.httpclient.UrlConnectionHttpClient.post(UrlConnectionHttpClient.java:70) ... 13 more !ENTRY org.jboss.tools.openshift.express.ui 4 0 2012-04-03 12:35:57.721 !MESSAGE Could not create application "as2" !STACK 0 com.openshift.express.client.OpenShiftException: Failed to create application: Could not configure application "as2" at "https://openshift.redhat.com/broker/cartridge" at org.jboss.tools.openshift.express.internal.ui.wizard.OpenShiftExpressApplicationWizardModel.createApplication(OpenShiftExpressApplicationWizardModel.java:390) at org.jboss.tools.openshift.express.internal.ui.wizard.OpenShiftExpressApplicationWizardModel.createApplication(OpenShiftExpressApplicationWizardModel.java:398) at org.jboss.tools.openshift.express.internal.ui.wizard.OpenShiftExpressApplicationWizard$3.run(OpenShiftExpressApplicationWizard.java:179) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54) To me there's now an issue with the way timeouts are reported. They dont make it to the UI any longer. We need to fix that.
          Hide
          Max Rydahl Andersen added a comment -

          problem of old client library, issues seen in new is not related. bogus issue now.

          Show
          Max Rydahl Andersen added a comment - problem of old client library, issues seen in new is not related. bogus issue now.

            People

            • Assignee:
              Andre Dietisheim
              Reporter:
              Andre Dietisheim
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development