Hi,
I have a dipendency problem with hibernate search 3.0.1 and jboss 4.2.2 GA.
Actually I tried all possible jars combinations:
--------------------------------------------------------
In server/default/lib:
hibernate-3.2.6/3.3.1
hibernate-annotations-3.3.1/3.4.0
hibernate-entitymanager-3.3.0/3.3.1/3.3.2/3.4.0
hibernate-validator-3.0.0/3.1.0
hibernate-commons-annotations-3.0.0
---------------------------------------------------------
In WEB-INF/lib:
lucene-core-2.30/2.3.1/2.3.2
hibernate-search-3.0.1/3.1.0
---------------------------------------------------------
I also tried the new hibernate-search beta release but still the same problem.
this is the stacktrace:
Code:
java.lang.NoSuchMethodError: org.hibernate.search.FullTextSession.createFullTextQuery(Lorg/apache/lucene/search/Query;[Ljava/lang/Class;)Lorg/hibernate/Query;
at it.ror.search.Searcher.getSearch(Searcher.java:55)
at it.rortutor.servlet.ServletLuceneTest.processRequest(ServletLuceneTest.java:43)
at it.rortutor.servlet.ServletLuceneTest.doGet(ServletLuceneTest.java:72)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:690)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:179)
at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:262)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:446)
at java.lang.Thread.run(Unknown Source)
I guess there is something I am forgetting.
I have no problems indexing my data.
Problems only comes when I try to perform a search with the following code :
Code:
AnnotationConfiguration h8Conf= new AnnotationConfiguration();
h8Conf.configure();
h8Conf.getProperties().put(org.hibernate.search.Environment.ANALYZER_CLASS, StandardAnalyzer.class.getName());
SessionFactory sessionFactory=h8Conf.buildSessionFactory();
Session s= sessionFactory.openSession();
FullTextSession fullTextSession= Search.createFullTextSession(s);
Transaction tx=fullTextSession.beginTransaction();
MultiFieldQueryParser parser = new MultiFieldQueryParser(new String[]{"idParagrafo.nome", "testo"},
new StandardAnalyzer());
org.apache.lucene.search.Query q=parser.parse(param);
Query h8Query=fullTextSession.createFullTextQuery(q, Contenuti.class);
Thank you so much for any help
Violix