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

Encoding document to json with JSON_UNESCAPED_UNICODE #559

Closed
rauanmayemir opened this issue Feb 21, 2014 · 4 comments
Closed

Encoding document to json with JSON_UNESCAPED_UNICODE #559

rauanmayemir opened this issue Feb 21, 2014 · 4 comments

Comments

@rauanmayemir
Copy link
Contributor

May I suggest to use additional options JSON_UNESCAPED_UNICODE and JSON_PRETTY_PRINT for content encoding? (the latter is not critical though)

Both options mostly are helpful for those who often play around with direct curl/browser queries

JSON_UNESCAPED_UNICODE is useful for non-latin texts, otherwise you end up with something like

"_source" : {"title":"\u041e\u0411\u0429\u0415\u0421\u0422\u0412\u0415\u041d\u041d\u041e\u0415"}

JSON_PRETTY_PRINT - readable tabbed json.

Case is similar to #464 and is pretty trivial to implement.
I can provide separate pull-request.

@ruflin
Copy link
Owner

ruflin commented Feb 22, 2014

Can you open a pull request with some tests and perhaps you can merge the changes from #464 in as well as they were never merged?

@rauanmayemir
Copy link
Contributor Author

Sure, I'll do it.

Btw, JSON_PRETTY_PRINT seems to cause some troubles in http transport. I assume it's because of new lines in command, so i rolled back and leaved only unicode stuff.

@ruflin
Copy link
Owner

ruflin commented Feb 24, 2014

Ok. Let me know when you open the pull request.

@ruflin
Copy link
Owner

ruflin commented Mar 8, 2014

Closed with merge of pull request #560

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

No branches or pull requests

2 participants