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

Unify http log #4258

Closed
TheOneRing opened this issue Dec 13, 2023 · 2 comments · Fixed by #4266
Closed

Unify http log #4258

TheOneRing opened this issue Dec 13, 2023 · 2 comments · Fixed by #4266
Assignees
Milestone

Comments

@TheOneRing
Copy link
Member

In owncloud/client#11224 (comment) we discussed starting the http log with

REQUEST x-id {
RESPONSE x-id {

The andorid client currently has the following format:

HTTP REQUEST: {
HTTP RESPONSE: {
@jesmrec jesmrec added this to the 4.2 - Current milestone Dec 13, 2023
@jesmrec jesmrec added Technical p3-medium Normal priority labels Dec 13, 2023
@Aitorbp
Copy link
Collaborator

Aitorbp commented Dec 15, 2023

In this issue the following problem will also be developed:
In some requests the following literal is appearing: "data": "<-- Body end for response -- Binary -- Omitted: 151 bytes -->". This is not correct, a Json should appear and not a binary.

@Aitorbp Aitorbp self-assigned this Dec 18, 2023
@Aitorbp Aitorbp mentioned this issue Dec 18, 2023
1 task
@Aitorbp Aitorbp linked a pull request Dec 18, 2023 that will close this issue
1 task
@jesmrec
Copy link
Collaborator

jesmrec commented Dec 22, 2023

new format:

D: 2023-12-22 10:29:14:435(LogInterceptor.kt:67)REQUEST 87c359e2-ed2d-4ab8-b52b-af36e33d8219 {"request":{"headers":{"X-Request-ID":"87c359e2-ed2d-4ab8-b52b-af36e33d8219","User-Agent":"Mozilla/5.0 (Android) ownCloud-android/4.2-beta.1","Accept-Language":"en","Accept-Encoding":"identity","Authorization":"Bearer [redacted]","Host":"159.69.153.173:9200","Connection":"Keep-Alive"},"info":{"id":"87c359e2-ed2d-4ab8-b52b-af36e33d8219","method":"GET","url":"https://159.69.153.173:9200/ocs/v2.php/cloud/user?format=json"}}}

D: 2023-12-22 10:29:14:445(LogInterceptor.kt:133)RESPONSE 87c359e2-ed2d-4ab8-b52b-af36e33d8219 {"response":{"body":{"data":"{\"ocs\":{\"meta\":{\"status\":\"ok\",\"statuscode\":200,\"message\":\"OK\"},\"data\":{\"id\":\"user1\",\"display-name\":\"Joe Smith\",\"email\":\"[email protected]\",\"user-type\":\"primary\"}}}","length":153},"headers":{"Content-Length":"153","Content-Type":"application/json; charset=utf-8","Date":"Fri, 22 Dec 2023 09:29:14 GMT","Ocs-Api-Version":"2","Vary":"Origin","X-Request-Id":"87c359e2-ed2d-4ab8-b52b-af36e33d8219"},"info":{"id":"87c359e2-ed2d-4ab8-b52b-af36e33d8219","method":"GET","reply":{"cached":false,"duration":166,"durationString":"duration(0h, 0min, 0s, 166ms)","status":200,"version":"http/1.1"},"url":"https://159.69.153.173:9200/ocs/v2.php/cloud/user?format=json"}}}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants