[EJB 3.0] - Single persistence.xml file with multiple EJB jars
by DeanoUK
Hi all,
Trying to place the persistence.xml file in the ear META-INF, and adding the two EJB jars explicitely, like so:
| <?xml version="1.0" encoding="UTF-8"?>
| <persistence xmlns="http://java.sun.com/xml/ns/persistence">
| <persistence-unit name="msp-par">
| <jta-data-source>java:/@deployeddatabase@</jta-data-source>
| <jar-file>../msp-ejb.jar</jar-file>
| <jar-file>../msp-csi-ejb.jar</jar-file>
| <properties>
| <property name="hibernate.hbm2ddl.auto" value="false"/>
| <property name="com.intellij.javaee.persistence.datasource" value="Datasource"/>
| </properties>
| </persistence-unit>
| </persistence>
|
Unforunately this causes JBoss to error on start, without an explicit cause:
| [27 Mar 2008 12:05:11] ERROR org.jboss.deployment.scanner.URLDeploymentScanner
| - Incomplete Deployment listing:
|
| --- MBeans waiting for other MBeans ---
| ObjectName: jboss.j2ee:ear=msp-ear.ear,jar=msp-csi-ejb.jar,name=AdminSurveyFacad
| eSession,service=EJB3
| State: NOTYETINSTALLED
|
etc etc
Can anyone help?
JBoss 4.2.2.GA
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4139233#4139233
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4139233
18 years
[JBoss jBPM] - Re: HTTP Status 403 - Access to the requested resource has b
by rsdickerson
The problem is that the users the book has you add do not have a "security-role" association. Here's what you can do to resolve this problem:
Insert a row in the JBPM_ID_MEMBERSHIP table for each new user to associate the user with one of the security-roles (manager, participant or administrator...or you can keep it simple and just make them all participants).
Explode the jbpm-console.war file in a temporary location. Edit the web.xml file so that the security-role section looks like this:
<!--
| This role list should be changed to include all the relevant roles for your
| environment.
| -->
| <security-role>
| <role-name>admin</role-name>
| </security-role>
| <security-role>
| <role-name>user</role-name>
| </security-role>
| <security-role>
| <role-name>manager</role-name>
| </security-role>
| <security-role>
| <role-name>participant</role-name>
| </security-role>
| <security-role>
| <role-name>administrator</role-name>
| </security-role>
|
Now, just zip up the war file again (if you use a zip program be sure to change to file extension to 'war').
And redeploy jbpm-console.war.
Let me know if you have any trouble with these instructions and I'll be glad to elaborate on them.
Scott
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4139232#4139232
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4139232
18 years
Re: Problem with TimerService
by samk@twinix.com
See Thread at: http://www.techienuggets.com/Detail?tx=14429 Posted on behalf of a User
Have u got any solution to that problem. I am having the same problem.
Omair
In Response To:
Hello,
i wrote a simple stateless bean to test the TimerService. i am using jboss 4.2.0GA
Whenerver i initialize the time i run into the following exception:
2007-10-02 14:56:55,437 ERROR [org.jboss.ejb.txtimer.TimerServiceImpl] Cannot create txtimer
| java.lang.IllegalStateException: Unable to persist timer
| at org.jboss.ejb.txtimer.DatabasePersistencePolicy.insertTimer(DatabasePersistencePolicy.java:124)
| 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.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
| ...
| ...
| at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:241)
| at org.apache.coyote.ajp.AjpProcessor.process(AjpProcessor.java:437)
| at org.apache.coyote.ajp.AjpProtocol$AjpConnectionHandler.process(AjpProtocol.java:381)
| at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
| at java.lang.Thread.run(Thread.java:595)
| Caused by: org.jboss.util.NestedSQLException: Could not enlist in transaction on entering meta-aware object!; - nested throwable: (javax.transaction.SystemException: java.lang.Throwable: Unabled to enlist resource, see the previous warnings. tx=TransactionImple < ac, BasicAction: -3f57fdff:555:47023fba:53 status: ActionStatus.ABORT_ONLY >); - nested throwable: (org.jboss.resource.JBossResourceException: Could not enlist in transaction on entering meta-aware object!; - nested throwable: (javax.transaction.SystemException: java.lang.Throwable: Unabled to enlist resource, see the previous warnings. tx=TransactionImple < ac, BasicAction: -3f57fdff:555:47023fba:53 status: ActionStatus.ABORT_ONLY >))
| at org.jboss.resource.adapter.jdbc.WrapperDataSource.getConnection(WrapperDataSource.java:94)
| at org.jboss.ejb.txtimer.GeneralPurposeDatabasePersistencePlugin.insertTimer(GeneralPurposeDatabasePersistencePlugin.java:199)
| at org.jboss.ejb.txtimer.DatabasePersistencePolicy.insertTimer(DatabasePersistencePolicy.java:120)
| ... 317 more
| Caused by: org.jboss.resource.JBossResourceException: Could not enlist in transaction on entering meta-aware object!; - nested throwable: (javax.transaction.SystemException: java.lang.Throwable: Unabled to enlist resource, see the previous warnings. tx=TransactionImple < ac, BasicAction: -3f57fdff:555:47023fba:53 status: ActionStatus.ABORT_ONLY >)
| at org.jboss.resource.connectionmanager.TxConnectionManager.managedConnectionReconnected(TxConnectionManager.java:343)
| at org.jboss.resource.connectionmanager.BaseConnectionManager2.reconnectManagedConnection(BaseConnectionManager2.java:518)
| at org.jboss.resource.connectionmanager.BaseConnectionManager2.allocateConnection(BaseConnectionManager2.java:399)
| at org.jboss.resource.connectionmanager.BaseConnectionManager2$ConnectionManagerProxy.allocateConnection(BaseConnectionManager2.java:842)
| at org.jboss.resource.adapter.jdbc.WrapperDataSource.getConnection(WrapperDataSource.java:88)
| ... 319 more
| Caused by: javax.transaction.SystemException: java.lang.Throwable: Unabled to enlist resource, see the previous warnings. tx=TransactionImple < ac, BasicAction: -3f57fdff:555:47023fba:53 status: ActionStatus.ABORT_ONLY >
| at org.jboss.resource.connectionmanager.TxConnectionManager$TxConnectionEventListener$TransactionSynchronization.checkEnlisted(TxConnectionManager.java:744)
| at org.jboss.resource.connectionmanager.TxConnectionManager$TxConnectionEventListener.enlist(TxConnectionManager.java:577)
| at org.jboss.resource.connectionmanager.TxConnectionManager.managedConnectionReconnected(TxConnectionManager.java:337)
| ... 323 mor
I googled a bit and found some issues. Now I still dont know what to do. Do i need to configure the TimerService with my database (MySQL)? I think for me its not neccessary to persist the status. Its enough for me if the timer is executed as long as the application is running.
Any hints would be great.
regards,
hasc
18 years
[JBoss Portal] - Re: WSRP: IBM Websphere Portal Server
by asaitov
Here it is:
| <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
| xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsd="http://www.w3.org/2001/XMLSchema"
| xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
| <soapenv:Header/>
| <soapenv:Body>
| <p631:getServiceDescriptionResponse xmlns:p631="urn:oasis:names:tc:wsrp:v1:types">
| <p631:requiresRegistration>0</p631:requiresRegistration>
| <p631:offeredPortlets>
| <p631:portletHandle>5_BTN9QKG10OVE9023LT9PJ130K4</p631:portletHandle>
| <p631:markupTypes>
| <p631:mimeType>text/html</p631:mimeType>
| <p631:modes>wsrp:view</p631:modes>
| <p631:windowStates>wsrp:normal</p631:windowStates>
| <p631:windowStates>wsrp:maximized</p631:windowStates>
| <p631:windowStates>wsrp:minimized</p631:windowStates>
| <p631:locales>en</p631:locales>
| <p631:locales>ru</p631:locales>
| </p631:markupTypes>
| <p631:groupID>1_BTN9QKG10O3D90231E2RDU0082</p631:groupID>
| <p631:description xml:lang="en" resourceName="5_BTN9QKG10OVE9023LT9PJ130K4.DESCRIPTION">
| <p631:value>TestListModel</p631:value>
| </p631:description>
| <p631:shortTitle xml:lang="en" resourceName="5_BTN9QKG10OVE9023LT9PJ130K4.SHORT_TITLE">
| <p631:value>Test List Portlet</p631:value>
| </p631:shortTitle>
| <p631:title xml:lang="en" resourceName="5_BTN9QKG10OVE9023LT9PJ130K4.TITLE">
| <p631:value>Test List Portlet</p631:value>
| </p631:title>
| <p631:displayName xml:lang="en" resourceName="5_BTN9QKG10OVE9023LT9PJ130K4.DISPLAY_NAME">
| <p631:value>TestListPortlet</p631:value>
| </p631:displayName>
| <p631:keywords xml:lang="en" resourceName="5_BTN9QKG10OVE9023LT9PJ130K4.1.KEYWORD">
| <p631:value>Test List Portlet</p631:value>
| </p631:keywords>
| <p631:usesMethodGet>0</p631:usesMethodGet>
| <p631:userContextStoredInSession>0</p631:userContextStoredInSession>
| <p631:templatesStoredInSession>0</p631:templatesStoredInSession>
| <p631:hasUserSpecificState>1</p631:hasUserSpecificState>
| <p631:doesUrlTemplateProcessing>0</p631:doesUrlTemplateProcessing>
| </p631:offeredPortlets>
| <p631:customModeDescriptions itemName="urn:javax:portlet:mode:custom:configure">
| <p631:description xml:lang="en">
| <p631:value>Let administrators configure portlet preferences that are marked non-modifiable.
| </p631:value>
| </p631:description>
| </p631:customModeDescriptions>
| <p631:customModeDescriptions itemName="urn:com:ibm:portlet:mode:custom:edit_default_comp">
| <p631:description xml:lang="en">
| <p631:value>Let administrators set default values for portlet preferences.</p631:value>
| </p631:description>
| </p631:customModeDescriptions>
| <p631:customModeDescriptions itemName="urn:com:ibm:portlet:mode:custom:edit_default">
| <p631:description xml:lang="en">
| <p631:value>Let administrators set default values for portlet preferences.</p631:value>
| </p631:description>
| </p631:customModeDescriptions>
| <p631:requiresInitCookie>perGroup</p631:requiresInitCookie>
| <p631:resourceList>
| <p631:resources resourceName="5_BTN9QKG10OVE9023LT9PJ130K4.DISPLAY_NAME">
| <p631:values xml:lang="en">
| <p631:value>TestListPortlet</p631:value>
| </p631:values>
| <p631:values xml:lang="ru">
| <p631:value>TestListPortlet</p631:value>
| </p631:values>
| </p631:resources>
| <p631:resources resourceName="5_BTN9QKG10OVE9023LT9PJ130K4.TITLE">
| <p631:values xml:lang="en">
| <p631:value>Test List Portlet</p631:value>
| </p631:values>
| <p631:values xml:lang="ru">
| <p631:value>Test List Portlet</p631:value>
| </p631:values>
| </p631:resources>
| <p631:resources resourceName="5_BTN9QKG10OVE9023LT9PJ130K4.SHORT_TITLE">
| <p631:values xml:lang="en">
| <p631:value>Test List Portlet</p631:value>
| </p631:values>
| </p631:resources>
| <p631:resources resourceName="5_BTN9QKG10OVE9023LT9PJ130K4.1.KEYWORD">
| <p631:values xml:lang="en">
| <p631:value>Test List Portlet</p631:value>
| </p631:values>
| </p631:resources>
| <p631:resources resourceName="5_BTN9QKG10OVE9023LT9PJ130K4.DESCRIPTION">
| <p631:values xml:lang="en">
| <p631:value>TestListModel</p631:value>
| </p631:values>
| </p631:resources>
| </p631:resourceList>
| </p631:getServiceDescriptionResponse>
| </soapenv:Body>
| </soapenv:Envelope>
|
Thank you.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4139228#4139228
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4139228
18 years
[JBoss Cache: Core Edition] - Re: basic question on starting a jboss cache
by bstansberry@jboss.com
For the Hibernate 2nd level cache case, how this works depends on what implementation of the org.hibernate.cache.CacheProvider interface you specify when you set the hibernate.cache.provider_class property in you Hibernate config.
If you use the most common one, org.hibernate.cache.TreeCacheProvider, that class will parse your config file, instantiate your cache and start it for you.
You tell Hibernate the resource path to your cache config file by setting the hibernate.cache.provider_configuration_file_resource_path property. There's also a deprecated hibernate.cache.tree_cache.config property that does the same thing.
There's also a org.hibernate.cache.JndiBoundTreeCacheProvider that looks up your cache in JNDI. If you use that, you're responsible for instantiating and starting your cache yourself and getting it bound into JNDI.
If you are running in JBoss AS with the 'all' config you can also specify org.jboss.ejb3.entity.TreeCacheProviderHook. The package name implies it only works for EJB3 entities, but it should work fine for plain Hibernate usage as well. That one works by finding a running cache in JMX. You get the cache running by naming your "cache-config.xml" file "something-service.xml" and deploying it. You then add the hibernate.treecache.mbean.object_name property to your Hibernate config and use it to specify the ObjectName of your cache.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4139222#4139222
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4139222
18 years