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

Custom headers don't override the default ones #141

Open
2 tasks done
panovitch opened this issue Jul 14, 2021 · 0 comments · May be fixed by #142
Open
2 tasks done

Custom headers don't override the default ones #141

panovitch opened this issue Jul 14, 2021 · 0 comments · May be fixed by #142

Comments

@panovitch
Copy link

panovitch commented Jul 14, 2021

Steps to reproduce:

  1. Pass a custom header to override the default one, e.g. client-request-id:
Payment.create(
    new Amount("123", "EUR"),
    new Pointer("IBAN", "mockiban"),
    "description",
    123,
    null,
    null,
    false,
    Map(
      BunqHeader.CLIENT_REQUEST_ID.toString -> "123"
    ).toJava)

What should happen:

  1. The specified request header gets passed to the server, and the server recognises the Client Request ID.

What happens:

  1. The server doesnt recognise the passed client request ID, and doesnt deduplicate the requests. Upon further investigation, I found out that the new header value gets appended to the header key, instead of replacing it.

Traceback

SDK version and environment

  • Tested on 1.14.1
  • Sandbox
  • Production

Response id

  • Response id:

Extra info:

panovitch pushed a commit to panovitch/sdk_java that referenced this issue Jul 14, 2021
@panovitch panovitch linked a pull request Jul 14, 2021 that will close this issue
1 task
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant