Return-Path: X-Original-To: apmail-jackrabbit-dev-archive@www.apache.org Delivered-To: apmail-jackrabbit-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 369D7347C for ; Wed, 4 May 2011 21:23:49 +0000 (UTC) Received: (qmail 33124 invoked by uid 500); 4 May 2011 21:23:48 -0000 Delivered-To: apmail-jackrabbit-dev-archive@jackrabbit.apache.org Received: (qmail 33078 invoked by uid 500); 4 May 2011 21:23:48 -0000 Mailing-List: contact dev-help@jackrabbit.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@jackrabbit.apache.org Delivered-To: mailing list dev@jackrabbit.apache.org Received: (qmail 33071 invoked by uid 99); 4 May 2011 21:23:48 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 04 May 2011 21:23:48 +0000 X-ASF-Spam-Status: No, hits=-2.3 required=5.0 tests=RCVD_IN_DNSWL_MED,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of aklimets@adobe.com designates 64.18.1.35 as permitted sender) Received: from [64.18.1.35] (HELO exprod6og115.obsmtp.com) (64.18.1.35) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 04 May 2011 21:23:41 +0000 Received: from outbound-smtp-1.corp.adobe.com ([192.150.11.134]) by exprod6ob115.postini.com ([64.18.5.12]) with SMTP ID DSNKTcHDx32ueX9jL4JpnAOXTpwA/5+M67eg@postini.com; Wed, 04 May 2011 14:23:20 PDT Received: from inner-relay-4.eur.adobe.com (inner-relay-4.adobe.com [193.104.215.14]) by outbound-smtp-1.corp.adobe.com (8.12.10/8.12.10) with ESMTP id p44LMKES012123 for ; Wed, 4 May 2011 14:22:21 -0700 (PDT) Received: from nacas01.corp.adobe.com (nacas01.corp.adobe.com [10.8.189.99]) by inner-relay-4.eur.adobe.com (8.12.10/8.12.9) with ESMTP id p44LNG1R020790 for ; Wed, 4 May 2011 14:23:17 -0700 (PDT) Received: from eurcas01.eur.adobe.com (10.128.4.27) by nacas01.corp.adobe.com (10.8.189.99) with Microsoft SMTP Server (TLS) id 8.3.137.0; Wed, 4 May 2011 14:23:16 -0700 Received: from eurmbx01.eur.adobe.com ([10.128.4.32]) by eurcas01.eur.adobe.com ([10.128.4.27]) with mapi; Wed, 4 May 2011 22:23:14 +0100 From: Alexander Klimetschek To: "dev@jackrabbit.apache.org" Date: Wed, 4 May 2011 22:23:11 +0100 Subject: Re: is doc addition / indexing synchronous or asynchronous? Thread-Topic: is doc addition / indexing synchronous or asynchronous? Thread-Index: AcwKoXobmEoMGna9Qd+9XVR8fmnXoA== Message-ID: In-Reply-To: <5FBB5FB921F28142B2BC6685307807FF011C45B4@Falcon.inmedius.com> Accept-Language: de-DE, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: user-agent: Microsoft-MacOutlook/14.10.0.110310 acceptlanguage: de-DE, en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Virus-Checked: Checked by ClamAV on apache.org On 04.05.11 22:38, "Dolan, Kelly" wrote: >If I modify SearchManager such that it >implements EventListener as opposed to SynchronousEventListener indexing >now occurs >in a background thread. If I proceed with such a change, will this break >anything in Jackrabbit? i.e., is there any operation that modifies the >repository, immediately does a search and expects to find what was just >added >and if it does not, fails? I don't know that exact part of the search index implementation to judge what this change will do, but I think this would break 6.5 "Search Scope" from the JCR spec [0]: "A query must search the persistent workspace associated with the current session. It may take into account pending changes to the persistent workspace; that is, changes which are either unsaved or, within a transaction, saved but uncommitted." That means, as soon save() returns (=3D=3D persisted), the index should be = up to date. This might be important for certain applications that for example change something, save it and then run a search again to update the view - this scenario would be broken and the app would have no information how long to wait until the search index is up to date. [0] http://www.day.com/specs/jcr/2.0/6_Query.html#6.5%20Search%20Scope Regards, Alex --=20 Alexander Klimetschek Developer // Adobe (Day) // Berlin - Basel