Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1wFGhC-004ucK-1M for pgsql-hackers@arkaria.postgresql.org; Tue, 21 Apr 2026 19:23:42 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1wFGhB-00ADGV-1m for pgsql-hackers@arkaria.postgresql.org; Tue, 21 Apr 2026 19:23:41 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1wFGhB-00ADGM-0q for pgsql-hackers@lists.postgresql.org; Tue, 21 Apr 2026 19:23:41 +0000 Received: from mail-vk1-xa2f.google.com ([2607:f8b0:4864:20::a2f]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.98.2) (envelope-from ) id 1wFGh8-00000002Lpi-3sGO for pgsql-hackers@postgresql.org; Tue, 21 Apr 2026 19:23:40 +0000 Received: by mail-vk1-xa2f.google.com with SMTP id 71dfb90a1353d-570f7bd671bso493288e0c.3 for ; Tue, 21 Apr 2026 12:23:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1776799417; x=1777404217; darn=postgresql.org; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=zHfXAHGiH9oiR89cgsj1L2KjeLNKWXyXvz4NsbGq9+U=; b=PoXSMtQdDBAcHXSe4WwzL+awtUTaSxv8po22RU12syqapTRYYLHpGS0jgMDqsLrco0 WJQFz6/pW8aaPjmdOmbLaatFZMLpxwzZtrsnG4Vvha5w6WbnVOQ5K01TKXFywysxtYmN ELKEn5JX3s/zFA63sI/8oS7360URXJb+Z+H66jSsBKrJRVsoAtAErAXBgwfRCCOUOa+n /H5/g1t5xra181bEkW3Yiux5Yrf50Xb6VX0Kpva5BaqwHSCFNyjfZMj8wZf3cBMlynU5 8PtC1r18dZgznF3YH/P7mYHiN0e0lPjEMAWYyhQFNbluVPpRZQ9FDc6NeeIrO+XnvTnN cqIw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1776799417; x=1777404217; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :x-gm-gg:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=zHfXAHGiH9oiR89cgsj1L2KjeLNKWXyXvz4NsbGq9+U=; b=XI4esRWSjgwhOsQ7HP1TeAAZuzXXr9R3KdMAjkhYe7cDKbRcfNlGx/HPtClcxIe/p3 TXIT70vXFODIw5W7oJeHbICLCtCfYaM19UszAKrk7VUU/bcICiu5ZlHLkXJ9756KldX4 AJI05qPB0dYrFyXduNje+iaJXV3K5x9OoFrPcH+gCrwG8lKJw4I9rIMNVejJOkdaWskZ VjzvJrIouc3+xtiEef6aiBb5b3+bc4bCX3umYnPsyJC6R7TpKtFtds4ztu6S2fsXBs+z jguGw6SQ2LnnKKbMGfRx9h+a0y4Ri4pEVikrLneCVjQEA81Mlom9ZNV+bG9UuoExOaiA lXCg== X-Forwarded-Encrypted: i=1; AFNElJ+aPHjWHG3ncwZIjusS30S3B5tJBehzpN3NcApgumdmZeKPOfdaLr0TI8enYmBoDJwDyVeNEFgDddEEUKE6@postgresql.org X-Gm-Message-State: AOJu0YwXi/WU4/QtLJJDyahlGLbFlY15MscAqGGpgjYLEGz3qUL2AaH5 xQrFrigp/8iVA2/qfyC9aHiEr1glFVxJUNsgCewKl0pameznbSMmzE5b X-Gm-Gg: AeBDietUd99QDLQamq9TlLtEObzb8OhZPRYtVMlgxCrm2zWS+eCH7vJLzuVOsIlAT4U kShAGvtWfYQZpGQZF71FqS/TJyD0a2FUW4aGGWOITvAJSPBs9gBvYBznFMnqFFkuwfDAj/WxGkU jxrn9Q0Ln2zqFuLJWVCHKyh4CGzMvJSBjudtxZ2rjyKnIi+eJiSKDc3cDkPPi3A4XMvQefvd+m9 S9xv8ZJrm7gkFEjJ/vEw70Rlz/xO6FjggCvtQHlKrFh9C1iuhe3opDIhJkW55F9V5HC7hSX9uQw FZVgzi7LgsPLW48ByRwSkJeRTWmxX3dBnmwRaEP6/zOCqhGg2u++dTic2LHIUoxfsKnzifowaKS 4nCxz9OMj7sWW0Z8Ba0vB2ZCY23RWu1e1fYWYoN4ioO31wStltOZuplMCh7+UNkM0CWKLUj1jsl 8lihaJmj2hUQVAT30NUtPvNXNuJf73NA3LJjSo3hmfpo97smmp4XasrVtaH6XzUooe7koZ08/TN I3hwsD9kEYbRq2N+0QrMUVWMo42Vhrw1PFbRyM+ X-Received: by 2002:a05:6122:8c8a:b0:56c:ca38:ebeb with SMTP id 71dfb90a1353d-56fa582b8cemr9837659e0c.2.1776799417061; Tue, 21 Apr 2026 12:23:37 -0700 (PDT) Received: from ?IPV6:2804:14d:328a:a59c:2991:f8b:77a7:8529? ([2804:14d:328a:a59c:2991:f8b:77a7:8529]) by smtp.gmail.com with ESMTPSA id 71dfb90a1353d-56fa93253aesm8307437e0c.14.2026.04.21.12.23.35 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 21 Apr 2026 12:23:36 -0700 (PDT) Message-ID: <271ebb35-8d8f-41c3-9d95-5c1e5b416216@gmail.com> Date: Tue, 21 Apr 2026 16:23:33 -0300 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: MERGE PARTITIONS and DEPENDS ON EXTENSION. To: Alexander Korotkov Cc: Dmitry Koval , pgsql-hackers References: <31d04a1b-c0cb-4e6f-a344-0db048a3b673@gmail.com> <414c3430-77a9-438e-9dc0-c66033f6be63@postgrespro.ru> Content-Language: en-US From: Matheus Alcantara In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 21/04/26 12:57, Alexander Korotkov wrote: > I've spotted the following things in this patch. > 1) The equality of dependencies is not fully checked. We only check > that for each new dependency, we have the same for previous partition, > but not vise versa. > 2) The complexity of dependency checking is O(n^2). > 3) Usage of citext and other extensions in src/test/regress where they > might be not available. > Oops, I forgot to replace the citext extension on split partition tests. > I've revised the patch. > 1) collectPartitionIndexExtDeps() is rewritten(). Now it works in > three phases: collect, sort, compare. The comparison phase requires > strict equivalence of dependencies and doesn't depend on the order. > The complexity is now O(n * log(n)), which I think is acceptable. > 2) PartitionIndexExtDepEntry struct now have indexOid. So, on > conflict error contains both partition index names. > 3) Tests moved to > src/test/modules/test_extensions/sql/test_extdepend.sql where > test_ext3/test_ext5 extensions are available. > 4) More tests for different scenarios. > > Could you, please, review this changes? > I think that you miss to include the patch? -- Matheus Alcantara EDB: https://www.enterprisedb.com