how did you resolved this problem, I have the Same problem, Could you tell me
the method,to resovle ! Thanks
paul_lmc
View the original post :
http://www.jboss.com/index.html?module=bbop=viewtopicp=4161287#4161287
Reply to the post :
http
my email is : [EMAIL PROTECTED]
View the original post :
http://www.jboss.com/index.html?module=bbop=viewtopicp=4161288#4161288
Reply to the post :
http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4161288
___
jboss-user mailing list
DETAIL LIKE THIS:
public class ArticleEJB extends HibernateBase implements InfoArticleUtil,
ArticleEJBLocal,
ArticleEJBRemote {
public List getAllArticle() {
List list = null;
try{
Begin();
HibernateUtil LIKE THIS :
public class HibernateUtil {
public static SessionFactory sf = null;
public void Init(){
if(sf == null){
sf = new
Configuration().configure().buildSessionFactory();
}
}
}
WEB.XML LIKE
WHEN THE WEB DEMO RUNNING THROW EXCEPTION LIKE THIS :
21:59:09,113 INFO [STDOUT] 21:59:09,113 INFO [Environment] Hibernate 3.1.3
21:59:09,123 INFO [STDOUT] 21:59:09,123 INFO [Environment]
hibernate.properties not found
21:59:09,133 INFO [STDOUT] 21:59:09,133 INFO [Environment] using CGLIB
IN THE CONTEXTLISTENER LIKE THIS :
public class StartUpListener implements ServletContextListener{
public void contextDestroyed(ServletContextEvent arg0) {
}
public void contextInitialized(ServletContextEvent arg0) {
try {
ANYONE CAN HELP ME? THANK YOU
WHY THROW THE CLASSCASTEXCEPTION LIKE THIS:
21:59:24,265 ERROR
[STDERR]java.lang.ClassCastException:org.hibernate.impl.SessionFactoryImpl
View the original post :
http://www.jboss.com/index.html?module=bbop=viewtopicp=4160884#4160884
Reply to the post :
public class HibernateUtil {
public static SessionFactory sf = null;
public void Init(){
if(sf == null){
sf = new
Configuration().configure().buildSessionFactory();
}
}
}
public class StartUpServlet extends
WHTN THE WEB APPLICATION RUN THROW EXCEPTION LIKE THIS:
21:59:08,512 INFO [TomcatDeployer] deploy, ctxPath=/ejb3web,
warUrl=.../deploy/ejb3web.war/
21:59:09,113 INFO [STDOUT] 21:59:09,113 INFO [Environment] Hibernate 3.1.3
21:59:09,123 INFO [STDOUT] 21:59:09,123 INFO [Environment]
ANYONE CAN HELP ME TO SOLVE THE QUESTION ?
THANK YOU VERY MUCH!
View the original post :
http://www.jboss.com/index.html?module=bbop=viewtopicp=4160888#4160888
Reply to the post :
http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4160888
THANK YOU !
BUT I MODIFY APPLICATION LIKE THIS THE NEW EXCEPTION THROW LIKE THIS:
public class HibernateBase {
private static SessionFactory sf = null;
public Session session = null;
public void Begin(){
//å¨è¿éå¯ä»¥æ ¹æ®é
THE HIBERNATE CFG.XML DEPLOY THE SESSIONFACTORY LIKE THIS :
hibernate.dialect=net.sf.hibernate.dialect.MySQLDialect
hibernate.show_sql=true
hibernate.session_factory_name=hibernateJNDI
hibernate.connection.datasource=java:/moreflurish
I USE THE SPRING,HIBERNATE WITH JNDI ,the problems follows:
IN THE APPLICATION.XML deploy like this:
com/moreflurish/domain/article/InfoArticle.hbm.xml
!--property name=dataSource
/property--
com/moreflurish/domain/OaPersonoaPress.hbm.xml
com/moreflurish/domain/OaPersonoaFeedback.hbm.xml
14 matches
Mail list logo