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 123C5200B11 for ; Mon, 13 Jun 2016 11:34:15 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 10C8D160A3C; Mon, 13 Jun 2016 09:34:15 +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 30F73160A19 for ; Mon, 13 Jun 2016 11:34:14 +0200 (CEST) Received: (qmail 71659 invoked by uid 500); 13 Jun 2016 09:34:13 -0000 Mailing-List: contact dev-help@manifoldcf.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@manifoldcf.apache.org Delivered-To: mailing list dev@manifoldcf.apache.org Received: (qmail 71646 invoked by uid 99); 13 Jun 2016 09:34:13 -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; Mon, 13 Jun 2016 09:34:13 +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 A2E48C06C9 for ; Mon, 13 Jun 2016 09:34:12 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -0.571 X-Spam-Level: X-Spam-Status: No, score=-0.571 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_ENVFROM_END_DIGIT=0.25, 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: spamd4-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx2-lw-us.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id YkUCvGulRJ7x for ; Mon, 13 Jun 2016 09:34:11 +0000 (UTC) Received: from mail-oi0-f45.google.com (mail-oi0-f45.google.com [209.85.218.45]) by mx2-lw-us.apache.org (ASF Mail Server at mx2-lw-us.apache.org) with ESMTPS id D8CCF5F4E3 for ; Mon, 13 Jun 2016 09:34:10 +0000 (UTC) Received: by mail-oi0-f45.google.com with SMTP id u201so72119119oie.0 for ; Mon, 13 Jun 2016 02:34:10 -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 :content-transfer-encoding; bh=bhf+5b1CRUzzMxh11mQyGYVkzCmb3/bI6ynDe25NQA4=; b=CGvfRDnesj6LZES11BAke2u9KzY4G5hG33HL5qHV3faFQh4kQ3/4bBrfq926qJ+8EZ kJmLpGGRT632DI/HXm15MnupbpHpCQC0I1s46UqsJvNkyZkAngWVRoqVDc5hTBpyfvX6 JzMu9wjwmfF041IemDGxhlYTx2RgzhQurv9neKwqLzAD9IiH4TVYGYY0fBr9md0aU0Hs 2EGfA22KLhppmgeyR14dC18mFiB/xJcgC/jX+iTZ80MHkckGs3VNpUK9CzZ+6QqmVEmN fLA3p1HuWAFYilZ67pmBbVDud8R8cDJLAWMZtFOLTa1ZFjNNdUAO0Ukrzi68+U1En+V4 q+Ag== 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:content-transfer-encoding; bh=bhf+5b1CRUzzMxh11mQyGYVkzCmb3/bI6ynDe25NQA4=; b=lWw9x4AzIT1SqUiAGdGhfVVp3k8bQum71K0Gs9kO7R79z10ZYVeZa5X+fSHf7+m66w LJ4ZwDwIvgEn3xZL/srT0EidaEaaJAc1lhkKFHtl2O1wLcv7b6IalGhujkSe7LbYeNlZ rJ7yfXsxSp6UKf2RrqRSk2QgOflsgOUI3Z39sB9KRzXRiqz/3fCLKUFmZvYYpoUbjqlM hmMAsGX39EVMRLrAtZa06CwAtH0wdsvMKEycmsgmAf40UdBX3hcICDQRdDLBYYPzFSsh l91PLn3xv+VSsQTeSeDpsMXxI8Nu8/TL2qSmPd9SmlOcm2Tpeti0ewzaqAcg12cLiRvc X7yA== X-Gm-Message-State: ALyK8tJWKHPZh2dC0WabdvMpPT9565aVE4vPqW/aRZ61uOoIn2we+5EYIn7vpIkgtaaMz+z7nw4/mbU/c6mpZQ== X-Received: by 10.202.197.11 with SMTP id v11mr3094068oif.187.1465810449738; Mon, 13 Jun 2016 02:34:09 -0700 (PDT) MIME-Version: 1.0 Received: by 10.157.53.113 with HTTP; Mon, 13 Jun 2016 02:34:09 -0700 (PDT) In-Reply-To: References: From: Tomoko Uchida Date: Mon, 13 Jun 2016 18:34:09 +0900 Message-ID: Subject: Re: SQLException "value too long for type character varying(64)" while deleting documents To: dev@manifoldcf.apache.org Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable archived-at: Mon, 13 Jun 2016 09:34:15 -0000 And some additional information are here. I use ManifoldCF 2.2. > (1) Which underlying database are you using? I use PostgreSQL 9.4.5 > (2) Have you modified the MCF schema in any way? No. I did not modify any MCF db schema. > (3) What are the actual names of the output connections in question? For example, a job has 8 outputs below. There are other jobs that cannot be deleted by same reason. - ds_solr_forum_en-eu - ds_solr_forum_en-in - ds_solr_forum_en-sg - ds_solr_forum_en-us - ds_solr_forum_ko-kr_en - ds_solr_forum_zh-cn_en - ds_solr_forum_zh-tw_en - ds_solr_forum_pt-br_en For business requirements, I crawl a web site and post to multiple (eight) solr cores. Whole job definition is below (I deleted seeds/includes/excludes URLs from the original json data): { "job": { "description": "ds_forum_en", "document_specification": { "excludes": =E2=80=9C=E2=80=A6=E2=80=9D, "excludescontentindex": "", "excludesindex": "", "includes": =E2=80=9C=E2=80=A6=E2=80=9D, "includesindex": ".*", "limittoseeds": { "_attribute_value": "true", "_value_": "" }, "seeds": =E2=80=9C=E2=80=A6=E2=80=9D }, "expiration_interval": "infinite", "hopcount_mode": "accurate", "id": "1464673266530", "pipelinestage": [ { "stage_connectionname": "ds_solr_forum_en-eu", "stage_id": "0", "stage_isoutput": "true", "stage_specification": {} }, { "stage_connectionname": "ds_solr_forum_en-in", "stage_id": "1", "stage_isoutput": "true", "stage_specification": {} }, { "stage_connectionname": "ds_solr_forum_en-sg", "stage_id": "2", "stage_isoutput": "true", "stage_specification": {} }, { "stage_connectionname": "ds_solr_forum_en-us", "stage_id": "3", "stage_isoutput": "true", "stage_specification": {} }, { "stage_connectionname": "ds_solr_forum_ko-kr_en", "stage_id": "4", "stage_isoutput": "true", "stage_specification": {} }, { "stage_connectionname": "ds_solr_forum_zh-cn_en", "stage_id": "5", "stage_isoutput": "true", "stage_specification": {} }, { "stage_connectionname": "ds_solr_forum_zh-tw_en", "stage_id": "6", "stage_isoutput": "true", "stage_specification": {} }, { "stage_connectionname": "ds_solr_forum_pt-br_en", "stage_id": "7", "stage_isoutput": "true", "stage_specification": {} } ], "priority": "5", "recrawl_interval": "86400000", "repository_connection": "ds_forum_en", "reseed_interval": "3600000", "run_mode": "continuous", "start_mode": "manual" } } Thank you, Tomoko 2016-06-13 18:09 GMT+09:00 Tomoko Uchida : > Hi Karl, > > Thank you for rapid response! I'll try the patch soon. > > Regards, > Tomoko > > 2016-06-13 16:20 GMT+09:00 Karl Wright : >> Ok, some further exploration yields the following: >> (1) A check was put into the code a while ago to prevent overly long >> activity names from blowing things up. That is why we no longer see thi= s >> problem. >> (2) There was a problem with activity logging for deletions across multi= ple >> output connections. See CONNECTORS-1323. I've provided a patch. >> >> Karl >> >> >> On Mon, Jun 13, 2016 at 1:55 AM, Karl Wright wrote: >> >>> Hi Tomoko, >>> >>> Sorry, I missed this post when it was originally made. >>> >>> The activitytype column is provided by the framework for only a small >>> number of specific events. In no case does the activitytype contain >>> anything other than a fixed-length string; it's meant to be queried on. >>> That string may include the name of a single output connection or of a >>> transformation connection, but only one. The maximum length of an outp= ut >>> or transformation connection name is 32, so the total length available = for >>> the rest of the activitytype column is 30. >>> >>> The string "document deletion" is 17 characters, so that's nowhere near >>> the limit here. So this makes no sense. >>> >>> Can you be more specific about the following: >>> >>> (1) Which underlying database are you using? >>> (2) Have you modified the MCF schema in any way? >>> (3) What are the actual names of the output connections in question? >>> >>> Thanks, >>> Karl >>> >>> >>> >>> >>> On Sun, Jun 12, 2016 at 10:42 PM, Tomoko Uchida < >>> tomoko.uchida.1111@gmail.com> wrote: >>> >>>> Hi, any suggestions? >>>> >>>> Is this a known limitation, or >>>> should I create a ticket about that? >>>> >>>> Thanks, >>>> Tomoko >>>> >>>> 2016-06-09 10:44 GMT+09:00 Tomoko Uchida : >>>> > Hello developers, >>>> > >>>> > I have sent same message to the user mailing list but there are no >>>> > reply. Could anyone help me? >>>> > Some jobs in our customer production environment no longer cannot be >>>> > deleted for this problem. >>>> > >>>> > We are looking for solutions to delete the jobs safely. >>>> > If my question was not clear, I am ready to provide more detailed >>>> explanation. >>>> > >>>> > ---- >>>> > >>>> > Hello, >>>> > I encountered an SQLException when I deleted a job with many output >>>> connections. >>>> > >>>> > ERROR 2016-06-02 09:41:49,492 (Document delete thread '9') - Documen= t >>>> > delete thread aborting and restarting due to database connection >>>> > reset: Database exception: SQLException doing query (22001): ERROR: >>>> > value too long for type character varying(64) >>>> > >>>> > >>>> > I've found that the error occurred because of ManifoldCF trying to >>>> > insert long string (more than 64 characters) to 'activitytype' colum= n >>>> > of 'repohistory' table while deleting documents associated with the >>>> > job. >>>> > >>>> > For a trial, I altered 'activitytype' column type to 'text' by this >>>> > sentence. >>>> > >>>> > ALTER TABLE repohistory ALTER COLUMN activitytype TYPE text; >>>> > >>>> > After altering the table I restarted ManifoldCF then the deletion >>>> > histories was successfully added and the job seemed to be safely >>>> > deleted. >>>> > >>>> > Inserted 'activitytype' values are like this: >>>> > document deletion (outputA) (outputB) (outputC) (outputD) (outputE= ) >>>> ... >>>> > >>>> > For application requirements, I cannot limit the number of output >>>> > connectors (to shorten history records.) >>>> > >>>> > Is that OK? Or there are good solutions for that? >>>> > >>>> > Thank you in advance, >>>> > Tomoko >>>> >>> >>>