Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: NPE in DatabaseMetaData.getTypeInfo when types are dropped concurrently #530

Closed
wants to merge 1 commit into from

Conversation

@vlsi
Copy link
Member

@vlsi vlsi commented Mar 7, 2016

DatabaseMetaData.getTypeInfo used several queries to load the data, thus the first of them
might observe some oid, then subsequent selects might fail to see it if the type was dropped.

The solution is not 100% bulletproof, however getTypeInfo always returns full info, thus it
is more likely to fail in a user-visible way.

See http://www.postgresql.org/message-id/9436a36d38164b35ba98a6a11c836068@MERCMBX49R.na.SAS.com

@vlsi vlsi force-pushed the vlsi:gettypeinfo_npe branch from 482cf74 to 96b68bd Mar 7, 2016
…rrently

DatabaseMetaData.getTypeInfo used several queries to load the data, thus the first of them
might observe some oid, then subsequent selects might fail to see it if the type was dropped.

The solution is not 100% bulletproof, however getTypeInfo always returns full info, thus it
is more likely to fail in a user-visible way.
@vlsi vlsi force-pushed the vlsi:gettypeinfo_npe branch from 96b68bd to 9898cef Mar 8, 2016
@codecov-io
Copy link

@codecov-io codecov-io commented Mar 8, 2016

Current coverage is 57.47%

Merging #530 into master will decrease coverage by -0.01% as of 7028025

@@            master    #530   diff @@
======================================
  Files          143     143       
  Stmts        15127   15129     +2
  Branches      2971    2971       
  Methods          0       0       
======================================
+ Hit           8695    8696     +1
+ Partial       1180    1178     -2
- Missed        5252    5255     +3

Review entire Coverage Diff as of 7028025

Powered by Codecov. Updated on successful CI builds.

@vlsi vlsi closed this in f3b0fd0 Mar 12, 2016
@vlsi vlsi deleted the vlsi:gettypeinfo_npe branch Mar 12, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

2 participants
You can’t perform that action at this time.