0 Replies Latest reply on May 14, 2009 5:29 PM by brian.stansberry

    ManagedObject persistence for -jboss-beans.xml

    brian.stansberry

      Emanuel,

      Still not seeing attachment persistence for the ServiceBindingManager MOs.

      In Branch_5_x I've modified the way the ServiceBindingManager MOs work along the lines of what we chatted about last week. Basically the conf/bindings-jboss-beans.xml only has one bean that has @ManagedXXX annotations; the rest are pure pojos. That ServiceBindingManagementObject bean exposes a few managed properties, annotated with @MetaMapping. For most properties the result is a CollectionValue whose elements are CompositeValues. This works fine in terms of being able to read the data via the ManagementView and pass back updates to the runtime component.

      But persistence doesn't work. I get a metadata.attachments.xml like the following but that's it:

      <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
      <attachments-metadata xmlns="urn:org:jboss:profileservice:attachments:1.0">
       <deployment-name>bindings-jboss-beans.xml</deployment-name>
       <deployment-structure>
       <relative-order>0</relative-order>
       </deployment-structure>
       <last-modified>1242333438099</last-modified>
      </attachments-metadata>


      I believe the problem is the following call returns null:

      Thread [WorkerThread#0[127.0.0.1:41261]] (Suspended)
       ManagedDeploymentImpl.getManagedObject(String) line: 212
       AbstractAttachmentStore.updateDeployment(ProfileDeployment, ManagedComponent, boolean) line: 426
       AbstractAttachmentStore.updateDeployment(ProfileDeployment, ManagedComponent) line: 342
       ManagementViewImpl.updateComponent(ManagedComponent) line: 1351
       NativeMethodAccessorImpl.invoke0(Method, Object, Object[]) line: not available [native method]
       NativeMethodAccessorImpl.invoke(Object, Object[]) line: 39
       DelegatingMethodAccessorImpl.invoke(Object, Object[]) line: 25
       Method.invoke(Object, Object...) line: 585
       Dispatcher.invoke(Invocation) line: 121
       ProfileServiceInvocationHandler(AOPRemotingInvocationHandler).invoke(InvocationRequest) line: 82
       ProfileServiceInvocationHandler.invoke(InvocationRequest) line: 97
       SocketServerInvoker(ServerInvoker).invoke(InvocationRequest) line: 891
       ServerThread.completeInvocation(SocketWrapper, InputStream, OutputStream, boolean, int) line: 744
       ServerThread.processInvocation(SocketWrapper, InputStream, OutputStream) line: 697
       ServerThread.dorun() line: 524
       ServerThread.run() line: 232


      The name of being looked up is "org.jboss.kernel.plugins.deployment.AbstractKernelDeployment". There is no such entry in the ManagedDeploymentImpl.unitMOs map.

      The component being updated is:

      org.jboss.profileservice.management.TempManagedComponentImpl@238b1d64{name=ServiceBindingManager, type=ComponentType{type=MCBean, subtype=ServiceBindingManager}, owner=ManagedDeployment@37134967}

      It's parent is

      ManagedObject{ServiceBindingManager}

      whose parent is

      ManagedObject{org.jboss.kernel.plugins.deployment.AbstractKernelDeployment}