Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bfzcZ-0007QX-Mq for pgsql-hackers@arkaria.postgresql.org; Sat, 03 Sep 2016 01:19:47 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1bfzcY-0007NS-TG for pgsql-hackers@arkaria.postgresql.org; Sat, 03 Sep 2016 01:19:46 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1bfzbB-0005qk-1r for pgsql-hackers@postgresql.org; Sat, 03 Sep 2016 01:18:21 +0000 Received: from mail-wm0-x233.google.com ([2a00:1450:400c:c09::233]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.84_2) (envelope-from ) id 1bfzb3-0004Nu-LV for pgsql-hackers@postgresql.org; Sat, 03 Sep 2016 01:18:19 +0000 Received: by mail-wm0-x233.google.com with SMTP id v143so54940222wmv.0 for ; Fri, 02 Sep 2016 18:18:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=2ndquadrant-com.20150623.gappssmtp.com; s=20150623; h=subject:to:references:cc:from:message-id:date:user-agent :mime-version:in-reply-to:content-transfer-encoding; bh=BybyEFwDZZ91tVodESWXmxO4IH+ezQhXUI0emOqZeFg=; b=OHqFrvz8eZWWGZJ8V1t+TrrfCChUSPMXtD2Vl6LKq76EgtbGI+JJir5Ou+vnYzB1tH sHR+Jvm/ELnR2gRmyl+N/xFM93Pm/IOe1z9VlwGQX50Sl01dKWZul3d1XzSmiqABX38b ih/idbekWp5KTHXn3BAZpNVL7pVJPx7+uWV/gG1rHWaT8HAJz4Pygga7cRGDG+IfGZyY rdL9o0sNazNkQUupHXUt52iC9CZW9D3qf8W9b0yHVAAMVkC1EOvVDR8HJAz8oRY2YAl8 mARE4q/NHbJAi+8bxXh/yXA2OyrH9eJ2+rpQTjarAwJcw1R1+SQImmGqrt6U9bRubHKC rMVw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:subject:to:references:cc:from:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding; bh=BybyEFwDZZ91tVodESWXmxO4IH+ezQhXUI0emOqZeFg=; b=NK4In81v0RCFLjpjEMfG78rWnsQpmGqERgK16ztuPMonHMG8UcOSul50eHhc213MZE lI8rH1FAunR+ccNVb7V/7UIuXAJWq91QPhG7HoESdC1ZA3pKE+pDSW916tPM+UIjnr9R qpfi8sADflotQIUz+rQmOIt6GbIyIxRl1nGL1S4FhzbcEODMKl9TxUXEWIVdksuyVnsZ HIjkG+gt/4W+S5/bInepYDjRnqS3UrQJPFpSsJEX2KtLioM81Fq1Vcc5U7LK+oCbMZV3 0Kg2hBkU9I1q9qlQsGaqR9ycFlpl84GAwhOxIGc+drxX9LyZXxjT7w5SQ+pk8KjyaAH0 rk+g== X-Gm-Message-State: AE9vXwNYnnVMVc56y/G5uxI9bSdCK+qyIhmS4gRA+uj3QO7NIE01jQ76p0cpZXrrQ4w/m0A/EEFVj1+OLWEIwn900un0fwHoykYbUnq4/fMvwT6Vn5gWUtImmuuxbGbQqCkjWzwEaIV3IDN4zCfFEreOg9JLBmoHlGpxsL57xYxZaGBeWLHhHCmyU+hbmBYvpFf7cgCZGIS6 X-Received: by 10.28.207.14 with SMTP id f14mr2857404wmg.40.1472865486977; Fri, 02 Sep 2016 18:18:06 -0700 (PDT) Received: from [10.137.2.17] (ip-89-177-44-58.net.upcbroadband.cz. [89.177.44.58]) by smtp.gmail.com with ESMTPSA id bj8sm12882638wjc.49.2016.09.02.18.18.05 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 02 Sep 2016 18:18:06 -0700 (PDT) Subject: Re: pg_dump / copy bugs with "big lines" ? To: Craig Ringer , Daniel Verite References: <20160318154830.GA94538@alvherre.pgsql> Cc: Alvaro Herrera , Tom Lane , Robert Haas , Jim Nasby , Ronan Dunklau , pgsql-hackers From: Tomas Vondra Message-ID: <5aafa6a9-e49c-ab13-be67-c68f34986801@2ndquadrant.com> Date: Sat, 3 Sep 2016 03:18:04 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:46.0) Gecko/20100101 Thunderbird/46.0a2 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-Pg-Spam-Score: -2.6 (--) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-hackers Precedence: bulk Sender: pgsql-hackers-owner@postgresql.org On 09/03/2016 02:21 AM, Tomas Vondra wrote: > > A few minor comments regarding the patch: > > 1) CopyStartSend seems pretty pointless - It only has one function call > in it, and is called on exactly one place (and all other places simply > call allowLongStringInfo directly). I'd get rid of this function and > replace the call in CopyOneRowTo(() with allowLongStringInfo(). > > 2) allowlong seems awkward, allowLong or allow_long would be better > > 3) Why does resetStringInfo reset the allowLong flag? Are there any > cases when we want/need to forget the flag value? I don't think so, so > let's simply not reset it and get rid of the allowLongStringInfo() > calls. Maybe it'd be better to invent a new makeLongStringInfo() method > instead, which would make it clear that the flag value is permanent. > > 4) HandleParallelMessage needs a tweak, as it uses msg->len in a log > message, but with '%d' and not '%ld' (as needed after changing the type > to Size). > 5) The comment at allowLongStringInfo talks about allocLongStringInfo (i.e. wrong function name). regards -- Tomas Vondra http://www.2ndQuadrant.com PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers