1 2 Previous Next 16 Replies Latest reply on Mar 6, 2008 1:49 AM by starksm64

    jndiName

      So in our code I am creating a LocalTX Datasource, the -ds.xml file is being created and has all the right properties and values, so I don't understand why I get the following warning, then the whole ManagedDeployment errors

      21:47:32,312 WARN [AbstractManagedObjectFactory] Cannot create String name from non-Simple property: ManagedProperty{jn
      di-name,jndiName,metaType=SimpleMetaType:java.lang.String}, value=null
      21:47:32,687 WARN [HDScanner] Failed to process changes
      org.jboss.deployers.client.spi.IncompleteDeploymentException: Summary of incomplete deployments (SEE PREVIOUS ERRORS FOR
      DETAILS):

      *** CONTEXTS MISSING DEPENDENCIES: Name -> Dependency{Required State:Actual State}

      jboss.jca:name=MarkDS,service=ManagedConnectionFactory

      vfsfile:/C:/JBossServers/jboss-5.0.0.CR1/server/default/deploy/MarkDS-ds.xml


      at org.jboss.deployers.plugins.deployers.DeployersImpl.checkComplete(DeployersImpl.java:576)
      at org.jboss.deployers.plugins.main.MainDeployerImpl.checkComplete(MainDeployerImpl.java:559)
      at org.jboss.system.server.profileservice.hotdeploy.HDScanner.scan(HDScanner.java:291)
      at org.jboss.system.server.profileservice.hotdeploy.HDScanner.run(HDScanner.java:221)
      at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:417)
      at java.util.concurrent.FutureTask$Sync.innerRunAndReset(FutureTask.java:280)
      at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:135)
      at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$101(ScheduledThreadPoolExecutor.j
      ava:65)
      at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.runPeriodic(ScheduledThreadPoolExecutor.
      java:142)
      at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:166
      )
      at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:675)
      at java.lang.Thread.run(Thread.java:595)
      21:47:32,750 INFO [ConnectionFactoryBindingService] Bound ConnectionManager 'jboss.jca:service=DataSourceBinding,name=M
      arkDS' to JNDI name 'java:MarkDS'
      21:47:32,843 WARN [ManagementViewImpl] Failed to create ManagedDeployment for: MarkDS-ds.xml
      org.jboss.deployers.spi.DeploymentException: Context MarkDS-ds.xml not found
      at org.jboss.deployers.plugins.main.MainDeployerImpl.getDeploymentContext(MainDeployerImpl.java:173)
      at org.jboss.deployers.plugins.main.MainDeployerImpl.getManagedDeployment(MainDeployerImpl.java:650)
      at org.jboss.profileservice.management.ManagementViewImpl.loadProfile(ManagementViewImpl.java:186)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:585)
      at org.jboss.aop.Dispatcher.invoke(Dispatcher.java:121)
      at org.jboss.aspects.remoting.AOPRemotingInvocationHandler.invoke(AOPRemotingInvocationHandler.java:82)
      at org.jboss.profileservice.remoting.ProfileServiceInvocationHandler.invoke(ProfileServiceInvocationHandler.java
      :56)
      at org.jboss.remoting.ServerInvoker.invoke(ServerInvoker.java:795)
      at org.jboss.remoting.transport.local.LocalClientInvoker.invoke(LocalClientInvoker.java:101)
      at org.jboss.remoting.Client.invoke(Client.java:1634)
      at org.jboss.remoting.Client.invoke(Client.java:548)
      at org.jboss.aspects.remoting.InvokeRemoteInterceptor.invoke(InvokeRemoteInterceptor.java:62)
      at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      at org.jboss.aspects.remoting.MergeMetaDataInterceptor.invoke(MergeMetaDataInterceptor.java:74)
      at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      at org.jboss.aspects.security.SecurityClientInterceptor.invoke(SecurityClientInterceptor.java:65)
      at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      at AOPProxy$1.loadProfile(AOPProxy$1.java)
      at org.rhq.plugins.jbossas5.factory.ProfileServiceFactory.refreshCurrentProfileView(ProfileServiceFactory.java:1
      02)
      at org.rhq.plugins.jbossas5.ProfileJBossServerDiscoveryComponent.discoverResources(ProfileJBossServerDiscoveryCo
      mponent.java:54)
      at org.rhq.core.pc.inventory.AutoDiscoveryExecutor.pluginDiscovery(AutoDiscoveryExecutor.java:189)
      at org.rhq.core.pc.inventory.AutoDiscoveryExecutor.call(AutoDiscoveryExecutor.java:98)
      at org.rhq.core.pc.inventory.AutoDiscoveryExecutor.call(AutoDiscoveryExecutor.java:65)
      at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:269)
      at java.util.concurrent.FutureTask.run(FutureTask.java:123)
      at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.j
      ava:65)
      at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:168
      )
      at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:675)
      at java.lang.Thread.run(Thread.java:595)
      21:47:32,890 INFO [ManagementViewImpl] Creating hsqldb-ds.xml ManagedDeployment
      21:47:32,937 WARN [AbstractManagedObjectFactory] Cannot create String name from non-Simple property: ManagedProperty{JN
      DIName,JNDIName,metaType=SimpleMetaType:java.lang.String}, value=null
      21:47:32,937 WARN [AbstractManagedObjectFactory] Cannot create String name from non-Simple property: ManagedProperty{JN
      DIName,JNDIName,metaType=SimpleMetaType:java.lang.String}, value=null

      Thanks

        • 1. Re: jndiName
          starksm64

          Its because the property value is null.

          • 2. Re: jndiName

            Thanks. ;)

            I mean there is already a jndi-name property, I think this might be related to the Template being out of sync. Maybe the template has jndiName, and the ManagedProperty is annotated as jndi-name.

            This is from the -ds.xml file that was created


            <?xml version="1.0" encoding="UTF-8" standalone="yes"?>

            <local-tx-datasource>
            <jndi-name>MarkDS</jndi-name>
            <use-java-context>true</use-java-context>
            <min-pool-size>0</min-pool-size>
            <max-pool-size>10</max-pool-size>
            <blocking-timeout-millis>30000</blocking-timeout-millis>
            <idle-timeout-minutes>30</idle-timeout-minutes>
            <background-validation>false</background-validation>
            <background-validation-minutes>0</background-validation-minutes>
            <validate-on-match>true</validate-on-match>
            <prepared-statement-cache-size>0</prepared-statement-cache-size>
            <share-prepared-statements>false</share-prepared-statements>
            <set-tx-query-timeout>false</set-tx-query-timeout>
            <query-timeout>0</query-timeout>
            <driver-class>org.hsqldb.jdbcDriver</driver-class>
            <connection-url>jdbc:hsqldb:.</connection-url>
            </local-tx-datasource>

            • 3. Re: jndiName

              Dang forum software, sorry for the unindented xml

              • 4. Re: jndiName

                 

                "bytor99999" wrote:

                21:47:32,687 WARN [HDScanner] Failed to process changes
                org.jboss.deployers.client.spi.IncompleteDeploymentException: Summary of incomplete deployments (SEE PREVIOUS ERRORS FOR
                DETAILS):

                *** CONTEXTS MISSING DEPENDENCIES: Name -> Dependency{Required State:Actual State}

                jboss.jca:name=MarkDS,service=ManagedConnectionFactory

                vfsfile:/C:/JBossServers/jboss-5.0.0.CR1/server/default/deploy/MarkDS-ds.xml


                This looks broken to me. Why is it listing these contexts as missing dependencies
                but not actually showing any dependencies?

                • 5. Re: jndiName

                   

                  "bytor99999" wrote:
                  21:47:32,843 WARN [ManagementViewImpl] Failed to create ManagedDeployment for: MarkDS-ds.xml
                  org.jboss.deployers.spi.DeploymentException: Context MarkDS-ds.xml not found
                  at org.jboss.deployers.plugins.main.MainDeployerImpl.getDeploymentContext(MainDeployerImpl.java:173)
                  at org.jboss.deployers.plugins.main.MainDeployerImpl.getManagedDeployment(MainDeployerImpl.java:650)
                  at org.jboss.profileservice.management.ManagementViewImpl.loadProfile(ManagementViewImpl.java:186)


                  At least part of the problem is that you are passing the wrong deployment name here.

                  • 6. Re: jndiName
                    starksm64

                    Your code is basically the same as the ProfileServiceUnitTestCase.testAddDataSource?

                    I'll work on generating the template from the annotation tomorrow.

                    • 7. Re: jndiName

                       

                      Your code is basically the same as the ProfileServiceUnitTestCase.testAddDataSource?


                      Yes it was definitely modeled after it (matched when I first wrote it), but it could break from any thing that has changed since then.

                      At least part of the problem is that you are passing the wrong deployment name here


                      I haven't changed anything, where this did work before. So in passing the "wrong" deployment, I am not sure what I am missing, or what is now considered wrong. What would it need to be?

                      Thanks guys

                      • 8. Re: jndiName

                         

                        "bytor99999" wrote:

                        At least part of the problem is that you are passing the wrong deployment name here


                        I haven't changed anything, where this did work before. So in passing the "wrong" deployment, I am not sure what I am missing, or what is now considered wrong. What would it need to be?

                        Thanks guys


                        From the error message (after the null problem)
                        you are just passing MarkDS-ds.xml as the deployment name
                        rather than vfsfile:/C:/JBossServers/jboss-5.0.0.CR1/server/default/deploy/MarkDS-ds.xml
                        (or whatever it is called) to the ManagedObject stuff.

                        21:47:32,843 WARN [ManagementViewImpl] Failed to create ManagedDeployment for: MarkDS-ds.xml
                        org.jboss.deployers.spi.DeploymentException: Context MarkDS-ds.xml not found
                        at org.jboss.deployers.plugins.main.MainDeployerImpl.getDeploymentContext(MainDeployerImpl.java:173)
                        at org.jboss.deployers.plugins.main.MainDeployerImpl.getManagedDeployment(MainDeployerImpl.java:650)
                        at org.jboss.profileservice.management.ManagementViewImpl.loadProfile(ManagementViewImpl.java:186)
                        ...
                         at AOPProxy$1.loadProfile(AOPProxy$1.java)
                        at org.rhq.plugins.jbossas5.factory.ProfileServiceFactory.refreshCurrentProfileView(ProfileServiceFactory.java:1


                        • 9. Re: jndiName

                          OK, I will check to see in my code where that is. I don't remember looking up deployments like that. :)

                          Thanks

                          • 10. Re: jndiName

                             

                            "adrian@jboss.org" wrote:
                            "bytor99999" wrote:
                            21:47:32,843 WARN [ManagementViewImpl] Failed to create ManagedDeployment for: MarkDS-ds.xml
                            org.jboss.deployers.spi.DeploymentException: Context MarkDS-ds.xml not found
                            at org.jboss.deployers.plugins.main.MainDeployerImpl.getDeploymentContext(MainDeployerImpl.java:173)
                            at org.jboss.deployers.plugins.main.MainDeployerImpl.getManagedDeployment(MainDeployerImpl.java:650)
                            at org.jboss.profileservice.management.ManagementViewImpl.loadProfile(ManagementViewImpl.java:186)


                            At least part of the problem is that you are passing the wrong deployment name here.


                            OK, I looked at the code, and in this case I am not passing that value at all

                            Here is the last bit of code in that stack from our code

                            at org.rhq.plugins.jbossas5.factory.ProfileServiceFactory.refreshCurrentProfileView(ProfileServiceFactory.java:1
                            02)

                            This is that method

                             public static void refreshCurrentProfileView()
                             {
                             try
                             {
                             Profile activeProfile = getProfileService().getActiveProfile();
                             ProfileKey activeKey = activeProfile.getKey();
                             getCurrentProfileView().loadProfile(activeKey);
                             }
                             catch (Exception e)
                             {
                             LOG.error("Could not find default Profile in Current Profile View", e);
                             }
                             }
                            


                            We are just refreshing our managementView

                            Thanks

                            • 11. Re: jndiName

                              OK, I am thinking this must be an old jar type thing happening

                              The stack trace shows

                              at org.jboss.deployers.plugins.main.MainDeployerImpl.getManagedDeployment(MainDeployerImpl.java:650)

                              However, that line isn't 650 in the most recent version of the java file.

                              I am thinking I am using Microcontainer Beta 10 jar instead of SNAPSHOT, I have the snapshot repository set as a repository in the project's pom file, but sometimes it gets snapshots and sometimes it takes Beta 10 jars.

                              Yep I only see
                              jboss-deployers-impl-2.0.0.Beta10.jar
                              in my local repository.

                              Sometimes I love Maven, sometimes I hate the bastard.

                              Thanks

                              • 12. Re: jndiName

                                and I think the Hudson build still has Beta 10 jars too.

                                • 13. Re: jndiName

                                  I am still a little bit wary though.

                                  when the code inside the ManagementViewImpl is doing is calling the ProfileService.getDeploymentNames() Then loops through those names calling getDeployment(name) from that Collection. It seems when it tries to create a DeploymentContext object from that name it got from itself.

                                  Thanks

                                  • 14. Re: jndiName
                                    starksm64

                                    It would seem to be a hangover from the bad deployment attempt, but I don't know why it would have just the simple name of the ds instead of its full name. Once I'm done with the deployment template factory we'll see if the problem still exists, and if so, reproduce it in the ProfileServiceUnitTestCase.

                                    1 2 Previous Next