Skip to content

[DE-55] Retry case of error 503(without 'x-arango-endpoint') #530

Closed
@ajw227

Description

@ajw227

Related

arangodb/arangojs#710

Description

When coordinator is start, it reponse 503 error about few seconds.
If you get a 503 error, I think calling a different coordinator will solve it.

  1. error 503. contains 'x-arango-endpoint' header : OK
  2. error 503. except 'x-arango-endpoint' header : Response Error.
com.arangodb.ArangoDBException: Response: 503, Error: 503 - service unavailable due to startup or maintenance mode

Proposal

https://github.com/arangodb/arangodb-java-driver/blob/main/core/src/main/java/com/arangodb/internal/net/Communication.java#L102

                            } else if (errorEntityEx != null) {
                                if(errorEntityEx.getErrorNum() == 503) { //Add this line case of maintenance or startup mode.
                                    handleException(true, errorEntityEx, hostHandle, request, host, reqId, attemptCount, rfuture);
                                } else {
                                    rfuture.completeExceptionally(errorEntityEx);
                                }
                            } else {

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions