pgjdbc/pgjdbc GitHub issues and pull requests (mirror)  
help / color / mirror / Atom feed
From: jrobe (@jrobe) <[email protected]>
To: pgjdbc/pgjdbc <[email protected]>
Subject: Re: [pgjdbc/pgjdbc] PR #2923: un-deprecate SSL_FACTORY_ARG
Date: Thu, 29 Jun 2023 15:53:51 +0000
Message-ID: <[email protected]> (raw)
In-Reply-To: <[email protected]>
References: <[email protected]>

> > Adding support for the Property based constructor is fine for our own code, but needless breaking everybody else
> 
> Could you please clarify how adding `Property` based constructor breaks everybody else code?
> 
> Property-based constructor would be a replacement for string-based one.

Here's the thing; other users have no way of adding custom properties to DataSource-based connections if they're wrapped by some other datasource passing them down. E.g. we should either deprecate this and add a separate property recognized by BaseDataSource, or do what [sehrope](https://github.com/sehrope) recommends, which is to allow setting user.[x] properties, and support them in the BaseDataSource.

I have a custom SSLSocketFactory class, and to configure it I need to be able to have at least one BaseDataSource property that I can use that can be the argument(s) I need for that class.

I'm hitting this issue with the aws-advanced-jdbc-wrapper, which doesn't work well with Hikari unless it uses a DataSource (PGSimpleDataSource in this case). That wrapper takes in a properties argument that can be set, which is applied to the base data-source. Driver-based I can set whatever property I want, but when using a data-source I'm limited to what the getters/setters on the datasource have; which means I need SSLFactoryArg (or some equivalent) to setup my custom SSLFactory class.

1. Deprecating something that you plan on supporting forever isn't the right thing to do.
2. Having no alternative to have a DataSource support sending arguments to a custom SSLFactory and removing this will certainly break a bunch of code and also isn't the right thing to do.

view thread (26+ messages)  latest in thread

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: github://pgjdbc/pgjdbc
  Cc: [email protected], [email protected]
  Subject: Re: [pgjdbc/pgjdbc] PR #2923: un-deprecate SSL_FACTORY_ARG
  In-Reply-To: <<[email protected]>>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox