pgjdbc/pgjdbc GitHub issues and pull requests (mirror)  
help / color / mirror / Atom feed
From: jorsol (@jorsol) <[email protected]>
To: pgjdbc/pgjdbc <[email protected]>
Subject: Re: [pgjdbc/pgjdbc] PR #943: fix: synchronize modification of shared calendar (#921)
Date: Mon, 11 Sep 2017 20:20:47 +0000
Message-ID: <[email protected]> (raw)
In-Reply-To: <[email protected]>
References: <[email protected]>

> I agree, however it turns out lots of uses depend on Statement.getWarnings thread safety. E.g. #927 

Fully agree, as I said, some methods require thread safety, and it's fine for these, but not necessarily for all.

> I think added synchronization would not matter much performance-wise. Nor it would matter support-wise: some of the methods have already been synchronized, so it could make sense to make them aligned.

I haven't made any performance measure of performance implications of synchronization, maybe new JVM works better and the "synchronization is expensive" no longer apply, so if this is the case, then it make sense to have a thread-safety driver.

Some quotes from _Java Concurrency in Practice_:

> The JDBC specification does not require that Connection objects be thread-safe.

> Since JDBC connections may not be thread-safe, a multithreaded application that uses a global connection without additional coordination is not thread-safe either.

> Many official Java technology specifications, such as servlets and JDBC, woefully underdocument their thread safety promises and requirements.

view thread (29+ 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 #943: fix: synchronize modification of shared calendar (#921)
  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