You can also try using the explain keyword to get introspection into how the JCR repository is planning to execute the query which may identify any traversal or index issues: https://jackrabbit.apache.org/oak/docs/query/grammar-sql2.html#explain
On Wed, Jan 22, 2020 at 12:06 PM Carlos Munoz <camu...@redhat.com> wrote: > Thanks heaps Robert, sounds like way more than I was expecting :) > > I'll try these things and let you know how it goes. > > > > On Wed, Jan 22, 2020 at 9:31 AM Robert Munteanu <romb...@apache.org> > wrote: > > > Hi Carlos, > > > > On Wed, 2020-01-22 at 07:11 -0500, Carlos Munoz wrote: > > > Thanks for the reply Robert. We are using the latest Sling release > > > (11) and > > > its corresponding bundle versions, so that would make it oak 1.8.8. > > > > > > We could proably be using more updated bundles, but without a stable > > > release or tag we're not sure how to gauge whether a set of bundles > > > is > > > stable enough. > > > > Latest released bundles as found in the current sling starter [1] > > should be stable. You could try and update to a later Oak, we have > > validated that Oak 1.16.0 works fine, see commit [2] for details. > > > > I would suggest the following: > > > > 1. Try and update to Oak 1.16.0, following commit [2] . > > 2. If that does not solve your problem, update to latest Oak (currently > > 1.22.0). If that does not work for you, let me know and we'll figure it > > out. > > 3. If that still does not work, you probably should ask in the > > Jackrabbit project. > > > > How does that sound? > > > > Thanks, > > Robert > > > > > > [1]: https://github.com/apache/sling-org-apache-sling-starter > > [2]: > > https://github.com/apache/sling-org-apache-sling-starter/commit/c4f6e3b > > > > > > Regards, > > > > > > Carlos > > > > > > > > > On Wed, Jan 22, 2020 at 4:47 AM Robert Munteanu <romb...@apache.org> > > > wrote: > > > > > > > Hi Carlos, > > > > > > > > On Tue, 2020-01-21 at 22:31 -0500, Carlos Munoz wrote: > > > > > Hi, > > > > > > > > > > My team is using Sling for an internal application and we've run > > > > > into > > > > > a > > > > > couple of unexpected scenarios: > > > > > > > > > > 1. When modifying the nodetypes.cnd file included with our bundle > > > > > (e.g. > > > > > adding a new node type), the application queries seem to stop > > > > > working. This > > > > > only happens when the queries use the following form: "select * > > > > > from > > > > > [custom:type] ..." and not when using something like "select * > > > > > from > > > > > [nt:base] where [jcr:primaryType] = 'custom:type'" > > > > > > > > > > 2. There is a specific query which runs very slowly only the > > > > > first > > > > > time it > > > > > is executed. Once it is executed that one time it runs > > > > > considerably > > > > > faster > > > > > on subsequent runs. > > > > > > > > These both look like Jackrabbit/Oak issues, so first let me ask you > > > > which version of Jackrabbit/Jackrabbit Oak are you using? > > > > > > > > Thanks, > > > > Robert > > > > > > > > > I was wondering if the Sling community would be able to shed some > > > > > light on > > > > > some possible causes to these two scenarios. > > > > > > > > > > Thanks in advance! > > > > >