Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Java > Java and JDK > BOOK: Professional Java for Web Applications
|
BOOK: Professional Java for Web Applications
This is the forum to discuss the Wrox book Professional Java for Web Applications by Nicholas S. Williams; ISBN: 978-1-118-65646-4
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Professional Java for Web Applications section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old April 28th, 2014, 07:58 AM
Authorized User
 
Join Date: Apr 2014
Posts: 11
Thanks: 0
Thanked 0 Times in 0 Posts
Default Ch28 CustomerSupport InvalidDataAccessApiUsageException

Hi to all,
while running Ch28 Customer support and after creating a ticket i got this error:

HTTP Status 500 - Request processing failed; nested exception is org.springframework.dao.InvalidDataAccessApiUsageE xception: org.hibernate.TransientPropertyValueException: Not-null property references a transient value - transient instance must be saved before current operation : com.wrox.site.entities.Ticket.customer -> com.wrox.site.entities.UserPrincipal; nested exception is java.lang.IllegalStateException: org.hibernate.TransientPropertyValueException: Not-null property references a transient value - transient instance must be saved before current operation : com.wrox.site.entities.Ticket.customer -> com.wrox.site.entities.UserPrincipal

Someone know how to solve this?
 
Old June 11th, 2014, 11:24 PM
Wrox Author
 
Join Date: Jun 2014
Posts: 12
Thanks: 0
Thanked 0 Times in 0 Posts
Default

That's very odd. I do not get this error. Can you please post the complete stacktrace(s)? Can you also post the full Java and Tomcat versions you are using, and let me know if you have updated the Maven dependency versions from those that ship in the pom file?
__________________
-- Nick Williams
 
Old January 27th, 2015, 10:33 AM
Registered User
 
Join Date: Jan 2015
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default RE: Ch28 CustomerSupport InvalidDataAccessApiUsageException

Hi, I have the exact same problem did you manage to solve it ??
 
Old February 12th, 2015, 09:42 AM
Registered User
 
Join Date: Jan 2015
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Are you still listening to this thread ?
If so, did you solve this pb, i've got the same ?
It's a very useful book for me, thank you
 
Old February 12th, 2015, 09:59 AM
Authorized User
 
Join Date: Apr 2014
Posts: 11
Thanks: 0
Thanked 0 Times in 0 Posts
Default

i'm sorry but i havent find any solutions :(
 
Old February 22nd, 2018, 12:53 AM
Registered User
 
Join Date: Feb 2018
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Arrow Same issue

Does anyone have a solution with mistre83 problem I am having the same problem, any help will be appreciated.


