org.hibernate.search.exception.SearchException: Unable to find field sponsor.profile.tag.id in nl.project.model.social.WallPost

Hibernate JIRA | Marc Schipperheyn | 2 years ago
  1. 0

    So, this is an early report for which I'm not 100% what the underlying issue is, and I'm still having issues getting my environment up and running. But you guys asked for early reports, so here goes A number of my @IndexedEmbedded relations are being reported as non-existing in queries. For example {code} @DiscriminatorValue(value = "WPT") @ClassBridge(impl=WallPostClassBridge.class,index=org.hibernate.search.annotations.Index.YES,analyze=Analyze.NO,store=Store.NO) @Indexed(interceptor=WallPostIndexingInterceptor.class) public class WallPost extends BaseWallPost{ @OneToMany(cascade=CascadeType.ALL, orphanRemoval=true,mappedBy="post", fetch=FetchType.LAZY) @IndexedEmbedded(prefix="sponsor.",indexNullAs=Field.DEFAULT_NULL_TOKEN) public List<SponsoredPost> getSponsored() { return sponsored; } } {code} {code} @Entity @Table(name="SponsoredPost") public class SponsoredPost{ @OneToOne(cascade=CascadeType.ALL,optional=false,fetch=FetchType.EAGER) @JoinColumn(name="FK_TargetProfileId", nullable=false, updatable=false) @IndexedEmbedded(prefix="profile.") @NotNull public TargetProfile getProfile() { return profile; } } {code} {code} Entity @Table(name="TargetProfile") public class TargetProfile{ @ManyToMany(fetch=FetchType.LAZY) @JoinTable(name="TargetProfile_Tags" ,joinColumns=@JoinColumn(name="targetProfileId") ,inverseJoinColumns=@JoinColumn(name="tagId") ) @IndexedEmbedded(prefix="tag.") public Set<Tag> getTags() { return tags; } } {code} The exception I'm seeing is: {code} org.hibernate.search.exception.SearchException: Unable to find field sponsor.profile.tag.id in nl.project.model.social.WallPost at org.hibernate.search.engine.spi.DocumentBuilderIndexedEntity.objectToString(DocumentBuilderIndexedEntity.java:674) at org.hibernate.search.query.dsl.impl.FieldContext.objectToString(FieldContext.java:69) at org.hibernate.search.query.dsl.impl.ConnectedMultiFieldsTermQueryBuilder.buildSearchTerm(ConnectedMultiFieldsTermQueryBuilder.java:129) at org.hibernate.search.query.dsl.impl.ConnectedMultiFieldsTermQueryBuilder.createQuery(ConnectedMultiFieldsTermQueryBuilder.java:83) at org.hibernate.search.query.dsl.impl.ConnectedMultiFieldsTermQueryBuilder.createQuery(ConnectedMultiFieldsTermQueryBuilder.java:64) at nl.project.dao.hibernate.WallDaoHibernate.getSponsoredPosts(WallDaoHibernate.java:2367) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:317) at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:201) at com.sun.proxy.$Proxy173.getSponsoredPosts(Unknown Source) at nl.project.integration.SponsoredPostTest.testSponsoredPostInvalid(SponsoredPostTest.java:477) {code}

    Hibernate JIRA | 2 years ago | Marc Schipperheyn
    org.hibernate.search.exception.SearchException: Unable to find field sponsor.profile.tag.id in nl.project.model.social.WallPost
  2. 0

    So, this is an early report for which I'm not 100% what the underlying issue is, and I'm still having issues getting my environment up and running. But you guys asked for early reports, so here goes A number of my @IndexedEmbedded relations are being reported as non-existing in queries. For example {code} @DiscriminatorValue(value = "WPT") @ClassBridge(impl=WallPostClassBridge.class,index=org.hibernate.search.annotations.Index.YES,analyze=Analyze.NO,store=Store.NO) @Indexed(interceptor=WallPostIndexingInterceptor.class) public class WallPost extends BaseWallPost{ @OneToMany(cascade=CascadeType.ALL, orphanRemoval=true,mappedBy="post", fetch=FetchType.LAZY) @IndexedEmbedded(prefix="sponsor.",indexNullAs=Field.DEFAULT_NULL_TOKEN) public List<SponsoredPost> getSponsored() { return sponsored; } } {code} {code} @Entity @Table(name="SponsoredPost") public class SponsoredPost{ @OneToOne(cascade=CascadeType.ALL,optional=false,fetch=FetchType.EAGER) @JoinColumn(name="FK_TargetProfileId", nullable=false, updatable=false) @IndexedEmbedded(prefix="profile.") @NotNull public TargetProfile getProfile() { return profile; } } {code} {code} Entity @Table(name="TargetProfile") public class TargetProfile{ @ManyToMany(fetch=FetchType.LAZY) @JoinTable(name="TargetProfile_Tags" ,joinColumns=@JoinColumn(name="targetProfileId") ,inverseJoinColumns=@JoinColumn(name="tagId") ) @IndexedEmbedded(prefix="tag.") public Set<Tag> getTags() { return tags; } } {code} The exception I'm seeing is: {code} org.hibernate.search.exception.SearchException: Unable to find field sponsor.profile.tag.id in nl.project.model.social.WallPost at org.hibernate.search.engine.spi.DocumentBuilderIndexedEntity.objectToString(DocumentBuilderIndexedEntity.java:674) at org.hibernate.search.query.dsl.impl.FieldContext.objectToString(FieldContext.java:69) at org.hibernate.search.query.dsl.impl.ConnectedMultiFieldsTermQueryBuilder.buildSearchTerm(ConnectedMultiFieldsTermQueryBuilder.java:129) at org.hibernate.search.query.dsl.impl.ConnectedMultiFieldsTermQueryBuilder.createQuery(ConnectedMultiFieldsTermQueryBuilder.java:83) at org.hibernate.search.query.dsl.impl.ConnectedMultiFieldsTermQueryBuilder.createQuery(ConnectedMultiFieldsTermQueryBuilder.java:64) at nl.project.dao.hibernate.WallDaoHibernate.getSponsoredPosts(WallDaoHibernate.java:2367) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:317) at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:201) at com.sun.proxy.$Proxy173.getSponsoredPosts(Unknown Source) at nl.project.integration.SponsoredPostTest.testSponsoredPostInvalid(SponsoredPostTest.java:477) {code}

    Hibernate JIRA | 2 years ago | Marc Schipperheyn
    org.hibernate.search.exception.SearchException: Unable to find field sponsor.profile.tag.id in nl.project.model.social.WallPost
  3. 0

    Programmatic mapping with embedded index in Hibernate Search results in unable to find field error

    Stack Overflow | 6 months ago | Priya Gachinamath
    org.hibernate.search.exception.SearchException: Unable to find field arr in com....AT
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    When using custom numeric field bridges on a sortable field, querying with a sort on this field will always fail with the following stacktrace: {code} org.hibernate.search.exception.SearchException: HSEARCH000307: Sort type INT is not compatible with UNKNOWN type of field 'favoriteTerritory'. at org.hibernate.search.query.engine.impl.AbstractHSQuery.validateNumericEncodingType(AbstractHSQuery.java:430) at org.hibernate.search.query.engine.impl.AbstractHSQuery.validateNumericSortField(AbstractHSQuery.java:412) at org.hibernate.search.query.engine.impl.AbstractHSQuery.validateSortField(AbstractHSQuery.java:399) at org.hibernate.search.query.engine.impl.AbstractHSQuery.validateCommonSortField(AbstractHSQuery.java:307) at org.hibernate.search.query.engine.impl.AbstractHSQuery.validateSortField(AbstractHSQuery.java:283) at org.hibernate.search.query.engine.impl.AbstractHSQuery.validateSortFields(AbstractHSQuery.java:270) at org.hibernate.search.query.engine.impl.LuceneHSQuery.buildSearcher(LuceneHSQuery.java:481) at org.hibernate.search.query.engine.impl.LuceneHSQuery.buildSearcher(LuceneHSQuery.java:380) at org.hibernate.search.query.engine.impl.LuceneHSQuery.queryEntityInfos(LuceneHSQuery.java:138) at org.hibernate.search.query.hibernate.impl.FullTextQueryImpl.list(FullTextQueryImpl.java:202) at org.hibernate.search.test.query.sorting.SortOnFieldsFromCustomBridgeTest.testNumericCustomFieldLevelBridge(SortOnFieldsFromCustomBridgeTest.java:148) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:47) at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12) at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:44) at org.hibernate.testing.junit4.ExtendedFrameworkMethod.invokeExplosively(ExtendedFrameworkMethod.java:45) at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17) at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:26) at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:27) at org.hibernate.testing.junit4.FailureExpectedHandler.evaluate(FailureExpectedHandler.java:41) at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:271) at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:70) at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:50) at org.junit.runners.ParentRunner$3.run(ParentRunner.java:238) at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:63) at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:236) at org.junit.runners.ParentRunner.access$000(ParentRunner.java:53) at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:229) at org.hibernate.testing.junit4.BeforeClassCallbackHandler.evaluate(BeforeClassCallbackHandler.java:26) at org.hibernate.testing.junit4.AfterClassCallbackHandler.evaluate(AfterClassCallbackHandler.java:25) at org.junit.runners.ParentRunner.run(ParentRunner.java:309) at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:86) at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:459) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:678) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:382) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:192) {code} Pull request coming, with test case and fix.

    Hibernate JIRA | 4 months ago | Yoann Rodière
    org.hibernate.search.exception.SearchException: HSEARCH000307: Sort type INT is not compatible with UNKNOWN type of field 'favoriteTerritory'.
  6. 0

    The following is the exact error: {code} Result window is too large, from + size must be less than or equal to: [10000] but was [10725]. See the scroll api for a more efficient way to request large data sets. {code} To reproduce the problem, I have an index with 11,228 products and issued a query that returned 10,722 hits. The UI returns pages with a page size of 25 products, and so page 1 returned just fine with the first 25. By selecting the last page, which is page 429, I got this error. Pagination parameters are provided to the FullTextQuery by specifying: {code} query.setFirstResult( ( page - 1 ) * pageSize ).setMaxResults( pageSize ); {code} This results in 10,700 being the value for the first result. Stack Trace: {code} org.hibernate.search.exception.SearchException: HSEARCH400007: Elasticsearch request failed. Request: ======== Operation: Search Data: {"query":{"filtered":{"query":{"bool":{"must":[{"bool":{"must":{"bool":{"should":[{"range":{"id.plantId":{"gte":1.0,"lte":1.0,"boost":1.0}}},{"range":{"id.plantId":{"gte":3.0,"lte":3.0,"boost":1.0}}},{"range":{"id.plantId":{"gte":4.0,"lte":4.0,"boost":1.0}}},{"range":{"id.plantId":{"gte":5.0,"lte":5.0,"boost":1.0}}},{"range":{"id.plantId":{"gte":6.0,"lte":6.0,"boost":1.0}}},{"range":{"id.plantId":{"gte":7.0,"lte":7.0,"boost":1.0}}},{"range":{"id.plantId":{"gte":10.0,"lte":10.0,"boost":1.0}}},{"range":{"id.plantId":{"gte":8.0,"lte":8.0,"boost":1.0}}},{"range":{"id.plantId":{"gte":9.0,"lte":9.0,"boost":1.0}}}]}}}},{"bool":{"must":{"bool":{"should":[{"wildcard":{"customerItemNumber":{"value":"*0*","boost":1.0}}},{"wildcard":{"customerItemNumberScrubbed":{"value":"*0*","boost":1.0}}}]}}}},{"term":{"serviceFlag":{"value":"false","boost":1.0}}}]}},"filter":{"type":{"value":"com.setech.mrovelocityhub.inventory.domain.Item"}}}},"sort":[{"_score":{"order":"desc"}}]} Response: ========= Status: 500 Error message: {"root_cause":[{"type":"query_phase_execution_exception","reason":"Result window is too large, from + size must be less than or equal to: [10000] but was [10725]. See the scroll api for a more efficient way to request large data sets. This limit can be set by changing the [index.max_result_window] index level parameter."}],"type":"search_phase_execution_exception","reason":"all shards failed","phase":"query","grouped":true,"failed_shards":[{"shard":0,"index":"com.setech.mrovelocityhub.inventory.domain.item","node":"TK1fAfSZSxyqX0rwgGKLhw","reason":{"type":"query_phase_execution_exception","reason":"Result window is too large, from + size must be less than or equal to: [10000] but was [10725]. See the scroll api for a more efficient way to request large data sets. This limit can be set by changing the [index.max_result_window] index level parameter."}}]} at org.hibernate.search.backend.elasticsearch.client.impl.JestClient.executeRequest(JestClient.java:89) at org.hibernate.search.backend.elasticsearch.client.impl.JestClient.executeRequest(JestClient.java:80) at org.hibernate.search.backend.elasticsearch.impl.ElasticsearchHSQueryImpl$IndexSearcher.runSearch(ElasticsearchHSQueryImpl.java:488) at org.hibernate.search.backend.elasticsearch.impl.ElasticsearchHSQueryImpl.execute(ElasticsearchHSQueryImpl.java:257) at org.hibernate.search.backend.elasticsearch.impl.ElasticsearchHSQueryImpl.queryResultSize(ElasticsearchHSQueryImpl.java:145) at org.hibernate.search.query.hibernate.impl.FullTextQueryImpl.getResultSize(FullTextQueryImpl.java:223) at org.hibernate.search.jpa.impl.FullTextQueryImpl.getResultSize(FullTextQueryImpl.java:98) at com.setech.mrovelocityhub.inventory.dao.internal.ItemSearchJpaRepository.find(ItemSearchJpaRepository.java:134) at com.setech.mrovelocityhub.inventory.internal.ItemSearchServiceImpl.search(ItemSearchServiceImpl.java:171) at com.setech.mrovelocityhub.inventory.internal.ItemSearchServiceImpl.search(ItemSearchServiceImpl.java:1) at sun.reflect.GeneratedMethodAccessor600.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.__invoke(DelegatingMethodAccessorImpl.java:43) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java) at java.lang.reflect.Method.invoke(Method.java:497) at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:302) at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:190) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157) at org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:99) at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:281) at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:96) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179) at org.springframework.security.access.intercept.aopalliance.MethodSecurityInterceptor.invoke(MethodSecurityInterceptor.java:68) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179) at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:208) at com.sun.proxy.$Proxy176.search(Unknown Source) at com.setech.mrovelocityhub.core.web.search.actions.SearchAction.getSearchResults(SearchAction.java:354) at com.setech.mrovelocityhub.core.web.search.actions.SearchAction.search(SearchAction.java:157) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.__invoke(DelegatingMethodAccessorImpl.java:43) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java) at java.lang.reflect.Method.invoke(Method.java:497) at ognl.OgnlRuntime.invokeMethod(OgnlRuntime.java:891) at ognl.OgnlRuntime.callAppropriateMethod(OgnlRuntime.java:1293) at ognl.ObjectMethodAccessor.callMethod(ObjectMethodAccessor.java:68) at com.opensymphony.xwork2.ognl.accessor.XWorkMethodAccessor.callMethodWithDebugInfo(XWorkMethodAccessor.java:117) at com.opensymphony.xwork2.ognl.accessor.XWorkMethodAccessor.callMethod(XWorkMethodAccessor.java:108) at ognl.OgnlRuntime.callMethod(OgnlRuntime.java:1369) at ognl.ASTMethod.getValueBody(ASTMethod.java:90) at ognl.SimpleNode.evaluateGetValueBody(SimpleNode.java:212) at ognl.SimpleNode.getValue(SimpleNode.java:258) at ognl.Ognl.getValue(Ognl.java:494) at ognl.Ognl.getValue(Ognl.java:458) at com.opensymphony.xwork2.ognl.OgnlUtil$2.execute(OgnlUtil.java:309) at com.opensymphony.xwork2.ognl.OgnlUtil.compileAndExecute(OgnlUtil.java:340) at com.opensymphony.xwork2.ognl.OgnlUtil.getValue(OgnlUtil.java:307) at com.opensymphony.xwork2.DefaultActionInvocation.invokeAction(DefaultActionInvocation.java:423) at com.opensymphony.xwork2.DefaultActionInvocation.invokeActionOnly(DefaultActionInvocation.java:287) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:250) at com.opensymphony.xwork2.interceptor.DefaultWorkflowInterceptor.doIntercept(DefaultWorkflowInterceptor.java:167) at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:98) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at com.opensymphony.xwork2.validator.ValidationInterceptor.doIntercept(ValidationInterceptor.java:265) at org.apache.struts2.interceptor.validation.AnnotationValidationInterceptor.doIntercept(AnnotationValidationInterceptor.java:76) at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:98) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at com.opensymphony.xwork2.interceptor.ConversionErrorInterceptor.intercept(ConversionErrorInterceptor.java:138) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at com.opensymphony.xwork2.interceptor.ParametersInterceptor.doIntercept(ParametersInterceptor.java:229) at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:98) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at com.opensymphony.xwork2.interceptor.ParametersInterceptor.doIntercept(ParametersInterceptor.java:229) at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:98) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at com.opensymphony.xwork2.interceptor.StaticParametersInterceptor.intercept(StaticParametersInterceptor.java:191) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at org.apache.struts2.interceptor.FileUploadInterceptor.intercept(FileUploadInterceptor.java:253) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at com.opensymphony.xwork2.interceptor.ModelDrivenInterceptor.intercept(ModelDrivenInterceptor.java:100) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at com.opensymphony.xwork2.interceptor.ChainingInterceptor.intercept(ChainingInterceptor.java:145) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at com.opensymphony.xwork2.interceptor.PrepareInterceptor.doIntercept(PrepareInterceptor.java:171) at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:98) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at org.apache.struts2.interceptor.ServletConfigInterceptor.intercept(ServletConfigInterceptor.java:164) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at com.opensymphony.xwork2.interceptor.ParametersInterceptor.doIntercept(ParametersInterceptor.java:229) at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:98) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at org.apache.struts2.interceptor.MultiselectInterceptor.intercept(MultiselectInterceptor.java:73) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at org.apache.struts2.interceptor.DateTextFieldInterceptor.intercept(DateTextFieldInterceptor.java:125) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at org.apache.struts2.interceptor.CheckboxInterceptor.intercept(CheckboxInterceptor.java:91) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at com.opensymphony.xwork2.interceptor.I18nInterceptor.intercept(I18nInterceptor.java:139) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at com.opensymphony.xwork2.interceptor.AliasInterceptor.intercept(AliasInterceptor.java:193) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at com.opensymphony.xwork2.interceptor.ExceptionMappingInterceptor.intercept(ExceptionMappingInterceptor.java:189) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at com.setech.struts2.interceptors.ConversationInterceptor.intercept(ConversationInterceptor.java:147) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at com.setech.mrovelocityhub.core.web.struts.interceptor.MenuInterceptor.doInterceptInternal(MenuInterceptor.java:67) at com.setech.mrovelocityhub.core.web.struts.interceptor.AbstractAuthenticatedInterceptor.intercept(AbstractAuthenticatedInterceptor.java:35) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at com.setech.mrovelocityhub.core.web.struts.interceptor.UnreadNotificationsInterceptor.doInterceptInternal(UnreadNotificationsInterceptor.java:73) at com.setech.mrovelocityhub.core.web.struts.interceptor.AbstractAuthenticatedInterceptor.intercept(AbstractAuthenticatedInterceptor.java:35) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at com.setech.mrovelocityhub.core.web.struts.interceptor.SiteOptionsOverrideInterceptor.intercept(SiteOptionsOverrideInterceptor.java:69) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at com.setech.mrovelocityhub.core.web.struts.interceptor.UserAgentCompatibleInterceptor.intercept(UserAgentCompatibleInterceptor.java:41) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at com.setech.mrovelocityhub.core.web.struts.interceptor.AjaxRequestAwareInterceptor.intercept(AjaxRequestAwareInterceptor.java:36) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at com.setech.mrovelocityhub.core.web.struts.interceptor.LocaleContextHolderInterceptor.intercept(LocaleContextHolderInterceptor.java:42) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at com.setech.mrovelocityhub.core.web.struts.interceptor.UserContextHolderInterceptor.intercept(UserContextHolderInterceptor.java:46) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at com.opensymphony.xwork2.interceptor.I18nInterceptor.intercept(I18nInterceptor.java:139) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at com.setech.mrovelocityhub.core.web.struts.interceptor.UserAgentTrackingInterceptor.intercept(UserAgentTrackingInterceptor.java:59) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at com.setech.mrovelocityhub.core.web.struts.interceptor.TypeConverterAwareInterceptor.intercept(TypeConverterAwareInterceptor.java:49) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at com.setech.mrovelocityhub.core.web.struts.interceptor.RequestLoggingInterceptor.intercept(RequestLoggingInterceptor.java:55) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at com.setech.mrovelocityhub.core.web.struts.interceptor.TimerInterceptor.intercept(TimerInterceptor.java:46) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244) at org.apache.struts2.impl.StrutsActionProxy.execute(StrutsActionProxy.java:54) at org.apache.struts2.dispatcher.Dispatcher.serviceAction(Dispatcher.java:564) at org.apache.struts2.dispatcher.ng.ExecuteOperations.executeAction(ExecuteOperations.java:81) at org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter.doFilter(StrutsPrepareAndExecuteFilter.java:99) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:239) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:316) at com.setech.mrovelocityhub.core.web.security.filter.PasswordChangeRequiredFilter.doFilterInternal(PasswordChangeRequiredFilter.java:78) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:330) at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:126) at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:90) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:330) at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:114) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:330) at org.springframework.security.web.session.SessionManagementFilter.doFilter(SessionManagementFilter.java:122) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:330) at org.springframework.security.web.authentication.AnonymousAuthenticationFilter.doFilter(AnonymousAuthenticationFilter.java:111) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:330) at org.springframework.security.web.servletapi.SecurityContextHolderAwareRequestFilter.doFilter(SecurityContextHolderAwareRequestFilter.java:169) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:330) at org.springframework.security.web.savedrequest.RequestCacheAwareFilter.doFilter(RequestCacheAwareFilter.java:48) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:330) at org.springframework.security.web.authentication.www.BasicAuthenticationFilter.doFilterInternal(BasicAuthenticationFilter.java:158) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:330) at org.springframework.security.web.session.ConcurrentSessionFilter.doFilter(ConcurrentSessionFilter.java:133) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:330) at org.springframework.security.web.authentication.AbstractAuthenticationProcessingFilter.doFilter(AbstractAuthenticationProcessingFilter.java:205) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:330) at org.springframework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:120) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:330) at org.springframework.security.web.header.HeaderWriterFilter.doFilterInternal(HeaderWriterFilter.java:64) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:330) at org.springframework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:91) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:330) at org.springframework.security.web.context.request.async.WebAsyncManagerIntegrationFilter.doFilterInternal(WebAsyncManagerIntegrationFilter.java:53) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:330) at org.springframework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:213) at org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:176) at org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:346) at org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:262) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:239) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:121) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:239) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:239) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:212) at org.apache.catalina.core.StandardContextValve.__invoke(StandardContextValve.java:106) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:502) at org.apache.catalina.core.StandardHostValve.__invoke(StandardHostValve.java:141) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:79) at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:616) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:88) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:518) at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1096) at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:674) at org.apache.tomcat.util.net.AprEndpoint$SocketProcessor.doRun(AprEndpoint.java:2500) at org.apache.tomcat.util.net.AprEndpoint$SocketProcessor.run(AprEndpoint.java:2489) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) at java.lang.Thread.run(Thread.java:745) {code} If I eliminate the call to {{getResultSize()}} and execute the {{getResultList()}} first, I get the same error.

    Hibernate JIRA | 9 months ago | Chris Cranford
    org.hibernate.search.exception.SearchException: HSEARCH400007: Elasticsearch request failed. Request: ======== Operation: Search Data: {"query":{"filtered":{"query":{"bool":{"must":[{"bool":{"must":{"bool":{"should":[{"range":{"id.plantId":{"gte":1.0,"lte":1.0,"boost":1.0}}},{"range":{"id.plantId":{"gte":3.0,"lte":3.0,"boost":1.0}}},{"range":{"id.plantId":{"gte":4.0,"lte":4.0,"boost":1.0}}},{"range":{"id.plantId":{"gte":5.0,"lte":5.0,"boost":1.0}}},{"range":{"id.plantId":{"gte":6.0,"lte":6.0,"boost":1.0}}},{"range":{"id.plantId":{"gte":7.0,"lte":7.0,"boost":1.0}}},{"range":{"id.plantId":{"gte":10.0,"lte":10.0,"boost":1.0}}},{"range":{"id.plantId":{"gte":8.0,"lte":8.0,"boost":1.0}}},{"range":{"id.plantId":{"gte":9.0,"lte":9.0,"boost":1.0}}}]}}}},{"bool":{"must":{"bool":{"should":[{"wildcard":{"customerItemNumber":{"value":"*0*","boost":1.0}}},{"wildcard":{"customerItemNumberScrubbed":{"value":"*0*","boost":1.0}}}]}}}},{"term":{"serviceFlag":{"value":"false","boost":1.0}}}]}},"filter":{"type":{"value":"com.setech.mrovelocityhub.inventory.domain.Item"}}}},"sort":[{"_score":{"order":"desc"}}]} Response: ========= Status: 500 Error message: {"root_cause":[{"type":"query_phase_execution_exception","reason":"Result window is too large, from + size must be less than or equal to: [10000] but was [10725]. See the scroll api for a more efficient way to request large data sets. This limit can be set by changing the [index.max_result_window] index level parameter."}],"type":"search_phase_execution_exception","reason":"all shards failed","phase":"query","grouped":true,"failed_shards":[{"shard":0,"index":"com.setech.mrovelocityhub.inventory.domain.item","node":"TK1fAfSZSxyqX0rwgGKLhw","reason":{"type":"query_phase_execution_exception","reason":"Result window is too large, from + size must be less than or equal to: [10000] but was [10725]. See the scroll api for a more efficient way to request large data sets. This limit can be set by changing the [index.max_result_window] index level parameter."}}]}

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. org.hibernate.search.exception.SearchException

      Unable to find field sponsor.profile.tag.id in nl.project.model.social.WallPost

      at org.hibernate.search.engine.spi.DocumentBuilderIndexedEntity.objectToString()
    2. Hibernate Search Engine
      ConnectedMultiFieldsTermQueryBuilder.createQuery
      1. org.hibernate.search.engine.spi.DocumentBuilderIndexedEntity.objectToString(DocumentBuilderIndexedEntity.java:674)
      2. org.hibernate.search.query.dsl.impl.FieldContext.objectToString(FieldContext.java:69)
      3. org.hibernate.search.query.dsl.impl.ConnectedMultiFieldsTermQueryBuilder.buildSearchTerm(ConnectedMultiFieldsTermQueryBuilder.java:129)
      4. org.hibernate.search.query.dsl.impl.ConnectedMultiFieldsTermQueryBuilder.createQuery(ConnectedMultiFieldsTermQueryBuilder.java:83)
      5. org.hibernate.search.query.dsl.impl.ConnectedMultiFieldsTermQueryBuilder.createQuery(ConnectedMultiFieldsTermQueryBuilder.java:64)
      5 frames
    3. nl.project.dao
      WallDaoHibernate.getSponsoredPosts
      1. nl.project.dao.hibernate.WallDaoHibernate.getSponsoredPosts(WallDaoHibernate.java:2367)
      1 frame
    4. Java RT
      Method.invoke
      1. sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      2. sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
      3. sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      4. java.lang.reflect.Method.invoke(Method.java:606)
      4 frames
    5. Spring AOP
      JdkDynamicAopProxy.invoke
      1. org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:317)
      2. org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:201)
      2 frames
    6. com.sun.proxy
      $Proxy173.getSponsoredPosts
      1. com.sun.proxy.$Proxy173.getSponsoredPosts(Unknown Source)
      1 frame
    7. nl.project.integration
      SponsoredPostTest.testSponsoredPostInvalid
      1. nl.project.integration.SponsoredPostTest.testSponsoredPostInvalid(SponsoredPostTest.java:477)
      1 frame