You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@flink.apache.org by Dawid Wysakowicz <dw...@apache.org> on 2025/07/28 13:31:49 UTC

[DISCUSS] FLIP-539: Support WITH Clause in CREATE FUNCTION Statement in Flink SQL

Hi,
I'd like to start a discussion of FLIP-539: Support WITH Clause in CREATE
FUNCTION Statement in Flink SQL [1].

The existing CREATE FUNCTION  statement in Flink SQL allows users to
register user-defined functions (UDFs) by specifying the class name and the
artifact (JAR) containing the implementation. While this design covers
common use cases, it lacks a declarative mechanism for associating
arbitrary properties or metadata with the function at creation time.

Other Flink SQL objects—such as tables—support a WITH  clause for
specifying options in a key-value fashion, improving consistency,
discoverability, and extensibility.
Looking forward to comments and suggestions for improvements!

Best,
Dawid

[1] https://cwiki.apache.org/confluence/x/sg9JFg

Re: [DISCUSS] FLIP-539: Support WITH Clause in CREATE FUNCTION Statement in Flink SQL

Posted by Timo Walther <tw...@apache.org>.
Hi Dawid,

thanks for proposing this FLIP. Overall it fits into existing concepts 
and completes the syntax.

+1 for this

Cheers,
Timo

On 28.07.25 15:31, Dawid Wysakowicz wrote:
> Hi,
> I'd like to start a discussion of FLIP-539: Support WITH Clause in CREATE
> FUNCTION Statement in Flink SQL [1].
> 
> The existing CREATE FUNCTION  statement in Flink SQL allows users to
> register user-defined functions (UDFs) by specifying the class name and the
> artifact (JAR) containing the implementation. While this design covers
> common use cases, it lacks a declarative mechanism for associating
> arbitrary properties or metadata with the function at creation time.
> 
> Other Flink SQL objects—such as tables—support a WITH  clause for
> specifying options in a key-value fashion, improving consistency,
> discoverability, and extensibility.
> Looking forward to comments and suggestions for improvements!
> 
> Best,
> Dawid
> 
> [1] https://cwiki.apache.org/confluence/x/sg9JFg
> 


Re: [DISCUSS] FLIP-539: Support WITH Clause in CREATE FUNCTION Statement in Flink SQL

Posted by Dawid Wysakowicz <dw...@apache.org>.
I'll proceed with the VOTE

On Fri, 1 Aug 2025 at 11:01, Gustavo de Morais <gu...@gmail.com>
wrote:

> Hi Dawid,
>
> That's a useful addition, +1. Thanks for the FLIP and for driving this.
>
> Gustavo
>
> On Thu, 31 Jul 2025 at 17:43, Natea Eshetu Beshada
> <nb...@confluent.io.invalid> wrote:
>
> > Hey Dawid,
> >
> > Looks like a solid idea to me to help enrich functions, I am +1 this
> > proposal.
> >
> > Thanks,
> > Natea
> >
> > On Tue, Jul 29, 2025 at 2:28 PM Hao Li <hl...@confluent.io.invalid> wrote:
> >
> > > Hi Dawid,
> > >
> > > Thanks for the FLIP. +1 to support options for functions as well.
> > >
> > > I have one question:
> > > Do you want to update `createTemporarySystemFunction` in
> > `TableEnvironment`
> > > to support `FunctionDescriptor` as well?
> > >
> > > Thanks,
> > > Hao
> > >
> > > On Tue, Jul 29, 2025 at 10:33 AM Yash Anand <ya...@gmail.com>
> > > wrote:
> > >
> > > > Hi Dawid,
> > > >
> > > > Thank you for initiating this FLIP, looks like a useful addition +1
> for
> > > the
> > > > FLIP.
> > > >
> > > > I have just one question, will the option keys be limited to some
> > > > predefined values or it could be any key user wants to add as
> metadata?
> > > > Like if the user wants to add a description for each argument?
> > > >
> > > > On Tue, Jul 29, 2025 at 7:09 AM Timo Walther <tw...@apache.org>
> > wrote:
> > > >
> > > > > Maybe not in the first version but eventually nothing in the design
> > > > > blocks us for supporting this. The SecretStore would need to be
> > > > > available in the FunctionDefinitionFactory for this.
> > > > >
> > > > > Cheers,
> > > > > Timo
> > > > >
> > > > > On 29.07.25 15:08, Ryan van Huuksloot wrote:
> > > > > > Overall the FLIP looks good to me.
> > > > > >
> > > > > > Would the properties support the SecretStore proposed in
> FLIP-529?
> > > > > >
> > > > > > Otherwise, +1, thanks!
> > > > > >
> > > > > > Ryan van Huuksloot
> > > > > > Staff Engineer, Infrastructure | Streaming Platform
> > > > > > [image: Shopify]
> > > > > > <
> > > >
> > https://www.shopify.com/?utm_medium=salessignatures&utm_source=hs_email
> > > > > >
> > > > > >
> > > > > >
> > > > > > On Tue, Jul 29, 2025 at 4:19 AM Jacky Lau <li...@gmail.com>
> > > > wrote:
> > > > > >
> > > > > >> Thanks for initiating this!
> > > > > >>
> > > > > >> +1 for this proposal.
> > > > > >>
> > > > > >> Sergey Nuyanzin <sn...@gmail.com> 于2025年7月29日周二 15:34写道:
> > > > > >>
> > > > > >>> Thanks for driving this Dawid.
> > > > > >>>
> > > > > >>> looks reasonable to me
> > > > > >>>
> > > > > >>> On Mon, Jul 28, 2025 at 5:03 PM Ramin Gharib <
> > > ramingharib@gmail.com>
> > > > > >>> wrote:
> > > > > >>>>
> > > > > >>>> Hello Dawid,
> > > > > >>>>
> > > > > >>>> Thanks for initiating this! The FLIP looks well-written.
> > > > > >>>> The WITH clause brings consistency to existing syntax.
> > > > > >>>>
> > > > > >>>> +1 for this proposal.
> > > > > >>>>
> > > > > >>>> On Mon, Jul 28, 2025 at 3:33 PM Dawid Wysakowicz <
> > > > > >> dwysakowicz@apache.org
> > > > > >>>>
> > > > > >>>> wrote:
> > > > > >>>>
> > > > > >>>>> Hi,
> > > > > >>>>> I'd like to start a discussion of FLIP-539: Support WITH
> Clause
> > > in
> > > > > >>> CREATE
> > > > > >>>>> FUNCTION Statement in Flink SQL [1].
> > > > > >>>>>
> > > > > >>>>> The existing CREATE FUNCTION  statement in Flink SQL allows
> > users
> > > > to
> > > > > >>>>> register user-defined functions (UDFs) by specifying the
> class
> > > name
> > > > > >>> and the
> > > > > >>>>> artifact (JAR) containing the implementation. While this
> design
> > > > > >> covers
> > > > > >>>>> common use cases, it lacks a declarative mechanism for
> > > associating
> > > > > >>>>> arbitrary properties or metadata with the function at
> creation
> > > > time.
> > > > > >>>>>
> > > > > >>>>> Other Flink SQL objects—such as tables—support a WITH  clause
> > for
> > > > > >>>>> specifying options in a key-value fashion, improving
> > consistency,
> > > > > >>>>> discoverability, and extensibility.
> > > > > >>>>> Looking forward to comments and suggestions for improvements!
> > > > > >>>>>
> > > > > >>>>> Best,
> > > > > >>>>> Dawid
> > > > > >>>>>
> > > > > >>>>> [1] https://cwiki.apache.org/confluence/x/sg9JFg
> > > > > >>>>>
> > > > > >>>
> > > > > >>>
> > > > > >>>
> > > > > >>> --
> > > > > >>> Best regards,
> > > > > >>> Sergey
> > > > > >>>
> > > > > >>
> > > > > >
> > > > >
> > > > >
> > > >
> > >
> >
>

