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.94.2) (envelope-from ) id 1qML36-002APK-TC for pgsql-hackers@arkaria.postgresql.org; Thu, 20 Jul 2023 04:13:56 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1qML34-00GriN-H4 for pgsql-hackers@arkaria.postgresql.org; Thu, 20 Jul 2023 04:13:54 +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.94.2) (envelope-from ) id 1qML34-00GriF-7R for pgsql-hackers@lists.postgresql.org; Thu, 20 Jul 2023 04:13:54 +0000 Received: from mail-lj1-x22f.google.com ([2a00:1450:4864:20::22f]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1qML2z-000ZSH-UO for pgsql-hackers@lists.postgresql.org; Thu, 20 Jul 2023 04:13:53 +0000 Received: by mail-lj1-x22f.google.com with SMTP id 38308e7fff4ca-2b8392076c9so4437031fa.1 for ; Wed, 19 Jul 2023 21:13:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1689826430; x=1692418430; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=x24WBd2bcDsI2k2uA9+fE7ej9BE7x5x8v62mT3BeDBo=; b=f9Rzctn9TGfuuCSljYwEdGlpq53eQhx1HFRuz4W7lBNcHLrz3NFaTxgY55GZTXubIk HEIsnYE/uEmDxd7Yy5oweiw2+nmYl4f6Vb2XkRJfDn8YW2LCmiMoOe5P5BCDDvVqMpyU RuBo097sU/Lla1ku/CfxJ7aWvcrTmuan1ohzN569pSpScxcEf9heyWAMQ/kn+SmUnn08 culxILqPYso0yMfEB+4TUnKfBdSAYghtoX0cCiq8joVjF+B7Sh68QqlK/x9qoEhm+JyG ICzyBoJYPHvHTTp94Y00IwJdvqB7Utw5SZh0BsAo+zAAeI7z65/WjjLHEmLAvcidd32E hJlw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1689826430; x=1692418430; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=x24WBd2bcDsI2k2uA9+fE7ej9BE7x5x8v62mT3BeDBo=; b=LEvk4TG6U1U2gfcll9YtEqvefF/mYgZBawEWM+QpIcldk5fWogd1RE54E8ZKw4huwy PbjfDWG+GP8vViy+iIjtCCBPtB7P9fHFoDT3XAhCLzsrSF0haztbOYniJgsulrbNf1Ts Qdkc4h01wsubaE+/dcax+/o55FYbUk59I2qy3cMKACUiWgDmN0ZYTaC0/a/j4lpUHOTq 7Ik+YrluSPo7wQGKkwZ8yc9qIZjyweDtR09rpwMA7Uwjh5NKz1LMEOtuseExGShlmHyJ y94Sw9HyWKtcHv7uyn7XhZo96HjBA4jg8PymAYig3BWhrTGZUBbsNkYa+UpxoX6BsqoR 5HHQ== X-Gm-Message-State: ABy/qLaHVn79I/qa5+OqZ76h/UI6rwKXN89Ub+bE0SNkyN1ZgtYMXpP0 iAf998FmDeK15okNrTZyWx8LP/av8Zb9TLqTszj6tE+X1j8= X-Google-Smtp-Source: APBJJlGq8jjfvjiQ27uG1SwI4X/7/KzkjvRx8oAzpuwMSc8j9sUQvTXjjNQJkIvfCNFWUlgA+CbD/7F7T4aX3cRtZ6g= X-Received: by 2002:a2e:8194:0:b0:2b9:5d2e:7f9 with SMTP id e20-20020a2e8194000000b002b95d2e07f9mr908654ljg.29.1689826429880; Wed, 19 Jul 2023 21:13:49 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Bharath Rupireddy Date: Thu, 20 Jul 2023 09:43:37 +0530 Message-ID: Subject: Re: Support worker_spi to execute the function dynamically. To: Michael Paquier Cc: Masahiro Ikeda , pgsql-hackers@lists.postgresql.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Thu, Jul 20, 2023 at 9:25=E2=80=AFAM Michael Paquier wrote: > > > In my understanding, the restriction is not required. So, I think it's > > better to change the behavior. > > (v1-0001-Support-worker_spi-to-execute-the-function-dynamical.patch) > > > > What do you think? > > +1. I'm OK to lift this restriction with a SIGHUP GUC for the > database name and that's not a pattern to encourage in a template > module. Will do so, if there are no objections. +1. However, a comment above helps one to understand why some GUCs are defined before if (!process_shared_preload_libraries_in_progress). As this is an example extension, it will help understand the reasoning better. I know we will it in the commit message, but a direct comment helps: /* * Note that this GUC is defined irrespective of worker_spi shared libr= ary * presence in shared_preload_libraries. It's possible to create the * worker_spi extension and use functions without it being specified in * shared_preload_libraries. If we return from here without defining th= is * GUC, the dynamic workers launched by worker_spi_launch() will keep * crashing and restarting. */ --=20 Bharath Rupireddy PostgreSQL Contributors Team RDS Open Source Databases Amazon Web Services: https://aws.amazon.com