glassfish
  1. glassfish
  2. GLASSFISH-18354

Edit and delete of virtual server failed

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 3.1.1_b12
    • Fix Version/s: 4.0_b80_EE7MS6, 4.0
    • Component/s: rest-interface
    • Labels:
      None
    • Environment:

      Linux (Ubuntu 11.10) 64bit Oracle VM 1.7.0-b147

      Description

      I've created a virtual server which is named "test-server (DEV)" (Only the part within the quotes).
      After adding him I've received the following error:

      An error has occurred
      REST: Exception java.lang.NullPointerException at org.glassfish.admin.rest.resources.PropertiesBagResource.setParentAndTagName(PropertiesBagResource.java:278) at org.glassfish.admin.rest.resources.generatedASM.VirtualServerResource.getPropertiesBagResource(Unknown Source) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:601) at com.sun.jersey.server.impl.uri.rules.SubLocatorRule.invokeSubLocator(SubLocatorRule.java:171) at com.sun.jersey.server.impl.uri.rules.SubLocatorRule.accept(SubLocatorRule.java:107) at com.sun.jersey.server.impl.uri.rules.RightHandPathRule.accept(RightHandPathRule.java:147) at com.sun.jersey.server.impl.uri.rules.SubLocatorRule.accept(SubLocatorRule.java:134) at com.sun.jersey.server.impl.uri.rules.RightHandPathRule.accept(R .... msg.seeServerLog

      When trying to delete him:

      An error has occurred
      DELETE http://localhost:4848/management/domain/configs/config/server-config/http-service/virtual-server/test-server+%28DEV%29?target=server returned a response status of 404 Not Found

      I think it's an issue related to the whitespace and/or the braces.

        Issue Links

          Activity

          Hide
          Joe Di Pol added a comment -

          Not a 3.1.2 stopper. Deferring from 3.1.2.

          Show
          Joe Di Pol added a comment - Not a 3.1.2 stopper. Deferring from 3.1.2.
          Hide
          Tom Mueller added a comment -

          This appears to be an issue in the REST layer. Using the asadmin create-virtual-server command, a virtual server with name "test-server (DEV)" can be created and deleted.

          Show
          Tom Mueller added a comment - This appears to be an issue in the REST layer. Using the asadmin create-virtual-server command, a virtual server with name "test-server (DEV)" can be created and deleted.
          Hide
          Anissa Lam added a comment -

          With the latest 4.0 build, using the console, I can create the virtual server with the name "test-server (DEV)" and then also delete that successfully.

          However, if i want to edit that, there is an exception thrown in REST.

          #]

          [#|2013-02-20T21:58:34.147-0800|INFO|glassfish 4.0|javax.enterprise.admin.rest|_ThreadID=124;_ThreadName=admin-listener(2);_TimeMillis=1361426314147;_LevelValue=800;_MessageID=NCLS-REST-00003;|An error occurred while processing the request. Please see the server logs for details.
          java.lang.NullPointerException
          at org.glassfish.admin.rest.resources.PropertiesBagResource.setParentAndTagName(PropertiesBagResource.java:265)
          at org.glassfish.admin.rest.resources.generatedASM.VirtualServerResource.getPropertiesBagResource(Unknown Source)
          at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
          at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
          at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
          at java.lang.reflect.Method.invoke(Method.java:601)
          at org.glassfish.jersey.server.internal.routing.SubResourceLocatorRouter.getResource(SubResourceLocatorRouter.java:197)
          at org.glassfish.jersey.server.internal.routing.SubResourceLocatorRouter.apply(SubResourceLocatorRouter.java:115)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:118)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121)
          at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121)
          at org.glassfish.jersey.server.internal.routing.RoutingStage.apply(RoutingStage.java:102)
          at org.glassfish.jersey.server.internal.routing.RoutingStage.apply(RoutingStage.java:62)
          at org.glassfish.jersey.process.internal.Stages.process(Stages.java:197)
          at org.glassfish.jersey.server.ServerRuntime$1.run(ServerRuntime.java:198)
          at org.glassfish.jersey.process.internal.RequestScope.runInScope(RequestScope.java:317)
          at org.glassfish.jersey.server.ServerRuntime.process(ServerRuntime.java:183)
          at org.glassfish.jersey.server.ApplicationHandler.handle(ApplicationHandler.java:852)
          at org.glassfish.jersey.grizzly2.httpserver.GrizzlyHttpContainer.service(GrizzlyHttpContainer.java:321)
          at org.glassfish.admin.rest.adapter.RestAdapter$2.service(RestAdapter.java:318)
          at org.glassfish.admin.rest.adapter.RestAdapter.service(RestAdapter.java:181)
          at com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:246)
          at org.glassfish.grizzly.http.server.HttpHandler.doHandle(HttpHandler.java:164)
          at org.glassfish.grizzly.http.server.HttpServerFilter.handleRead(HttpServerFilter.java:175)
          at org.glassfish.grizzly.filterchain.ExecutorResolver$9.execute(ExecutorResolver.java:119)
          at org.glassfish.grizzly.filterchain.DefaultFilterChain.executeFilter(DefaultFilterChain.java:273)
          at org.glassfish.grizzly.filterchain.DefaultFilterChain.executeChainPart(DefaultFilterChain.java:200)
          at org.glassfish.grizzly.filterchain.DefaultFilterChain.execute(DefaultFilterChain.java:134)
          at org.glassfish.grizzly.filterchain.DefaultFilterChain.process(DefaultFilterChain.java:112)
          at org.glassfish.grizzly.ProcessorExecutor.execute(ProcessorExecutor.java:77)
          at org.glassfish.grizzly.nio.transport.TCPNIOTransport.fireIOEvent(TCPNIOTransport.java:820)
          at org.glassfish.grizzly.strategies.AbstractIOStrategy.fireIOEvent(AbstractIOStrategy.java:113)
          at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy.run0(WorkerThreadIOStrategy.java:115)
          at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy.access$100(WorkerThreadIOStrategy.java:55)
          at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy$WorkerThreadRunnable.run(WorkerThreadIOStrategy.java:135)
          at org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:564)
          at org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.run(AbstractThreadPool.java:544)
          at java.lang.Thread.run(Thread.java:722)

          #]

          [#|2013-02-20T21:58:34.147-0800|SEVERE|glassfish 4.0|org.glassfish.admingui|_ThreadID=127;_ThreadName=admin-listener(4);_TimeMillis=1361426314147;_LevelValue=1000;|RestResponse.getResponse() gives FAILURE. endpoint = 'http://localhost:4848/management/domain/configs/config/server-config/http-service/virtual-server/est-server+%28DEV%29/property.json'; attrs = '{}'|#]

          Show
          Anissa Lam added a comment - With the latest 4.0 build, using the console, I can create the virtual server with the name "test-server (DEV)" and then also delete that successfully. However, if i want to edit that, there is an exception thrown in REST. #] [#|2013-02-20T21:58:34.147-0800|INFO|glassfish 4.0|javax.enterprise.admin.rest|_ThreadID=124;_ThreadName=admin-listener(2);_TimeMillis=1361426314147;_LevelValue=800;_MessageID=NCLS-REST-00003;|An error occurred while processing the request. Please see the server logs for details. java.lang.NullPointerException at org.glassfish.admin.rest.resources.PropertiesBagResource.setParentAndTagName(PropertiesBagResource.java:265) at org.glassfish.admin.rest.resources.generatedASM.VirtualServerResource.getPropertiesBagResource(Unknown Source) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:601) at org.glassfish.jersey.server.internal.routing.SubResourceLocatorRouter.getResource(SubResourceLocatorRouter.java:197) at org.glassfish.jersey.server.internal.routing.SubResourceLocatorRouter.apply(SubResourceLocatorRouter.java:115) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:118) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121) at org.glassfish.jersey.server.internal.routing.RoutingStage._apply(RoutingStage.java:121) at org.glassfish.jersey.server.internal.routing.RoutingStage.apply(RoutingStage.java:102) at org.glassfish.jersey.server.internal.routing.RoutingStage.apply(RoutingStage.java:62) at org.glassfish.jersey.process.internal.Stages.process(Stages.java:197) at org.glassfish.jersey.server.ServerRuntime$1.run(ServerRuntime.java:198) at org.glassfish.jersey.process.internal.RequestScope.runInScope(RequestScope.java:317) at org.glassfish.jersey.server.ServerRuntime.process(ServerRuntime.java:183) at org.glassfish.jersey.server.ApplicationHandler.handle(ApplicationHandler.java:852) at org.glassfish.jersey.grizzly2.httpserver.GrizzlyHttpContainer.service(GrizzlyHttpContainer.java:321) at org.glassfish.admin.rest.adapter.RestAdapter$2.service(RestAdapter.java:318) at org.glassfish.admin.rest.adapter.RestAdapter.service(RestAdapter.java:181) at com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:246) at org.glassfish.grizzly.http.server.HttpHandler.doHandle(HttpHandler.java:164) at org.glassfish.grizzly.http.server.HttpServerFilter.handleRead(HttpServerFilter.java:175) at org.glassfish.grizzly.filterchain.ExecutorResolver$9.execute(ExecutorResolver.java:119) at org.glassfish.grizzly.filterchain.DefaultFilterChain.executeFilter(DefaultFilterChain.java:273) at org.glassfish.grizzly.filterchain.DefaultFilterChain.executeChainPart(DefaultFilterChain.java:200) at org.glassfish.grizzly.filterchain.DefaultFilterChain.execute(DefaultFilterChain.java:134) at org.glassfish.grizzly.filterchain.DefaultFilterChain.process(DefaultFilterChain.java:112) at org.glassfish.grizzly.ProcessorExecutor.execute(ProcessorExecutor.java:77) at org.glassfish.grizzly.nio.transport.TCPNIOTransport.fireIOEvent(TCPNIOTransport.java:820) at org.glassfish.grizzly.strategies.AbstractIOStrategy.fireIOEvent(AbstractIOStrategy.java:113) at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy.run0(WorkerThreadIOStrategy.java:115) at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy.access$100(WorkerThreadIOStrategy.java:55) at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy$WorkerThreadRunnable.run(WorkerThreadIOStrategy.java:135) at org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:564) at org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.run(AbstractThreadPool.java:544) at java.lang.Thread.run(Thread.java:722) #] [#|2013-02-20T21:58:34.147-0800|SEVERE|glassfish 4.0|org.glassfish.admingui|_ThreadID=127;_ThreadName=admin-listener(4);_TimeMillis=1361426314147;_LevelValue=1000;|RestResponse.getResponse() gives FAILURE. endpoint = 'http://localhost:4848/management/domain/configs/config/server-config/http-service/virtual-server/est-server+%28DEV%29/property.json'; attrs = '{}'|#]
          Hide
          Jason Lee added a comment -

          The tag name was not being decoded, so the system was looking for "test-server+(DEV)", which it couldn't find. Fix committed in r59737.

          Show
          Jason Lee added a comment - The tag name was not being decoded, so the system was looking for "test-server+(DEV)", which it couldn't find. Fix committed in r59737.

            People

            • Assignee:
              Jason Lee
              Reporter:
              internalerror
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: