Skip to content

Commit 991a26f

Browse files
committed
added accept and content-type headers to VST messages
1 parent 47d022d commit 991a26f

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

ChangeLog.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) a
66

77
## [Unreleased]
88

9+
- fixed VST communication adding `accept` and `content-type` headers
10+
911
## [6.7.0] - 2020-07-01
1012

1113
- added support of schema validation (ArangoDB v3.7)

src/main/java/com/arangodb/internal/velocystream/VstCommunication.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,9 @@ protected Response createResponse(final Message message) throws VPackParserExcep
149149
return response;
150150
}
151151

152-
protected Message createMessage(final Request request) throws VPackParserException {
152+
protected final Message createMessage(final Request request) throws VPackParserException {
153+
request.putHeaderParam("accept", "application/x-velocypack");
154+
request.putHeaderParam("content-type", "application/x-velocypack");
153155
final long id = mId.incrementAndGet();
154156
return new Message(id, util.serialize(request), request.getBody());
155157
}

0 commit comments

Comments
 (0)