Re: [DISCUSS] FLIP-539: Support WITH Clause in CREATE FUNCTION Statement in Flink SQL

Posted by Gustavo de Morais <gu...@gmail.com>.
Hi Dawid,

That's a useful addition, +1. Thanks for the FLIP and for driving this.

Gustavo

On Thu, 31 Jul 2025 at 17:43, Natea Eshetu Beshada
<nb...@confluent.io.invalid> wrote:

> Hey Dawid,
>
> Looks like a solid idea to me to help enrich functions, I am +1 this
> proposal.
>
> Thanks,
> Natea
>
> On Tue, Jul 29, 2025 at 2:28 PM Hao Li <hl...@confluent.io.invalid> wrote:
>
> > Hi Dawid,
> >
> > Thanks for the FLIP. +1 to support options for functions as well.
> >
> > I have one question:
> > Do you want to update `createTemporarySystemFunction` in
> `TableEnvironment`
> > to support `FunctionDescriptor` as well?
> >
> > Thanks,
> > Hao
> >
> > On Tue, Jul 29, 2025 at 10:33 AM Yash Anand <ya...@gmail.com>
> > wrote:
> >
> > > Hi Dawid,
> > >
> > > Thank you for initiating this FLIP, looks like a useful addition +1 for
> > the
> > > FLIP.
> > >
> > > I have just one question, will the option keys be limited to some
> > > predefined values or it could be any key user wants to add as metadata?
> > > Like if the user wants to add a description for each argument?
> > >
> > > On Tue, Jul 29, 2025 at 7:09 AM Timo Walther <tw...@apache.org>
> wrote:
> > >
> > > > Maybe not in the first version but eventually nothing in the design
> > > > blocks us for supporting this. The SecretStore would need to be
> > > > available in the FunctionDefinitionFactory for this.
> > > >
> > > > Cheers,
> > > > Timo
> > > >
> > > > On 29.07.25 15:08, Ryan van Huuksloot wrote:
> > > > > Overall the FLIP looks good to me.
> > > > >
> > > > > Would the properties support the SecretStore proposed in FLIP-529?
> > > > >
> > > > > Otherwise, +1, thanks!
> > > > >
> > > > > Ryan van Huuksloot
> > > > > Staff Engineer, Infrastructure | Streaming Platform
> > > > > [image: Shopify]
> > > > > <
> > >
> https://www.shopify.com/?utm_medium=salessignatures&utm_source=hs_email
> > > > >
> > > > >
> > > > >
> > > > > On Tue, Jul 29, 2025 at 4:19 AM Jacky Lau <li...@gmail.com>
> > > wrote:
> > > > >
> > > > >> Thanks for initiating this!
> > > > >>
> > > > >> +1 for this proposal.
> > > > >>
> > > > >> Sergey Nuyanzin <sn...@gmail.com> 于2025年7月29日周二 15:34写道:
> > > > >>
> > > > >>> Thanks for driving this Dawid.
> > > > >>>
> > > > >>> looks reasonable to me
> > > > >>>
> > > > >>> On Mon, Jul 28, 2025 at 5:03 PM Ramin Gharib <
> > ramingharib@gmail.com>
> > > > >>> wrote:
> > > > >>>>
> > > > >>>> Hello Dawid,
> > > > >>>>
> > > > >>>> Thanks for initiating this! The FLIP looks well-written.
> > > > >>>> The WITH clause brings consistency to existing syntax.
> > > > >>>>
> > > > >>>> +1 for this proposal.
> > > > >>>>
> > > > >>>> On Mon, Jul 28, 2025 at 3:33 PM Dawid Wysakowicz <
> > > > >> dwysakowicz@apache.org
> > > > >>>>
> > > > >>>> wrote:
> > > > >>>>
> > > > >>>>> Hi,
> > > > >>>>> I'd like to start a discussion of FLIP-539: Support WITH Clause
> > in
> > > > >>> CREATE
> > > > >>>>> FUNCTION Statement in Flink SQL [1].
> > > > >>>>>
> > > > >>>>> The existing CREATE FUNCTION  statement in Flink SQL allows
> users
> > > to
> > > > >>>>> register user-defined functions (UDFs) by specifying the class
> > name
> > > > >>> and the
> > > > >>>>> artifact (JAR) containing the implementation. While this design
> > > > >> covers
> > > > >>>>> common use cases, it lacks a declarative mechanism for
> > associating
> > > > >>>>> arbitrary properties or metadata with the function at creation
> > > time.
> > > > >>>>>
> > > > >>>>> Other Flink SQL objects—such as tables—support a WITH  clause
> for
> > > > >>>>> specifying options in a key-value fashion, improving
> consistency,
> > > > >>>>> discoverability, and extensibility.
> > > > >>>>> Looking forward to comments and suggestions for improvements!
> > > > >>>>>
> > > > >>>>> Best,
> > > > >>>>> Dawid
> > > > >>>>>
> > > > >>>>> [1] https://cwiki.apache.org/confluence/x/sg9JFg
> > > > >>>>>
> > > > >>>
> > > > >>>
> > > > >>>
> > > > >>> --
> > > > >>> Best regards,
> > > > >>> Sergey
> > > > >>>
> > > > >>
> > > > >
> > > >
> > > >
> > >
> >
>

Re: [DISCUSS] FLIP-539: Support WITH Clause in CREATE FUNCTION Statement in Flink SQL

Posted by Natea Eshetu Beshada <nb...@confluent.io.INVALID>.
Hey Dawid,

Looks like a solid idea to me to help enrich functions, I am +1 this
proposal.

Thanks,
Natea

On Tue, Jul 29, 2025 at 2:28 PM Hao Li <hl...@confluent.io.invalid> wrote:

> Hi Dawid,
>
> Thanks for the FLIP. +1 to support options for functions as well.
>
> I have one question:
> Do you want to update `createTemporarySystemFunction` in `TableEnvironment`
> to support `FunctionDescriptor` as well?
>
> Thanks,
> Hao
>
> On Tue, Jul 29, 2025 at 10:33 AM Yash Anand <ya...@gmail.com>
> wrote:
>
> > Hi Dawid,
> >
> > Thank you for initiating this FLIP, looks like a useful addition +1 for
> the
> > FLIP.
> >
> > I have just one question, will the option keys be limited to some
> > predefined values or it could be any key user wants to add as metadata?
> > Like if the user wants to add a description for each argument?
> >
> > On Tue, Jul 29, 2025 at 7:09 AM Timo Walther <tw...@apache.org> wrote:
> >
> > > Maybe not in the first version but eventually nothing in the design
> > > blocks us for supporting this. The SecretStore would need to be
> > > available in the FunctionDefinitionFactory for this.
> > >
> > > Cheers,
> > > Timo
> > >
> > > On 29.07.25 15:08, Ryan van Huuksloot wrote:
> > > > Overall the FLIP looks good to me.
> > > >
> > > > Would the properties support the SecretStore proposed in FLIP-529?
> > > >
> > > > Otherwise, +1, thanks!
> > > >
> > > > Ryan van Huuksloot
> > > > Staff Engineer, Infrastructure | Streaming Platform
> > > > [image: Shopify]
> > > > <
> > https://www.shopify.com/?utm_medium=salessignatures&utm_source=hs_email
> > > >
> > > >
> > > >
> > > > On Tue, Jul 29, 2025 at 4:19 AM Jacky Lau <li...@gmail.com>
> > wrote:
> > > >
> > > >> Thanks for initiating this!
> > > >>
> > > >> +1 for this proposal.
> > > >>
> > > >> Sergey Nuyanzin <sn...@gmail.com> 于2025年7月29日周二 15:34写道:
> > > >>
> > > >>> Thanks for driving this Dawid.
> > > >>>
> > > >>> looks reasonable to me
> > > >>>
> > > >>> On Mon, Jul 28, 2025 at 5:03 PM Ramin Gharib <
> ramingharib@gmail.com>
> > > >>> wrote:
> > > >>>>
> > > >>>> Hello Dawid,
> > > >>>>
> > > >>>> Thanks for initiating this! The FLIP looks well-written.
> > > >>>> The WITH clause brings consistency to existing syntax.
> > > >>>>
> > > >>>> +1 for this proposal.
> > > >>>>
> > > >>>> On Mon, Jul 28, 2025 at 3:33 PM Dawid Wysakowicz <
> > > >> dwysakowicz@apache.org
> > > >>>>
> > > >>>> wrote:
> > > >>>>
> > > >>>>> Hi,
> > > >>>>> I'd like to start a discussion of FLIP-539: Support WITH Clause
> in
> > > >>> CREATE
> > > >>>>> FUNCTION Statement in Flink SQL [1].
> > > >>>>>
> > > >>>>> The existing CREATE FUNCTION  statement in Flink SQL allows users
> > to
> > > >>>>> register user-defined functions (UDFs) by specifying the class
> name
> > > >>> and the
> > > >>>>> artifact (JAR) containing the implementation. While this design
> > > >> covers
> > > >>>>> common use cases, it lacks a declarative mechanism for
> associating
> > > >>>>> arbitrary properties or metadata with the function at creation
> > time.
> > > >>>>>
> > > >>>>> Other Flink SQL objects—such as tables—support a WITH  clause for
> > > >>>>> specifying options in a key-value fashion, improving consistency,
> > > >>>>> discoverability, and extensibility.
> > > >>>>> Looking forward to comments and suggestions for improvements!
> > > >>>>>
> > > >>>>> Best,
> > > >>>>> Dawid
> > > >>>>>
> > > >>>>> [1] https://cwiki.apache.org/confluence/x/sg9JFg
> > > >>>>>
> > > >>>
> > > >>>
> > > >>>
> > > >>> --
> > > >>> Best regards,
> > > >>> Sergey
> > > >>>
> > > >>
> > > >
> > >
> > >
> >
>

Re: [DISCUSS] FLIP-539: Support WITH Clause in CREATE FUNCTION Statement in Flink SQL

Posted by Dawid Wysakowicz <dw...@apache.org>.
If there are no other comments, I will start the vote in a day or two.
Best,
Dawid

On Wed, 30 Jul 2025 at 09:56, Dawid Wysakowicz <dw...@apache.org>
wrote:

> Would the properties support the SecretStore proposed in FLIP-529?
>
> As Timo wrote, not in the first version, but we can extend it once both
> FLIPs land in.
>
>>   have just one question, will the option keys be limited to some
>> predefined values or it could be any key user wants to add as metadata?
>> Like if the user wants to add a description for each argument?
>
> No, there would be no limitations. Those will be just arbitrary properties
> that are not interpreted by Flink itself. Similarly as other objects such
> as Table, Catalog, Database and so on do.
>
>> Do you want to update `createTemporarySystemFunction` in
>> `TableEnvironment`
>> to support `FunctionDescriptor` as well?
>
> I added this method as well to the FLIP.
>
>> What's the difference between the FunctionDescriptor and
>> CatalogFunction? In my opinion, they are almost same here. If possible,
>> can
>> we reuse the same pojo class here?
>
> I don't think that's a good idea. They serve different purposes. One is a
> catalog object (CatalogFunction) that is fully in control of the Catalog
> and can have catalog specific implementations. The other is an API object
> with a fluent API. The same way as it is for CatalogTable and
> TableDescriptor.
>
>> The FLIP writes "The WITH clause will accept a list of key-value pairs
>> similar to the syntax currently used in CREATE TABLE, CREATE VIEW, and
>> CTAS", but I don't see CREATE VIEW statement works with WITH clause in any
>> doc.
>
> That's actually a good point. I was not aware CREATE VIEW does not support
> WITH clause. I think this is a mistake of the VIEW implementation.
> CatalogView does have properties and there are classes that prepare for
> setting them at certain locations[1]. I believe this should be addressed in
> a separate FLIP.
>
>> In most cases, the options in the WITH clause are defined by the
>> framework or system. But it seems function is different, it's totally
>> determined by the users. I prefer we can align the same design to provide
>> system-defiend options for users to track version, resource hints.
>
> That's not the purpose of the FLIP. The purpose of the FLIP is to provide
> a mechanism for users to pass arbitrary properties from the user to the
> catalog and back to the factory that instantiates the function definitions.
>
> Best,
> Dawid
>
> [1]
> https://github.com/apache/flink/blob/master/flink-table/flink-sql-parser/src/main/java/org/apache/flink/sql/parser/ddl/SqlAlterViewProperties.java
>
> On Wed, 30 Jul 2025 at 04:47, Shengkai Fang <fs...@gmail.com> wrote:
>
>> Hi.
>>
>> I have some questions about this FLIP:
>>
>> 1. What's the difference between the FunctionDescriptor and
>> CatalogFunction? In my opinion, they are almost same here. If possible,
>> can
>> we reuse the same pojo class here?
>>
>> 2. The FLIP writes "The WITH clause will accept a list of key-value pairs
>> similar to the syntax currently used in CREATE TABLE, CREATE VIEW, and
>> CTAS", but I don't see CREATE VIEW statement works with WITH clause in any
>> doc.
>>
>> 3. In most cases, the options in the WITH clause are defined by the
>> framework or system. But it seems function is different, it's totally
>> determined by the users. I prefer we can align the same design to provide
>> system-defiend options for users to track version, resource hints.
>>
>> Best,
>> Shengkai
>>
>> Hao Li <hl...@confluent.io.invalid> 于2025年7月30日周三 02:27写道:
>>
>> > Hi Dawid,
>> >
>> > Thanks for the FLIP. +1 to support options for functions as well.
>> >
>> > I have one question:
>> > Do you want to update `createTemporarySystemFunction` in
>> `TableEnvironment`
>> > to support `FunctionDescriptor` as well?
>> >
>> > Thanks,
>> > Hao
>> >
>> > On Tue, Jul 29, 2025 at 10:33 AM Yash Anand <ya...@gmail.com>
>> > wrote:
>> >
>> > > Hi Dawid,
>> > >
>> > > Thank you for initiating this FLIP, looks like a useful addition +1
>> for
>> > the
>> > > FLIP.
>> > >
>> > > I have just one question, will the option keys be limited to some
>> > > predefined values or it could be any key user wants to add as
>> metadata?
>> > > Like if the user wants to add a description for each argument?
>> > >
>> > > On Tue, Jul 29, 2025 at 7:09 AM Timo Walther <tw...@apache.org>
>> wrote:
>> > >
>> > > > Maybe not in the first version but eventually nothing in the design
>> > > > blocks us for supporting this. The SecretStore would need to be
>> > > > available in the FunctionDefinitionFactory for this.
>> > > >
>> > > > Cheers,
>> > > > Timo
>> > > >
>> > > > On 29.07.25 15:08, Ryan van Huuksloot wrote:
>> > > > > Overall the FLIP looks good to me.
>> > > > >
>> > > > > Would the properties support the SecretStore proposed in FLIP-529?
>> > > > >
>> > > > > Otherwise, +1, thanks!
>> > > > >
>> > > > > Ryan van Huuksloot
>> > > > > Staff Engineer, Infrastructure | Streaming Platform
>> > > > > [image: Shopify]
>> > > > > <
>> > >
>> https://www.shopify.com/?utm_medium=salessignatures&utm_source=hs_email
>> > > > >
>> > > > >
>> > > > >
>> > > > > On Tue, Jul 29, 2025 at 4:19 AM Jacky Lau <li...@gmail.com>
>> > > wrote:
>> > > > >
>> > > > >> Thanks for initiating this!
>> > > > >>
>> > > > >> +1 for this proposal.
>> > > > >>
>> > > > >> Sergey Nuyanzin <sn...@gmail.com> 于2025年7月29日周二 15:34写道:
>> > > > >>
>> > > > >>> Thanks for driving this Dawid.
>> > > > >>>
>> > > > >>> looks reasonable to me
>> > > > >>>
>> > > > >>> On Mon, Jul 28, 2025 at 5:03 PM Ramin Gharib <
>> > ramingharib@gmail.com>
>> > > > >>> wrote:
>> > > > >>>>
>> > > > >>>> Hello Dawid,
>> > > > >>>>
>> > > > >>>> Thanks for initiating this! The FLIP looks well-written.
>> > > > >>>> The WITH clause brings consistency to existing syntax.
>> > > > >>>>
>> > > > >>>> +1 for this proposal.
>> > > > >>>>
>> > > > >>>> On Mon, Jul 28, 2025 at 3:33 PM Dawid Wysakowicz <
>> > > > >> dwysakowicz@apache.org
>> > > > >>>>
>> > > > >>>> wrote:
>> > > > >>>>
>> > > > >>>>> Hi,
>> > > > >>>>> I'd like to start a discussion of FLIP-539: Support WITH
>> Clause
>> > in
>> > > > >>> CREATE
>> > > > >>>>> FUNCTION Statement in Flink SQL [1].
>> > > > >>>>>
>> > > > >>>>> The existing CREATE FUNCTION  statement in Flink SQL allows
>> users
>> > > to
>> > > > >>>>> register user-defined functions (UDFs) by specifying the class
>> > name
>> > > > >>> and the
>> > > > >>>>> artifact (JAR) containing the implementation. While this
>> design
>> > > > >> covers
>> > > > >>>>> common use cases, it lacks a declarative mechanism for
>> > associating
>> > > > >>>>> arbitrary properties or metadata with the function at creation
>> > > time.
>> > > > >>>>>
>> > > > >>>>> Other Flink SQL objects—such as tables—support a WITH  clause
>> for
>> > > > >>>>> specifying options in a key-value fashion, improving
>> consistency,
>> > > > >>>>> discoverability, and extensibility.
>> > > > >>>>> Looking forward to comments and suggestions for improvements!
>> > > > >>>>>
>> > > > >>>>> Best,
>> > > > >>>>> Dawid
>> > > > >>>>>
>> > > > >>>>> [1] https://cwiki.apache.org/confluence/x/sg9JFg
>> > > > >>>>>
>> > > > >>>
>> > > > >>>
>> > > > >>>
>> > > > >>> --
>> > > > >>> Best regards,
>> > > > >>> Sergey
>> > > > >>>
>> > > > >>
>> > > > >
>> > > >
>> > > >
>> > >
>> >
>>
>

Re: [DISCUSS] FLIP-539: Support WITH Clause in CREATE FUNCTION Statement in Flink SQL

Posted by Dawid Wysakowicz <dw...@apache.org>.
>
> Would the properties support the SecretStore proposed in FLIP-529?

As Timo wrote, not in the first version, but we can extend it once both
FLIPs land in.

>   have just one question, will the option keys be limited to some
> predefined values or it could be any key user wants to add as metadata?
> Like if the user wants to add a description for each argument?

No, there would be no limitations. Those will be just arbitrary properties
that are not interpreted by Flink itself. Similarly as other objects such
as Table, Catalog, Database and so on do.

> Do you want to update `createTemporarySystemFunction` in `TableEnvironment`
> to support `FunctionDescriptor` as well?

I added this method as well to the FLIP.

> What's the difference between the FunctionDescriptor and
> CatalogFunction? In my opinion, they are almost same here. If possible, can
> we reuse the same pojo class here?

I don't think that's a good idea. They serve different purposes. One is a
catalog object (CatalogFunction) that is fully in control of the Catalog
and can have catalog specific implementations. The other is an API object
with a fluent API. The same way as it is for CatalogTable and
TableDescriptor.

> The FLIP writes "The WITH clause will accept a list of key-value pairs
> similar to the syntax currently used in CREATE TABLE, CREATE VIEW, and
> CTAS", but I don't see CREATE VIEW statement works with WITH clause in any
> doc.

That's actually a good point. I was not aware CREATE VIEW does not support
WITH clause. I think this is a mistake of the VIEW implementation.
CatalogView does have properties and there are classes that prepare for
setting them at certain locations[1]. I believe this should be addressed in
a separate FLIP.

> In most cases, the options in the WITH clause are defined by the
> framework or system. But it seems function is different, it's totally
> determined by the users. I prefer we can align the same design to provide
> system-defiend options for users to track version, resource hints.

That's not the purpose of the FLIP. The purpose of the FLIP is to provide a
mechanism for users to pass arbitrary properties from the user to the
catalog and back to the factory that instantiates the function definitions.

Best,
Dawid

[1]
https://github.com/apache/flink/blob/master/flink-table/flink-sql-parser/src/main/java/org/apache/flink/sql/parser/ddl/SqlAlterViewProperties.java

On Wed, 30 Jul 2025 at 04:47, Shengkai Fang <fs...@gmail.com> wrote:

> Hi.
>
> I have some questions about this FLIP:
>
> 1. What's the difference between the FunctionDescriptor and
> CatalogFunction? In my opinion, they are almost same here. If possible, can
> we reuse the same pojo class here?
>
> 2. The FLIP writes "The WITH clause will accept a list of key-value pairs
> similar to the syntax currently used in CREATE TABLE, CREATE VIEW, and
> CTAS", but I don't see CREATE VIEW statement works with WITH clause in any
> doc.
>
> 3. In most cases, the options in the WITH clause are defined by the
> framework or system. But it seems function is different, it's totally
> determined by the users. I prefer we can align the same design to provide
> system-defiend options for users to track version, resource hints.
>
> Best,
> Shengkai
>
> Hao Li <hl...@confluent.io.invalid> 于2025年7月30日周三 02:27写道:
>
> > Hi Dawid,
> >
> > Thanks for the FLIP. +1 to support options for functions as well.
> >
> > I have one question:
> > Do you want to update `createTemporarySystemFunction` in
> `TableEnvironment`
> > to support `FunctionDescriptor` as well?
> >
> > Thanks,
> > Hao
> >
> > On Tue, Jul 29, 2025 at 10:33 AM Yash Anand <ya...@gmail.com>
> > wrote:
> >
> > > Hi Dawid,
> > >
> > > Thank you for initiating this FLIP, looks like a useful addition +1 for
> > the
> > > FLIP.
> > >
> > > I have just one question, will the option keys be limited to some
> > > predefined values or it could be any key user wants to add as metadata?
> > > Like if the user wants to add a description for each argument?
> > >
> > > On Tue, Jul 29, 2025 at 7:09 AM Timo Walther <tw...@apache.org>
> wrote:
> > >
> > > > Maybe not in the first version but eventually nothing in the design
> > > > blocks us for supporting this. The SecretStore would need to be
> > > > available in the FunctionDefinitionFactory for this.
> > > >
> > > > Cheers,
> > > > Timo
> > > >
> > > > On 29.07.25 15:08, Ryan van Huuksloot wrote:
> > > > > Overall the FLIP looks good to me.
> > > > >
> > > > > Would the properties support the SecretStore proposed in FLIP-529?
> > > > >
> > > > > Otherwise, +1, thanks!
> > > > >
> > > > > Ryan van Huuksloot
> > > > > Staff Engineer, Infrastructure | Streaming Platform
> > > > > [image: Shopify]
> > > > > <
> > >
> https://www.shopify.com/?utm_medium=salessignatures&utm_source=hs_email
> > > > >
> > > > >
> > > > >
> > > > > On Tue, Jul 29, 2025 at 4:19 AM Jacky Lau <li...@gmail.com>
> > > wrote:
> > > > >
> > > > >> Thanks for initiating this!
> > > > >>
> > > > >> +1 for this proposal.
> > > > >>
> > > > >> Sergey Nuyanzin <sn...@gmail.com> 于2025年7月29日周二 15:34写道:
> > > > >>
> > > > >>> Thanks for driving this Dawid.
> > > > >>>
> > > > >>> looks reasonable to me
> > > > >>>
> > > > >>> On Mon, Jul 28, 2025 at 5:03 PM Ramin Gharib <
> > ramingharib@gmail.com>
> > > > >>> wrote:
> > > > >>>>
> > > > >>>> Hello Dawid,
> > > > >>>>
> > > > >>>> Thanks for initiating this! The FLIP looks well-written.
> > > > >>>> The WITH clause brings consistency to existing syntax.
> > > > >>>>
> > > > >>>> +1 for this proposal.
> > > > >>>>
> > > > >>>> On Mon, Jul 28, 2025 at 3:33 PM Dawid Wysakowicz <
> > > > >> dwysakowicz@apache.org
> > > > >>>>
> > > > >>>> wrote:
> > > > >>>>
> > > > >>>>> Hi,
> > > > >>>>> I'd like to start a discussion of FLIP-539: Support WITH Clause
> > in
> > > > >>> CREATE
> > > > >>>>> FUNCTION Statement in Flink SQL [1].
> > > > >>>>>
> > > > >>>>> The existing CREATE FUNCTION  statement in Flink SQL allows
> users
> > > to
> > > > >>>>> register user-defined functions (UDFs) by specifying the class
> > name
> > > > >>> and the
> > > > >>>>> artifact (JAR) containing the implementation. While this design
> > > > >> covers
> > > > >>>>> common use cases, it lacks a declarative mechanism for
> > associating
> > > > >>>>> arbitrary properties or metadata with the function at creation
> > > time.
> > > > >>>>>
> > > > >>>>> Other Flink SQL objects—such as tables—support a WITH  clause
> for
> > > > >>>>> specifying options in a key-value fashion, improving
> consistency,
> > > > >>>>> discoverability, and extensibility.
> > > > >>>>> Looking forward to comments and suggestions for improvements!
> > > > >>>>>
> > > > >>>>> Best,
> > > > >>>>> Dawid
> > > > >>>>>
> > > > >>>>> [1] https://cwiki.apache.org/confluence/x/sg9JFg
> > > > >>>>>
> > > > >>>
> > > > >>>
> > > > >>>
> > > > >>> --
> > > > >>> Best regards,
> > > > >>> Sergey
> > > > >>>
> > > > >>
> > > > >
> > > >
> > > >
> > >
> >
>

Re: [DISCUSS] FLIP-539: Support WITH Clause in CREATE FUNCTION Statement in Flink SQL

Posted by Shengkai Fang <fs...@gmail.com>.
Hi.

I have some questions about this FLIP:

1. What's the difference between the FunctionDescriptor and
CatalogFunction? In my opinion, they are almost same here. If possible, can
we reuse the same pojo class here?

2. The FLIP writes "The WITH clause will accept a list of key-value pairs
similar to the syntax currently used in CREATE TABLE, CREATE VIEW, and
CTAS", but I don't see CREATE VIEW statement works with WITH clause in any
doc.

3. In most cases, the options in the WITH clause are defined by the
framework or system. But it seems function is different, it's totally
determined by the users. I prefer we can align the same design to provide
system-defiend options for users to track version, resource hints.

Best,
Shengkai

Hao Li <hl...@confluent.io.invalid> 于2025年7月30日周三 02:27写道:

> Hi Dawid,
>
> Thanks for the FLIP. +1 to support options for functions as well.
>
> I have one question:
> Do you want to update `createTemporarySystemFunction` in `TableEnvironment`
> to support `FunctionDescriptor` as well?
>
> Thanks,
> Hao
>
> On Tue, Jul 29, 2025 at 10:33 AM Yash Anand <ya...@gmail.com>
> wrote:
>
> > Hi Dawid,
> >
> > Thank you for initiating this FLIP, looks like a useful addition +1 for
> the
> > FLIP.
> >
> > I have just one question, will the option keys be limited to some
> > predefined values or it could be any key user wants to add as metadata?
> > Like if the user wants to add a description for each argument?
> >
> > On Tue, Jul 29, 2025 at 7:09 AM Timo Walther <tw...@apache.org> wrote:
> >
> > > Maybe not in the first version but eventually nothing in the design
> > > blocks us for supporting this. The SecretStore would need to be
> > > available in the FunctionDefinitionFactory for this.
> > >
> > > Cheers,
> > > Timo
> > >
> > > On 29.07.25 15:08, Ryan van Huuksloot wrote:
> > > > Overall the FLIP looks good to me.
> > > >
> > > > Would the properties support the SecretStore proposed in FLIP-529?
> > > >
> > > > Otherwise, +1, thanks!
> > > >
> > > > Ryan van Huuksloot
> > > > Staff Engineer, Infrastructure | Streaming Platform
> > > > [image: Shopify]
> > > > <
> > https://www.shopify.com/?utm_medium=salessignatures&utm_source=hs_email
> > > >
> > > >
> > > >
> > > > On Tue, Jul 29, 2025 at 4:19 AM Jacky Lau <li...@gmail.com>
> > wrote:
> > > >
> > > >> Thanks for initiating this!
> > > >>
> > > >> +1 for this proposal.
> > > >>
> > > >> Sergey Nuyanzin <sn...@gmail.com> 于2025年7月29日周二 15:34写道:
> > > >>
> > > >>> Thanks for driving this Dawid.
> > > >>>
> > > >>> looks reasonable to me
> > > >>>
> > > >>> On Mon, Jul 28, 2025 at 5:03 PM Ramin Gharib <
> ramingharib@gmail.com>
> > > >>> wrote:
> > > >>>>
> > > >>>> Hello Dawid,
> > > >>>>
> > > >>>> Thanks for initiating this! The FLIP looks well-written.
> > > >>>> The WITH clause brings consistency to existing syntax.
> > > >>>>
> > > >>>> +1 for this proposal.
> > > >>>>
> > > >>>> On Mon, Jul 28, 2025 at 3:33 PM Dawid Wysakowicz <
> > > >> dwysakowicz@apache.org
> > > >>>>
> > > >>>> wrote:
> > > >>>>
> > > >>>>> Hi,
> > > >>>>> I'd like to start a discussion of FLIP-539: Support WITH Clause
> in
> > > >>> CREATE
> > > >>>>> FUNCTION Statement in Flink SQL [1].
> > > >>>>>
> > > >>>>> The existing CREATE FUNCTION  statement in Flink SQL allows users
> > to
> > > >>>>> register user-defined functions (UDFs) by specifying the class
> name
> > > >>> and the
> > > >>>>> artifact (JAR) containing the implementation. While this design
> > > >> covers
> > > >>>>> common use cases, it lacks a declarative mechanism for
> associating
> > > >>>>> arbitrary properties or metadata with the function at creation
> > time.
> > > >>>>>
> > > >>>>> Other Flink SQL objects—such as tables—support a WITH  clause for
> > > >>>>> specifying options in a key-value fashion, improving consistency,
> > > >>>>> discoverability, and extensibility.
> > > >>>>> Looking forward to comments and suggestions for improvements!
> > > >>>>>
> > > >>>>> Best,
> > > >>>>> Dawid
> > > >>>>>
> > > >>>>> [1] https://cwiki.apache.org/confluence/x/sg9JFg
> > > >>>>>
> > > >>>
> > > >>>
> > > >>>
> > > >>> --
> > > >>> Best regards,
> > > >>> Sergey
> > > >>>
> > > >>
> > > >
> > >
> > >
> >
>

Re: [DISCUSS] FLIP-539: Support WITH Clause in CREATE FUNCTION Statement in Flink SQL

Posted by Hao Li <hl...@confluent.io.INVALID>.
Hi Dawid,

Thanks for the FLIP. +1 to support options for functions as well.

I have one question:
Do you want to update `createTemporarySystemFunction` in `TableEnvironment`
to support `FunctionDescriptor` as well?

Thanks,
Hao

On Tue, Jul 29, 2025 at 10:33 AM Yash Anand <ya...@gmail.com>
wrote:

> Hi Dawid,
>
> Thank you for initiating this FLIP, looks like a useful addition +1 for the
> FLIP.
>
> I have just one question, will the option keys be limited to some
> predefined values or it could be any key user wants to add as metadata?
> Like if the user wants to add a description for each argument?
>
> On Tue, Jul 29, 2025 at 7:09 AM Timo Walther <tw...@apache.org> wrote:
>
> > Maybe not in the first version but eventually nothing in the design
> > blocks us for supporting this. The SecretStore would need to be
> > available in the FunctionDefinitionFactory for this.
> >
> > Cheers,
> > Timo
> >
> > On 29.07.25 15:08, Ryan van Huuksloot wrote:
> > > Overall the FLIP looks good to me.
> > >
> > > Would the properties support the SecretStore proposed in FLIP-529?
> > >
> > > Otherwise, +1, thanks!
> > >
> > > Ryan van Huuksloot
> > > Staff Engineer, Infrastructure | Streaming Platform
> > > [image: Shopify]
> > > <
> https://www.shopify.com/?utm_medium=salessignatures&utm_source=hs_email
> > >
> > >
> > >
> > > On Tue, Jul 29, 2025 at 4:19 AM Jacky Lau <li...@gmail.com>
> wrote:
> > >
> > >> Thanks for initiating this!
> > >>
> > >> +1 for this proposal.
> > >>
> > >> Sergey Nuyanzin <sn...@gmail.com> 于2025年7月29日周二 15:34写道:
> > >>
> > >>> Thanks for driving this Dawid.
> > >>>
> > >>> looks reasonable to me
> > >>>
> > >>> On Mon, Jul 28, 2025 at 5:03 PM Ramin Gharib <ra...@gmail.com>
> > >>> wrote:
> > >>>>
> > >>>> Hello Dawid,
> > >>>>
> > >>>> Thanks for initiating this! The FLIP looks well-written.
> > >>>> The WITH clause brings consistency to existing syntax.
> > >>>>
> > >>>> +1 for this proposal.
> > >>>>
> > >>>> On Mon, Jul 28, 2025 at 3:33 PM Dawid Wysakowicz <
> > >> dwysakowicz@apache.org
> > >>>>
> > >>>> wrote:
> > >>>>
> > >>>>> Hi,
> > >>>>> I'd like to start a discussion of FLIP-539: Support WITH Clause in
> > >>> CREATE
> > >>>>> FUNCTION Statement in Flink SQL [1].
> > >>>>>
> > >>>>> The existing CREATE FUNCTION  statement in Flink SQL allows users
> to
> > >>>>> register user-defined functions (UDFs) by specifying the class name
> > >>> and the
> > >>>>> artifact (JAR) containing the implementation. While this design
> > >> covers
> > >>>>> common use cases, it lacks a declarative mechanism for associating
> > >>>>> arbitrary properties or metadata with the function at creation
> time.
> > >>>>>
> > >>>>> Other Flink SQL objects—such as tables—support a WITH  clause for
> > >>>>> specifying options in a key-value fashion, improving consistency,
> > >>>>> discoverability, and extensibility.
> > >>>>> Looking forward to comments and suggestions for improvements!
> > >>>>>
> > >>>>> Best,
> > >>>>> Dawid
> > >>>>>
> > >>>>> [1] https://cwiki.apache.org/confluence/x/sg9JFg
> > >>>>>
> > >>>
> > >>>
> > >>>
> > >>> --
> > >>> Best regards,
> > >>> Sergey
> > >>>
> > >>
> > >
> >
> >
>

