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

REST API: The 'Accept-Language' request header is ignored when middleware service is invoked #23

Open
gorbunkov opened this issue Apr 16, 2019 · 0 comments
Labels
type: enhancement New feature or request
Milestone

Comments

@gorbunkov
Copy link
Contributor

Environment

  • Platform version: 6.10.9

Description of the bug or enhancement

If the middleware service is invoked with the standard rest api and the Accept-Language header is set in the request, then it is expected that UserSession in the service implementation will have the corresponding locale. However, it doesn't.

The problem is that REST API filter sets the locale from the Accept-Language header to the UserInvocationContext:

UserInvocationContext.setRequestScopeInfo(sessionId, locale, null, null, null);

When the middleware service is invoked after that, this value is not used.

Forum: https://www.cuba-platform.ru/discuss/t/ignoriruetsya-accept-language-pri-poluchenii-access-tokena-s-pomoshhyu-refresh-tokena-cherez-rest-api/2926

@knstvk knstvk transferred this issue from cuba-platform/cuba May 21, 2019
@knstvk knstvk added the type: enhancement New feature or request label May 21, 2019
@zaharchenko-evgeny zaharchenko-evgeny added this to the REST API 1.0 milestone May 21, 2019
@dtsaryov dtsaryov modified the milestones: REST API 1.0, 7.1 May 28, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

5 participants