Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1loSXA-00048P-PG for pgsql-hackers@arkaria.postgresql.org; Wed, 02 Jun 2021 15:11:52 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1loSX9-0001SI-N0 for pgsql-hackers@arkaria.postgresql.org; Wed, 02 Jun 2021 15:11:51 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1loSX9-0001RI-5Y for pgsql-hackers@lists.postgresql.org; Wed, 02 Jun 2021 15:11:51 +0000 Received: from mail-qk1-x741.google.com ([2607:f8b0:4864:20::741]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1loSX2-0001Tz-MM for pgsql-hackers@lists.postgresql.org; Wed, 02 Jun 2021 15:11:50 +0000 Received: by mail-qk1-x741.google.com with SMTP id c20so2702723qkm.3 for ; Wed, 02 Jun 2021 08:11:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=joeconway.com; s=google; h=to:cc:references:from:subject:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=0/ywTBh9vVtj/O9hBacDbDslP+49GsVfBx0ndsXXJ9o=; b=XsUUEU5veQoOrCfELs8d87cKOKo6sD9RykkJ+oLAXX9cyQk3v2wsLHAiQT5i5GK8m5 EWKNakOzqLmrrOG6HivcW0PfU38Qcyj5AgAcz0W+sX6Fm3GROQ02jpHe/jTTF9KTplv1 e8O87OO/BhPMNnMQjvnb/pIglWE1jMp0RyT72HyZR+oNwb6r1fU6l7pqKZQdmeOMMew5 DWmNVN2CgvNWzVfcoP9x7cnUe1XygTfgDiPICnD4oXdZ8venCuH/tf4hb2M7pkr0zrzT mIf5SykuyW+Zsv+Zrrps4OypetYCDL4BoEEF6dmWwSV6cdcnYhXNd+5hLXNMtyTOEc1x Mcvg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:to:cc:references:from:subject:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=0/ywTBh9vVtj/O9hBacDbDslP+49GsVfBx0ndsXXJ9o=; b=enVXhRp9Kmv2Y/g/+Tw64teaZc0ThgzvGQkBBr6C3tdTLTsrmTEbaXCUqMih51A8z+ S6VT56E7GiGh8fO0C2zUchiBkhdVC9+xtplYnmDWnnAscGw3ruqSbnTmiZnYjdzGShE8 l4KVhGtFTE0aW/eiO3uyFrf31flYUxJ6H5Q/ahrATH1zNTq5QFPKc4wj8ZsFLD160tcj tGwjC9l9RwFE6hzIEeFZ4UVh3BqiHyGojepfMjgxPECeCNPghYecElPB/VO4TkbF/dgg UZ4Forxo1weD99r/Ef6jiYigpRkYMFkwdsmm1KzNpSLOdFNCWjjBgCJQwNjWKAMHVPNg NjaQ== X-Gm-Message-State: AOAM533gFYBiiEkcLn4lljN1h76gx8d4iEkId+dEuyhd2/Mtz3a7wjH0 W2rl2nayFH8RLbjbvS2eCohR+x3KLvVfQLZf8ZKf64zX9BynIdOo7QNlAbGiWue/5OcKpUJHMB4 CdU8OjgQ7kzCOfsTENXEWldqR4DJ9pY1dDJMb8JWkIjPpWAsQk8Zg1pNbGLuRHiw7iNDm7SEqQk sVaG9h2dCOrxy1QA== X-Google-Smtp-Source: ABdhPJxfz4NHwAITYnrzYoz75XKOeJGCeHeVbojoM/8sXA3FKesaOqvpXO/h4JpuLWsTyctVo+IalQ== X-Received: by 2002:a37:4392:: with SMTP id q140mr9498692qka.49.1622646703181; Wed, 02 Jun 2021 08:11:43 -0700 (PDT) Received: from [192.168.4.41] (072-017-018-098.res.spectrum.com. [72.17.18.98]) by smtp.gmail.com with ESMTPSA id k23sm176547qkk.71.2021.06.02.08.11.42 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 02 Jun 2021 08:11:42 -0700 (PDT) To: Jim Mlodgenski , Tom Lane Cc: PostgreSQL Hackers References: <2897116.1622642280@sss.pgh.pa.us> From: Joe Conway Subject: Re: Support for CREATE MODULE? Message-ID: <3cb12d67-c94d-375b-d4a1-18441f2abd25@joeconway.com> Date: Wed, 2 Jun 2021 11:11:42 -0400 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.7.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 6/2/21 10:43 AM, Jim Mlodgenski wrote: > On Wed, Jun 2, 2021 at 9:58 AM Tom Lane wrote: >> I wonder whether it'd be better to consider modules as a kind of >> extension, or at least things with the same sort of ownership relations >> as extensions have. > > That would solve the problem of associating objects which is the larger > problem for users today. The objects can all live in their respective > schemas with the module tying them all together. Maybe something similar to "CREATE EXTENSION ... FROM unpackaged"? Something like: CREATE EXTENSION myfoo; /* shell extension */ ALTER EXTENSION myfoo ADD type ...; ALTER EXTENSION myfoo ADD function ...; ... Joe -- Crunchy Data - http://crunchydata.com PostgreSQL Support for Secure Enterprises Consulting, Training, & Open Source Development