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

docs/chore: Add DEADLOCK_DETECTED Enumeration #1380

Merged
merged 1 commit into from Jan 7, 2019

Conversation

@deanmarc25
Copy link
Contributor

@deanmarc25 deanmarc25 commented Jan 2, 2019

include an additional value to represent the PostgreSQL error code for the condition "deadlock_detected". This is used for client error handling code, similar to (I assume), OBJECT_IN_USE

This is a personal issue that I came across today when attempting to handle deadlock exceptions, I am trying to avoid hard coding error codes in the applications.

All Submissions:

  • [X ] Have you followed the guidelines in our Contributing document?
  • [X ] Have you checked to ensure there aren't other open Pull Requests for the same update/change?
This commit includes an additional value to represent the PostgreSQL error code for the condition "deadlock_detected".

- Include enum value for DEADLOCK_DETECTED PSQLState
- Set value to "40P01" per documentation located at: https://www.postgresql.org/docs/current/errcodes-appendix.html
@codecov-io
Copy link

@codecov-io codecov-io commented Jan 2, 2019

Codecov Report

Merging #1380 into master will increase coverage by <.01%.
The diff coverage is 100%.

@@             Coverage Diff              @@
##             master    #1380      +/-   ##
============================================
+ Coverage     68.71%   68.72%   +<.01%     
  Complexity     3894     3894              
============================================
  Files           179      179              
  Lines         16393    16394       +1     
  Branches       2668     2668              
============================================
+ Hits          11264    11266       +2     
+ Misses         3881     3880       -1     
  Partials       1248     1248

@davecramer davecramer merged commit a7f63bf into pgjdbc:master Jan 7, 2019
2 checks passed
@deanmarc25 deanmarc25 deleted the add_deadlock_sql_state branch Jan 7, 2019
davecramer added a commit to davecramer/pgjdbc that referenced this issue Jul 5, 2021
This commit includes an additional value to represent the PostgreSQL error code for the condition "deadlock_detected".

- Include enum value for DEADLOCK_DETECTED PSQLState
- Set value to "40P01" per documentation located at: https://www.postgresql.org/docs/current/errcodes-appendix.html
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

3 participants