Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Genesys PGR
Java Client API
Commits
96dc2037
Commit
96dc2037
authored
Jul 15, 2018
by
Matija Obreza
Browse files
Retry on Gateway timeout response
parent
39f2a0a0
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/main/java/org/genesys2/client/oauth/GenesysClient.java
View file @
96dc2037
...
...
@@ -267,7 +267,7 @@ public class GenesysClient {
LOG
.
error
(
new
String
(
postBody
));
LOG
.
error
(
"HTTP response code: {}"
,
response
.
getCode
());
LOG
.
error
(
"Response: {}"
,
responseBody
);
if
(
responseBody
.
contains
(
"Deadlock found when trying to get lock; try restarting transaction"
)
if
(
response
.
getCode
()
==
504
||
responseBody
.
contains
(
"Deadlock found when trying to get lock; try restarting transaction"
)
||
responseBody
.
contains
(
"nested exception is org.hibernate.exception.LockAcquisitionException: could not execute statement"
)
||
responseBody
.
contains
(
"nested exception is org.hibernate.exception.LockTimeoutException: could not execute statement"
))
{
throw
new
PleaseRetryException
(
responseBody
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment