You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Kevin Huntly <km...@gmail.com> on 2023/04/21 13:35:19 UTC

MySQL Connection settings

Hi Everyone,

I'm not a DBA nor do I pretend to be, so I'm asking what everyone's
thoughts are on MySQL connection string settings? What are the best options
to use, what options are absolutely required, etc?
________________________________________________

Kevin Huntly
Email: kmhuntly@gmail.com
Cell: 716/424-3311
________________________________________________

-----BEGIN GEEK CODE BLOCK-----
Version: 1.0
GCS/IT d+ s a C++ UL+++$ P+(++) L+++ E---
W+++ N+ o K(+) w--- O- M-- V-- PS+ PE Y(+)
PGP++(+++) t+ 5-- X-- R+ tv+ b++  DI++ D++
G++ e(+) h--- r+++ y+++*
------END GEEK CODE BLOCK------

Re: [OT] MySQL Connection settings

Posted by Christopher Schultz <ch...@christopherschultz.net>.
Kevin,

On 4/21/23 14:19, Kevin Huntly wrote:
> in general. something all purpose to get started with
> 
> On Fri, Apr 21, 2023, 14:17 Christopher Schultz <
> chris@christopherschultz.net> wrote:
> 
>> Kevin,
>>
>> On 4/21/23 09:35, Kevin Huntly wrote:
>>> I'm not a DBA nor do I pretend to be, so I'm asking what everyone's
>>> thoughts are on MySQL connection string settings? What are the best
>> options
>>> to use, what options are absolutely required, etc?
>>
>> Just ... in general? Or do you have a specific use-case?

Uhh... I would recommend getting the host, port, and database correct, 
otherwise you'll be disappointed. Everything after that is pretty much 
up to you.

Are you using clustering or a multi-primary setup? Are you using a db 
load-balancer (e.g. haproxy or similar)?

What does your code expect when datetime values are all zeros?

Do you care about security? You should. I recommend encrypting all 
connections, regardless of the network configuration.

At $work, we have collected a bunch of settings over the years that we 
have been required to set. Some of them may no longer be necessary, but 
they are all things we've tripped over.

There is nothing the driver can do to significantly improve performance 
of the database other than:

1. Configuring how prepared statements are done: client-side or 
server-side. Server-side prepared statements were broken for a good long 
time, but all the references to Oracle's documentation I had for that 
issue have disappeared online :(

2. Provide pooling, which really should be handled by your application 
(or Tomcat in the case of a web application).

-chris

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: [OT] MySQL Connection settings

Posted by Kevin Huntly <km...@gmail.com>.
in general. something all purpose to get started with

On Fri, Apr 21, 2023, 14:17 Christopher Schultz <
chris@christopherschultz.net> wrote:

> Kevin,
>
> On 4/21/23 09:35, Kevin Huntly wrote:
> > I'm not a DBA nor do I pretend to be, so I'm asking what everyone's
> > thoughts are on MySQL connection string settings? What are the best
> options
> > to use, what options are absolutely required, etc?
>
> Just ... in general? Or do you have a specific use-case?
>
> -chris
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
>

Re: [OT] MySQL Connection settings

Posted by Christopher Schultz <ch...@christopherschultz.net>.
Kevin,

On 4/21/23 09:35, Kevin Huntly wrote:
> I'm not a DBA nor do I pretend to be, so I'm asking what everyone's
> thoughts are on MySQL connection string settings? What are the best options
> to use, what options are absolutely required, etc?

Just ... in general? Or do you have a specific use-case?

-chris

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org