15:23:09,864 ERROR [AbstractKernelController] Error installing to Start:
> name=persistence.unit:unitName=#CasPersistence state=Create
> java.lang.RuntimeException: Specification violation [EJB3 JPA 6.2.1.2] - You
> have not defined a non-jta-data-source for a RESOURCE_LOCAL enabled
> persistence context named: CasPersistence

This is caused by the default persistence.xml used to set up the JPA
entity manager:

<persistence xmlns="http://java.sun.com/xml/ns/persistence";
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
        xsi:schemaLocation="http://java.sun.com/xml/ns/persistence
http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd";
        version="1.0">
        <persistence-unit name="CasPersistence" 
transaction-type="RESOURCE_LOCAL">
        </persistence-unit>
</persistence>

You'll need to change RESOURCE_LOCAL to JTA.  May be tricky even with
the Maven WAR overlay deployment process, but should be doable.
Problem is you must define persistence.xml in the same JAR that
contains the JPA-annotated classes, which would be
cas-server-core-$VERSION.jar  You may also need to define a
container-managed data source and you must use
LocalContainerEntityManagerFactoryBean for your entity manager factory
definition in deployConfigContext.xml.

Hope that helps with at least half your problems.

M

-- 
You are currently subscribed to [email protected] as: 
[email protected]
To unsubscribe, change settings or access archives, see 
http://www.ja-sig.org/wiki/display/JSG/cas-user

Reply via email to