21-Feb-2018 22:35:15.498 INFO [http-nio-8080-exec-14] org.apache.catalina.core.StandardContext.reload Reloading Context with name [/customer-support] is completed
22:36:13.725 [task-1] ERROR com.wrox.config.RootContextConfiguration.[scheduling] - Unknown error occurred while executing task.
org.springframework.dao.InvalidDataAccessApiUsageE xception: Name for parameter binding must not be null or empty! For named parameters you need to use @Param for query method parameters on Java versions < 8.; nested exception is java.lang.IllegalArgumentException: Name for parameter binding must not be null or empty! For named parameters you need to use @Param for query method parameters on Java versions < 8.
at org.springframework.orm.jpa.EntityManagerFactoryUt ils.convertJpaAccessExceptionIfPossible(EntityMana gerFactoryUtils.java:384) ~[spring-orm-4.0.6.RELEASE.jar:4.0.6.RELEASE]
at org.springframework.orm.jpa.vendor.HibernateJpaDia lect.translateExceptionIfPossible(HibernateJpaDial ect.java:157) ~[spring-orm-4.0.6.RELEASE.jar:4.0.6.RELEASE]
at org.springframework.orm.jpa.AbstractEntityManagerF actoryBean.translateExceptionIfPossible(AbstractEn tityManagerFactoryBean.java:417) ~[spring-orm-4.0.6.RELEASE.jar:4.0.6.RELEASE]
at org.springframework.dao.support.ChainedPersistence ExceptionTranslator.translateExceptionIfPossible(C hainedPersistenceExceptionTranslator.java:59) ~[spring-tx-4.0.6.RELEASE.jar:4.0.6.RELEASE]
at org.springframework.dao.support.DataAccessUtils.tr anslateIfNecessary(DataAccessUtils.java:213) ~[spring-tx-4.0.6.RELEASE.jar:4.0.6.RELEASE]
at org.springframework.dao.support.PersistenceExcepti onTranslationInterceptor.invoke(PersistenceExcepti onTranslationInterceptor.java:147) ~[spring-tx-4.0.6.RELEASE.jar:4.0.6.RELEASE]
at org.springframework.aop.framework.ReflectiveMethod Invocation.proceed(ReflectiveMethodInvocation.java :179) ~[spring-aop-4.0.6.RELEASE.jar:4.0.6.RELEASE]
at org.springframework.data.jpa.repository.support.Lo ckModeRepositoryPostProcessor$LockModePopulatingMe thodIntercceptor.invoke(LockModeRepositoryPostProc essor.java:105) ~[spring-data-jpa-1.5.3.RELEASE.jar:?]
at org.springframework.aop.framework.ReflectiveMethod Invocation.proceed(ReflectiveMethodInvocation.java :179) ~[spring-aop-4.0.6.RELEASE.jar:4.0.6.RELEASE]
at org.springframework.aop.interceptor.ExposeInvocati onInterceptor.invoke(ExposeInvocationInterceptor.j ava:92) ~[spring-aop-4.0.6.RELEASE.jar:4.0.6.RELEASE]
at org.springframework.aop.framework.ReflectiveMethod Invocation.proceed(ReflectiveMethodInvocation.java :179) ~[spring-aop-4.0.6.RELEASE.jar:4.0.6.RELEASE]
at org.springframework.aop.framework.JdkDynamicAopPro xy.invoke(JdkDynamicAopProxy.java:207) ~[spring-aop-4.0.6.RELEASE.jar:4.0.6.RELEASE]
at com.sun.proxy.$Proxy358.deleteWhereTimestampLessTh an(Unknown Source) ~[?:?]
at com.wrox.site.DefaultOAuthNonceServices.deleteOldN onces(DefaultOAuthNonceServices.java:30) ~[classes/:?]
at com.wrox.site.DefaultOAuthNonceServices$$FastClass BySpringCGLIB$$6c42f34d.invoke(<generated>) ~[spring-core-4.0.6.RELEASE.jar:?]
at org.springframework.cglib.proxy.MethodProxy.invoke (MethodProxy.java:204) ~[spring-core-4.0.6.RELEASE.jar:4.0.6.RELEASE]
at org.springframework.aop.framework.CglibAopProxy$Cg libMethodInvocation.invokeJoinpoint(CglibAopProxy. java:708) ~[spring-aop-4.0.6.RELEASE.jar:4.0.6.RELEASE]
at org.springframework.aop.framework.ReflectiveMethod Invocation.proceed(ReflectiveMethodInvocation.java :157) ~[spring-aop-4.0.6.RELEASE.jar:4.0.6.RELEASE]
at org.springframework.transaction.interceptor.Transa ctionInterceptor$1.proceedWithInvocation(Transacti onInterceptor.java:98) ~[spring-tx-4.0.6.RELEASE.jar:4.0.6.RELEASE]
at org.springframework.transaction.interceptor.Transa ctionAspectSupport.invokeWithinTransaction(Transac tionAspectSupport.java:262) ~[spring-tx-4.0.6.RELEASE.jar:4.0.6.RELEASE]
at org.springframework.transaction.interceptor.Transa ctionInterceptor.invoke(TransactionInterceptor.jav a:95) ~[spring-tx-4.0.6.RELEASE.jar:4.0.6.RELEASE]
at org.springframework.aop.framework.ReflectiveMethod Invocation.proceed(ReflectiveMethodInvocation.java :179) ~[spring-aop-4.0.6.RELEASE.jar:4.0.6.RELEASE]
at org.springframework.aop.framework.CglibAopProxy$Dy namicAdvisedInterceptor.intercept(CglibAopProxy.ja va:644) ~[spring-aop-4.0.6.RELEASE.jar:4.0.6.RELEASE]
at com.wrox.site.DefaultOAuthNonceServices$$EnhancerB ySpringCGLIB$$8e9e1278.deleteOldNonces(<generated> ) ~[spring-core-4.0.6.RELEASE.jar:?]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Nativ e Method) ~[?:1.8.0_162]
at sun.reflect.NativeMethodAccessorImpl.invoke(Native MethodAccessorImpl.java:62) ~[?:1.8.0_162]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(De legatingMethodAccessorImpl.java:43) ~[?:1.8.0_162]
at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_162]
at org.springframework.scheduling.support.ScheduledMe thodRunnable.run(ScheduledMethodRunnable.java:65) ~[spring-context-4.0.6.RELEASE.jar:4.0.6.RELEASE]
at org.springframework.scheduling.support.DelegatingE rrorHandlingRunnable.run(DelegatingErrorHandlingRu nnable.java:54) [spring-context-4.0.6.RELEASE.jar:4.0.6.RELEASE]
at java.util.concurrent.Executors$RunnableAdapter.cal l(Executors.java:511) [?:1.8.0_162]

Last edited by barbelou; February 22nd, 2018 at 12:55 AM..





Similar Threads
Thread Thread Starter Forum Replies Last Post
ch28 rat BOOK: Beginning JavaServer Pages 0 August 24th, 2007 11:04 AM
CustomerSupport Site papalolo22 BOOK: ASP.NET 2.0 Instant Results ISBN: 978-0-471-74951-6 3 March 13th, 2007 02:50 PM
Ch28 - HTTP Status 503 - Servlet action is current mona3000m BOOK: Beginning JavaServer Pages 0 December 3rd, 2006 04:19 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.