Re: [DISCUSS] FLIP-539: Support WITH Clause in CREATE FUNCTION Statement in Flink SQL

Posted by Yash Anand <ya...@gmail.com>.
Hi Dawid,

Thank you for initiating this FLIP, looks like a useful addition +1 for the
FLIP.

I have just one question, will the option keys be limited to some
predefined values or it could be any key user wants to add as metadata?
Like if the user wants to add a description for each argument?

On Tue, Jul 29, 2025 at 7:09 AM Timo Walther <tw...@apache.org> wrote:

> Maybe not in the first version but eventually nothing in the design
> blocks us for supporting this. The SecretStore would need to be
> available in the FunctionDefinitionFactory for this.
>
> Cheers,
> Timo
>
> On 29.07.25 15:08, Ryan van Huuksloot wrote:
> > Overall the FLIP looks good to me.
> >
> > Would the properties support the SecretStore proposed in FLIP-529?
> >
> > Otherwise, +1, thanks!
> >
> > Ryan van Huuksloot
> > Staff Engineer, Infrastructure | Streaming Platform
> > [image: Shopify]
> > <https://www.shopify.com/?utm_medium=salessignatures&utm_source=hs_email
> >
> >
> >
> > On Tue, Jul 29, 2025 at 4:19 AM Jacky Lau <li...@gmail.com> wrote:
> >
> >> Thanks for initiating this!
> >>
> >> +1 for this proposal.
> >>
> >> Sergey Nuyanzin <sn...@gmail.com> 于2025年7月29日周二 15:34写道:
> >>
> >>> Thanks for driving this Dawid.
> >>>
> >>> looks reasonable to me
> >>>
> >>> On Mon, Jul 28, 2025 at 5:03 PM Ramin Gharib <ra...@gmail.com>
> >>> wrote:
> >>>>
> >>>> Hello Dawid,
> >>>>
> >>>> Thanks for initiating this! The FLIP looks well-written.
> >>>> The WITH clause brings consistency to existing syntax.
> >>>>
> >>>> +1 for this proposal.
> >>>>
> >>>> On Mon, Jul 28, 2025 at 3:33 PM Dawid Wysakowicz <
> >> dwysakowicz@apache.org
> >>>>
> >>>> wrote:
> >>>>
> >>>>> Hi,
> >>>>> I'd like to start a discussion of FLIP-539: Support WITH Clause in
> >>> CREATE
> >>>>> FUNCTION Statement in Flink SQL [1].
> >>>>>
> >>>>> The existing CREATE FUNCTION  statement in Flink SQL allows users to
> >>>>> register user-defined functions (UDFs) by specifying the class name
> >>> and the
> >>>>> artifact (JAR) containing the implementation. While this design
> >> covers
> >>>>> common use cases, it lacks a declarative mechanism for associating
> >>>>> arbitrary properties or metadata with the function at creation time.
> >>>>>
> >>>>> Other Flink SQL objects—such as tables—support a WITH  clause for
> >>>>> specifying options in a key-value fashion, improving consistency,
> >>>>> discoverability, and extensibility.
> >>>>> Looking forward to comments and suggestions for improvements!
> >>>>>
> >>>>> Best,
> >>>>> Dawid
> >>>>>
> >>>>> [1] https://cwiki.apache.org/confluence/x/sg9JFg
> >>>>>
> >>>
> >>>
> >>>
> >>> --
> >>> Best regards,
> >>> Sergey
> >>>
> >>
> >
>
>

Re: [DISCUSS] FLIP-539: Support WITH Clause in CREATE FUNCTION Statement in Flink SQL

Posted by Timo Walther <tw...@apache.org>.
Maybe not in the first version but eventually nothing in the design 
blocks us for supporting this. The SecretStore would need to be 
available in the FunctionDefinitionFactory for this.

Cheers,
Timo

On 29.07.25 15:08, Ryan van Huuksloot wrote:
> Overall the FLIP looks good to me.
> 
> Would the properties support the SecretStore proposed in FLIP-529?
> 
> Otherwise, +1, thanks!
> 
> Ryan van Huuksloot
> Staff Engineer, Infrastructure | Streaming Platform
> [image: Shopify]
> <https://www.shopify.com/?utm_medium=salessignatures&utm_source=hs_email>
> 
> 
> On Tue, Jul 29, 2025 at 4:19 AM Jacky Lau <li...@gmail.com> wrote:
> 
>> Thanks for initiating this!
>>
>> +1 for this proposal.
>>
>> Sergey Nuyanzin <sn...@gmail.com> 于2025年7月29日周二 15:34写道:
>>
>>> Thanks for driving this Dawid.
>>>
>>> looks reasonable to me
>>>
>>> On Mon, Jul 28, 2025 at 5:03 PM Ramin Gharib <ra...@gmail.com>
>>> wrote:
>>>>
>>>> Hello Dawid,
>>>>
>>>> Thanks for initiating this! The FLIP looks well-written.
>>>> The WITH clause brings consistency to existing syntax.
>>>>
>>>> +1 for this proposal.
>>>>
>>>> On Mon, Jul 28, 2025 at 3:33 PM Dawid Wysakowicz <
>> dwysakowicz@apache.org
>>>>
>>>> wrote:
>>>>
>>>>> Hi,
>>>>> I'd like to start a discussion of FLIP-539: Support WITH Clause in
>>> CREATE
>>>>> FUNCTION Statement in Flink SQL [1].
>>>>>
>>>>> The existing CREATE FUNCTION  statement in Flink SQL allows users to
>>>>> register user-defined functions (UDFs) by specifying the class name
>>> and the
>>>>> artifact (JAR) containing the implementation. While this design
>> covers
>>>>> common use cases, it lacks a declarative mechanism for associating
>>>>> arbitrary properties or metadata with the function at creation time.
>>>>>
>>>>> Other Flink SQL objects—such as tables—support a WITH  clause for
>>>>> specifying options in a key-value fashion, improving consistency,
>>>>> discoverability, and extensibility.
>>>>> Looking forward to comments and suggestions for improvements!
>>>>>
>>>>> Best,
>>>>> Dawid
>>>>>
>>>>> [1] https://cwiki.apache.org/confluence/x/sg9JFg
>>>>>
>>>
>>>
>>>
>>> --
>>> Best regards,
>>> Sergey
>>>
>>
> 


