From solr-user-return-140870-archive-asf-public=cust-asf.ponee.io@lucene.apache.org Thu Apr 26 16:42:45 2018 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx-eu-01.ponee.io (Postfix) with SMTP id 2526D180648 for ; Thu, 26 Apr 2018 16:42:44 +0200 (CEST) Received: (qmail 8080 invoked by uid 500); 26 Apr 2018 14:42:43 -0000 Mailing-List: contact solr-user-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: solr-user@lucene.apache.org Delivered-To: mailing list solr-user@lucene.apache.org Received: (qmail 8061 invoked by uid 99); 26 Apr 2018 14:42:42 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 26 Apr 2018 14:42:42 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id CA181C0148 for ; Thu, 26 Apr 2018 14:42:41 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 1.202 X-Spam-Level: * X-Spam-Status: No, score=1.202 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, GAPPY_SUBJECT=1.312, MIME_QP_LONG_LINE=0.001, SPF_PASS=-0.001, T_RP_MATCHES_RCVD=-0.01] autolearn=disabled Authentication-Results: spamd4-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=openindex.io Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id i8LQrO3JUT8Y for ; Thu, 26 Apr 2018 14:42:39 +0000 (UTC) Received: from mail1.ams.nl.openindex.io (mail1.ams.nl.openindex.io [141.105.125.41]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTP id 2CB835F189 for ; Thu, 26 Apr 2018 14:42:39 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by mail1.ams.nl.openindex.io (Postfix) with ESMTP id 91F3E38074F for ; Thu, 26 Apr 2018 14:42:33 +0000 (UTC) Received: from mail1.ams.nl.openindex.io ([127.0.0.1]) by localhost (mail1.ams.nl.openindex.io [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id haAUIDZaSqOs for ; Thu, 26 Apr 2018 14:42:33 +0000 (UTC) Received: from mail1.ams.nl.openindex.io (localhost [127.0.0.1]) by mail1.ams.nl.openindex.io (Postfix) with ESMTP id 72C9638074B for ; Thu, 26 Apr 2018 14:42:33 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=openindex.io; s=mail; t=1524753753; bh=lCU+sbIG+HAvGRMP6K3GDO+EOEvzUKxy9u/74qjpeRY=; h=Subject:From:To:Date:From; b=FwWkPMpCoku+ehA5SwjOmAtqPE3memFTLXgOohD9ocORvAzhcdX4ynaYe9W2/yMR7 kjBGku1zRdQL+BhvwMm4gpvrrVFSr6Kp4tJAimqXK87po0FMqEvn9chvfjD1m2lLfS IWTTC6LnpeQrKfvaMNKCnwl/OhBliOkFnJ35PJfzBY1Z7U+V6uhAd6jsabosLWUmE9 tz3JI89fa0DuLF4Kkv/zsWp5vULoEFZXjJZsMB0A58QCtt82ijs4Rdw4cb7uRoHP8x R6NyffBZrPfymPhlsPz35iviF1RCL2IGZeDvGql2LyIZm0ZoEwO2OXv8MDT9YgGpvt oUMO4c3qRpIpQ== Subject: RE: ClassCastException: o.a.l.d.Field cannot be cast to o.a.l.d.StoredField From: =?utf-8?Q?Markus_Jelsma?= To: =?utf-8?Q?solr-user=40lucene=2Eapache=2Eorg?= Date: Thu, 26 Apr 2018 14:42:33 +0000 Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Priority: 3 (Normal) X-Mailer: Zarafa 7.2.1-51838 X-Original-To: Message-Id: Hello David, Yes it was sporadic indeed, but how would a DocumentTransformer affect UpdateLog replay=3F We removed the cast, no idea how it got there. Thanks, Markus =20 -----Original message----- > From:David Smiley > Sent: Thursday 26th April 2018 16:31 > To: solr-user@lucene.apache.org > Subject: Re: ClassCastException: o.a.l.d.Field cannot be cast to o.a.l.d.StoredField >=20 > I'm not sure but I wonder why you would want to cast it in the first > place. Field is the base class; all it's subclasses are in one way or > another utilities/conveniences. In other words, if you ever see code > casting Field to some subclass, there's a good chance it's fundamentally > wrong or making assumptions that aren't necessarily true. >=20 > If the problem you saw appears sporadic, there's a good chance it is in > some way related to updateLog replay. >=20 > On Tue, Apr 24, 2018 at 7:13 AM Markus Jelsma > wrote: >=20 > > Hello, > > > > We have a DocumentTransformer that gets a Field from the SolrDocument and > > casts it to StoredField (although aparently we don't need to cast). This > > works well in tests and fine in production, except for some curious, > > unknown and unreproducible, cases, throwing the ClassCastException. > > > > I can, and will, just remove the cast to fix the rare exception, but in > > what cases could the exception get thrown=3F > > > > Many thanks, > > Markus > > > --=20 > Lucene/Solr Search Committer, Consultant, Developer, Author, Speaker > LinkedIn: http://linkedin.com/in/davidwsmiley | Book: > http://www.solrenterprisesearchserver.com >=20