Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id B9EFB200B7D for ; Sat, 10 Sep 2016 15:15:05 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id B88A8160ABE; Sat, 10 Sep 2016 13:15:05 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id D96EA160AB2 for ; Sat, 10 Sep 2016 15:15:04 +0200 (CEST) Received: (qmail 12681 invoked by uid 500); 10 Sep 2016 13:15:03 -0000 Mailing-List: contact dev-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@lucene.apache.org Delivered-To: mailing list dev@lucene.apache.org Received: (qmail 12669 invoked by uid 99); 10 Sep 2016 13:15:03 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd3-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 10 Sep 2016 13:15:03 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd3-us-west.apache.org (ASF Mail Server at spamd3-us-west.apache.org) with ESMTP id 1CE9C18061E for ; Sat, 10 Sep 2016 13:15:03 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd3-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -0.821 X-Spam-Level: X-Spam-Status: No, score=-0.821 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_PASS=-0.001] autolearn=disabled Authentication-Results: spamd3-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd3-us-west.apache.org [10.40.0.10]) (amavisd-new, port 10024) with ESMTP id K_cCTMyThZNL for ; Sat, 10 Sep 2016 13:15:00 +0000 (UTC) Received: from mail-oi0-f46.google.com (mail-oi0-f46.google.com [209.85.218.46]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTPS id B80AF5FE5C for ; Sat, 10 Sep 2016 13:14:59 +0000 (UTC) Received: by mail-oi0-f46.google.com with SMTP id q188so88430475oia.3 for ; Sat, 10 Sep 2016 06:14:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to; bh=aKpt/ZiOgTdIoYqkdJ5BIyRgPEQGOPv8kvb0Z1XLcns=; b=Zd/8innUZOiIvNWUyjKzkFUmaPJGe0oA19WEiXTufhLhENYnJ/YxgVz24JHotqYAl/ zSGyaxhfYncIvEfJhPXOpDv6h7FrxAGMLuZBIyzeilxmdbHj+L68TZgtPnPPl4kuotbS xGPZNwVqqK6OWGHO0GxONbqZKwYdUWuU/aMgtPGn6cP9+3VpcuL4DtZjoGyfrO/VSrwj u2A+9yabVRLB12JV7knwAPcbjQnDIiZ84PzocDsfiPVQMfhb3bJanGA5lMV+BmHwLA0z HnqrLUZf5VStSQB+HByJPnlNpdwtQZmmRndLmcZmoubp/yop3TA3Mj1oq4Wfd0inKeh+ 7Etg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to; bh=aKpt/ZiOgTdIoYqkdJ5BIyRgPEQGOPv8kvb0Z1XLcns=; b=Qqnt3mvgWuozY23VFOtQ/F5Q0NzzZH3cx7a6p7lPo3Ve/IjEoY4b0ZwGXgtDt6k96A BppYRW/Ecl0TuHYWUsmsla1DRCutBJsb9UqQ+lYnm0c+PEWEg7yjmvyCSez4JfuF2RqX 1I8jV9ygEk+9LgyZsMeDOqvySaNRB2scSE/Uutc+VCQxFRmPkr+jpnfxHzUkmC9pISSx tAITvOFhdvDZlkLGxRZWGyt5R5nWyhOhR56yxN/tMMcPTTzdBUvyb8DTqXb+X/pmHfHR jVBb09kb3iAUCEzMWgWVPgyn6WelAgSf7Xy3F94ZqOBCTfpOG5mO/fcbhR8KLJlNLPqu UgQQ== X-Gm-Message-State: AE9vXwNhWVdJsAQGlvSrGRpwiGgMWunx9TpvRZ8H/Uza2gwO30SSdXi4C5wWZbHVMf643uYIqihLxXQVjrGHBQ== X-Received: by 10.202.224.196 with SMTP id x187mr13001638oig.13.1473513298336; Sat, 10 Sep 2016 06:14:58 -0700 (PDT) MIME-Version: 1.0 Received: by 10.50.114.234 with HTTP; Sat, 10 Sep 2016 06:14:17 -0700 (PDT) In-Reply-To: References: From: Alexandre Rafalovitch Date: Sat, 10 Sep 2016 20:14:17 +0700 Message-ID: Subject: Re: Request for sanity check: SOLR-9477 (UpdateRequestProcessors ignore child documents) To: dev@lucene.apache.org Content-Type: text/plain; charset=UTF-8 archived-at: Sat, 10 Sep 2016 13:15:05 -0000 Only AddSchemaFieldsUpdateProcessorFactory deals with the children. None others do. So, I am looking at this and as a first group I am looking at DefaultValue URPs, of which we have 3: * DefaultValueUpdateProcessorFactory * TimestampUpdateProcessorFactory * UUIDUpdateProcessorFactory Of those, UUIDUpdateProcessorFactory - to me - should always apply on all levels. Mikhail said we need a paradigm shift on the whole ID thing, but while we wait for that, we need to assign those unique IDs or see the import fail. On the other hand, both Timestamp and DefaultValue URPs are more complex as they both actually create a field. With timestamp, it seems that applying it universally would mean it would be on all nested documents, however many levels down. Seems redundant. Default value URP is more complex again - the 'price' element given in the example could be in a parent or in a child. Or in a grandchild. And may not make sense on the other levels. What's the best way to deal with that? Obviously, this discussion applies to all of the URPs, I am just using concrete example here to make the discussion more concrete. Regards, Alex. ---- Newsletter and resources for Solr beginners and intermediates: http://www.solr-start.com/ On 7 September 2016 at 22:01, David Smiley wrote: > I think we need to document which URPs apply to child docs (if any) and > otherwise say that, unless otherwise noted, URPs only apply to the root doc. > > It would be nice if one could simply configure at the URP declaration if it > applies to children only, root doc only, or both. I figure *most* URPs > don't need internal coding to pick. If users could pick at the declaration > to which it applies, we might then also want the ability for some URPs to > declare that they only work with root docs and then Solr could give you a > helpful error if you misuse it. > > ~ David > > On Wed, Sep 7, 2016 at 4:38 AM Alexandre Rafalovitch > wrote: >> >> On 7 September 2016 at 11:52, Mikhail Khludnev wrote: >> >> *) Do we need to document this as a limitation? >> > >> > Yes. Sure. But it's nowhere promised that update processors are applied >> > on >> > children. >> I feel this violates the expectation of least surprise. For example, I >> have discovered this issue by creating a sample dataset that ended-up >> with a blank Date field in the child record. So, I figured this is >> easy to fix Solr side by just adding RemoveBlankField URP. And.... it >> did not work. Took me an hour to figure out that _none_ of the URPs >> work at all. More importantly, it means we have no solutions for the >> child documents for all those problems we solved over time with URPs. >> Which we need to document and/or fix. >> >> >> *) Do we need to fix it individually or there is a smart way to do it >> >> centrally? >> >> > Probably yes, but I prefer to aim someones real life challenge, than >> > solve an abstract >> > common sense problem. eg. >> > how to apply a processor to children only but not to parent? Another >> > case is ID generation >> > - it's often required >> > to generate it for parent but then implicitly propagate to children, but >> > it requires paradigm >> > shift: >> > uniqueKey should be assigned on a block not a single document. This will >> > fix when >> > childless docs are mixed with blocks, etc. >> > Perhaps, it make sense to create a processed which applies a certain >> > chain of processors >> > to children docs only? >> >> Ok, these are interesting questions that can apply to specific URPs. >> This suggests to me that each one (or each group) should be deal with >> separately. >> >> > Frankly speaking, block support are yet raw, and this limitation is not >> > considered >> > significant at comparison with other ones. >> >> Well, we support them in XML, JSON, DIH, queries, etc. It may be raw >> but it is usable and people are using it. So - to me - it is a valid >> issue and worth thinking about. >> >> Regards, >> Alex. >> ---- >> Newsletter and resources for Solr beginners and intermediates: >> http://www.solr-start.com/ >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org >> For additional commands, e-mail: dev-help@lucene.apache.org >> > -- > Lucene/Solr Search Committer, Consultant, Developer, Author, Speaker > LinkedIn: http://linkedin.com/in/davidwsmiley | Book: > http://www.solrenterprisesearchserver.com --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org For additional commands, e-mail: dev-help@lucene.apache.org