Re: [DISCUSS] FLIP-539: Support WITH Clause in CREATE FUNCTION Statement in Flink SQL

Posted by Ryan van Huuksloot <ry...@shopify.com.INVALID>.
Overall the FLIP looks good to me.

Would the properties support the SecretStore proposed in FLIP-529?

Otherwise, +1, thanks!

Ryan van Huuksloot
Staff Engineer, Infrastructure | Streaming Platform
[image: Shopify]
<https://www.shopify.com/?utm_medium=salessignatures&utm_source=hs_email>


On Tue, Jul 29, 2025 at 4:19 AM Jacky Lau <li...@gmail.com> wrote:

> Thanks for initiating this!
>
> +1 for this proposal.
>
> Sergey Nuyanzin <sn...@gmail.com> 于2025年7月29日周二 15:34写道:
>
> > Thanks for driving this Dawid.
> >
> > looks reasonable to me
> >
> > On Mon, Jul 28, 2025 at 5:03 PM Ramin Gharib <ra...@gmail.com>
> > wrote:
> > >
> > > Hello Dawid,
> > >
> > > Thanks for initiating this! The FLIP looks well-written.
> > > The WITH clause brings consistency to existing syntax.
> > >
> > > +1 for this proposal.
> > >
> > > On Mon, Jul 28, 2025 at 3:33 PM Dawid Wysakowicz <
> dwysakowicz@apache.org
> > >
> > > wrote:
> > >
> > > > Hi,
> > > > I'd like to start a discussion of FLIP-539: Support WITH Clause in
> > CREATE
> > > > FUNCTION Statement in Flink SQL [1].
> > > >
> > > > The existing CREATE FUNCTION  statement in Flink SQL allows users to
> > > > register user-defined functions (UDFs) by specifying the class name
> > and the
> > > > artifact (JAR) containing the implementation. While this design
> covers
> > > > common use cases, it lacks a declarative mechanism for associating
> > > > arbitrary properties or metadata with the function at creation time.
> > > >
> > > > Other Flink SQL objects—such as tables—support a WITH  clause for
> > > > specifying options in a key-value fashion, improving consistency,
> > > > discoverability, and extensibility.
> > > > Looking forward to comments and suggestions for improvements!
> > > >
> > > > Best,
> > > > Dawid
> > > >
> > > > [1] https://cwiki.apache.org/confluence/x/sg9JFg
> > > >
> >
> >
> >
> > --
> > Best regards,
> > Sergey
> >
>

Re: [DISCUSS] FLIP-539: Support WITH Clause in CREATE FUNCTION Statement in Flink SQL

Posted by Jacky Lau <li...@gmail.com>.
Thanks for initiating this!

+1 for this proposal.

Sergey Nuyanzin <sn...@gmail.com> 于2025年7月29日周二 15:34写道:

> Thanks for driving this Dawid.
>
> looks reasonable to me
>
> On Mon, Jul 28, 2025 at 5:03 PM Ramin Gharib <ra...@gmail.com>
> wrote:
> >
> > Hello Dawid,
> >
> > Thanks for initiating this! The FLIP looks well-written.
> > The WITH clause brings consistency to existing syntax.
> >
> > +1 for this proposal.
> >
> > On Mon, Jul 28, 2025 at 3:33 PM Dawid Wysakowicz <dwysakowicz@apache.org
> >
> > wrote:
> >
> > > Hi,
> > > I'd like to start a discussion of FLIP-539: Support WITH Clause in
> CREATE
> > > FUNCTION Statement in Flink SQL [1].
> > >
> > > The existing CREATE FUNCTION  statement in Flink SQL allows users to
> > > register user-defined functions (UDFs) by specifying the class name
> and the
> > > artifact (JAR) containing the implementation. While this design covers
> > > common use cases, it lacks a declarative mechanism for associating
> > > arbitrary properties or metadata with the function at creation time.
> > >
> > > Other Flink SQL objects—such as tables—support a WITH  clause for
> > > specifying options in a key-value fashion, improving consistency,
> > > discoverability, and extensibility.
> > > Looking forward to comments and suggestions for improvements!
> > >
> > > Best,
> > > Dawid
> > >
> > > [1] https://cwiki.apache.org/confluence/x/sg9JFg
> > >
>
>
>
> --
> Best regards,
> Sergey
>

Re: [DISCUSS] FLIP-539: Support WITH Clause in CREATE FUNCTION Statement in Flink SQL

Posted by Sergey Nuyanzin <sn...@gmail.com>.
Thanks for driving this Dawid.

looks reasonable to me

On Mon, Jul 28, 2025 at 5:03 PM Ramin Gharib <ra...@gmail.com> wrote:
>
> Hello Dawid,
>
> Thanks for initiating this! The FLIP looks well-written.
> The WITH clause brings consistency to existing syntax.
>
> +1 for this proposal.
>
> On Mon, Jul 28, 2025 at 3:33 PM Dawid Wysakowicz <dw...@apache.org>
> wrote:
>
> > Hi,
> > I'd like to start a discussion of FLIP-539: Support WITH Clause in CREATE
> > FUNCTION Statement in Flink SQL [1].
> >
> > The existing CREATE FUNCTION  statement in Flink SQL allows users to
> > register user-defined functions (UDFs) by specifying the class name and the
> > artifact (JAR) containing the implementation. While this design covers
> > common use cases, it lacks a declarative mechanism for associating
> > arbitrary properties or metadata with the function at creation time.
> >
> > Other Flink SQL objects—such as tables—support a WITH  clause for
> > specifying options in a key-value fashion, improving consistency,
> > discoverability, and extensibility.
> > Looking forward to comments and suggestions for improvements!
> >
> > Best,
> > Dawid
> >
> > [1] https://cwiki.apache.org/confluence/x/sg9JFg
> >



-- 
Best regards,
Sergey

Re: [DISCUSS] FLIP-539: Support WITH Clause in CREATE FUNCTION Statement in Flink SQL

Posted by Ramin Gharib <ra...@gmail.com>.
Hello Dawid,

Thanks for initiating this! The FLIP looks well-written.
The WITH clause brings consistency to existing syntax.

+1 for this proposal.

On Mon, Jul 28, 2025 at 3:33 PM Dawid Wysakowicz <dw...@apache.org>
wrote:

> Hi,
> I'd like to start a discussion of FLIP-539: Support WITH Clause in CREATE
> FUNCTION Statement in Flink SQL [1].
>
> The existing CREATE FUNCTION  statement in Flink SQL allows users to
> register user-defined functions (UDFs) by specifying the class name and the
> artifact (JAR) containing the implementation. While this design covers
> common use cases, it lacks a declarative mechanism for associating
> arbitrary properties or metadata with the function at creation time.
>
> Other Flink SQL objects—such as tables—support a WITH  clause for
> specifying options in a key-value fashion, improving consistency,
> discoverability, and extensibility.
> Looking forward to comments and suggestions for improvements!
>
> Best,
> Dawid
>
> [1] https://cwiki.apache.org/confluence/x/sg9JFg
>