There's a parameter to tell Hibernate to generate the tables on startup. It doesn't look configured there and I'm not sure what the default value is.
On Tue, Jun 23, 2009 at 1:31 PM, Andrew Tillinghast <[email protected]>wrote: > Still working with CAS, JBoss 5, JPA and MS SQL. > > Working in ticketRegistry.xml > > No matter what I tried I couldn't seem to get JPA connecting to my MS SQL > box, I tried with the MS SQLJBC package, and the JTDS package. Always goto > datasource not found issues, even tried changing the datasource > to org.springframework.jdbc.datasource.DriverManagerDataSource > > I do seem to have JPA working however by connecting it to the JBoss JTA via > JNDI: > > <bean id="ticketRegistry" > class="org.jasig.cas.ticket.registry.JpaTicketRegistry"> > <constructor-arg index="0" ref="entityManagerFactory" /> > </bean> > <bean id="entityManagerFactory" > class="org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean"> > <property name="persistenceUnitName" value="CasPersistence"/> > <property name="jpaVendorAdapter"> > <bean > class="org.springframework.orm.jpa.vendor.HibernateJpaVendorAdapter"> > <property name="showSql" value="true"/> > <property name="database" value="SQL_SERVER"/> > </bean> > </property> > <property name="jpaProperties"> > <props> > <prop > key="hibernate.transaction.manager_lookup_class">org.hibernate.transaction.JBossTransactionManagerLookup</prop> > </props> > </property> > </bean> > > Now CAS is loading correctly and JBoss is identifying it as persistent but > the CAS tables don't seem to be created. I was expecting I would see them in > the JBoss database I have on the SQL box along side the JBoss persistence > tables but they aren't there. > Right now quartz is throwing an > exception: java.lang.IllegalArgumentException: > org.hibernate.hql.ast.QuerySyntaxException: TicketGrantingTicketImpl is not > mapped [from TicketGrantingTicketImpl] > and on login: org.springframework.web.util.NestedServletException: Request > processing failed; nested exception is > org.springframework.webflow.engine.ActionExecutionException: Exception > thrown executing [annotatedact...@13dc9f3 targetAction = org.jasig.cas. > web.flow.authenticationviaformact...@11d6c3a, attributes = map['method' -> > 'submit']] in state 'submit' of flow 'login-webflow' -- action execution > attributes were 'map['method' -> 'submit']'; nested exception is > org.springframework.dao.InvalidDataAccessApiUsageException: Unknown entity: > org.jasig.cas.ticket.TicketGrantingTicketImpl; nested exception is > java.lang.IllegalArgumentException: Unknown entity: > org.jasig.cas.ticket.TicketGrantingTicketImpl > I'm wondering is I just create the CAS tables by hand it might work. > > Andrew Tillinghast > Sr. Web Developer > [email protected] > 270 Mohegan Avenue > New London, CT 06320-4196 > Ph:860 439-5265 Fax: 860 439-2871 > P *Think before you print > ** > *CONFIDENTIALITY: This email (including any attachments) may contain > confidential, > proprietary and privileged information, and unauthorized disclosure or use > is > prohibited. If you received this email in error, please notify the sender > and delete > this email from your system. > > -- > 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 > > -- 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
<<image.gif>>
