Commits


James Duong authored and GitHub committed 5583dbeca4f
GH-38737: [Java] Fix JDBC caching of SqlInfo values (#38739) ### Rationale for this change The cache of SqlInfo properties that ArrowDatabaseMetaData maintains isn't populated in a thread-safe way. This can cause JDBC applications trying to retrieve several properties from DatabaseMetaData to encounter missing properties when they shouldn't. ### What changes are included in this PR? - Changed the checking for the cache being populated to be based on an AtomicBoolean marking that the cache is fully populated, rather than just checking if the cache is empty. - Avoid having multiple threads call getSqlInfo() if they see that the cache is empty concurrently. ### Are these changes tested? Verified existing unit tests. ### Are there any user-facing changes? No. * Closes: #38737 Authored-by: James Duong <james.duong@improving.com> Signed-off-by: David Li <li.davidm96@gmail.com>