GithubHelp home page GithubHelp logo

Comments (4)

FZambia avatar FZambia commented on June 18, 2024 1

Hello @alouani-youssef ,

Centrifugo has its own protocol, are you using our bidirectional SDK to connect? If yes - please share the code and also full server logs (I suggest enabling "log_level": "trace") - not only last log message.

from centrifugo.

FZambia avatar FZambia commented on June 18, 2024 1

You are sending wrong JSON commands, that's why connection is closed. You need to use our SDKs to communicate with Centrifugo or use proper command structure (described here). See also docs on how to use Postman when you want to debug sth.

from centrifugo.

alouani-youssef avatar alouani-youssef commented on June 18, 2024

Hello @FZambia Those are the logs after enabling the log_level trace,
{"level":"debug","method":"GET","status":101,"path":"/connection/websocket","addr":"IP","duration":"269.45µs","time":"2024-03-07T11:02:10Z","message":"http request"} {"level":"trace","client":"e9b6aa27-c385-4cbb-b368-7d232d371570","command":"{\"id\":2}","user":"","time":"2024-03-07T11:02:10Z","message":"<--"} {"level":"info","client":"e9b6aa27-c385-4cbb-b368-7d232d371570","command":"id:2","reason":"bad request","user":"","time":"2024-03-07T11:02:10Z","message":"disconnect after handling command"} {"level":"debug","client":"e9b6aa27-c385-4cbb-b368-7d232d371570","duration":23.967399,"transport":"websocket","time":"2024-03-07T11:02:10Z","message":"client connection completed"} {"level":"debug","client":"e9b6aa27-c385-4cbb-b368-7d232d371570","reason":"bad request","user":"","time":"2024-03-07T11:02:10Z","message":"closing client connection"} {"level":"debug","method":"GET","status":101,"path":"/connection/websocket","addr":"IP","duration":"150.432µs","time":"2024-03-07T11:02:21Z","message":"http request"} {"level":"debug","client":"fd219032-aafe-4621-bf8f-d33026fdb219","transport":"websocket","time":"2024-03-07T11:02:21Z","message":"client connection established"} {"level":"trace","client":"fd219032-aafe-4621-bf8f-d33026fdb219","command":"{\"id\":94}","user":"","time":"2024-03-07T11:02:21Z","message":"<--"} {"level":"info","client":"fd219032-aafe-4621-bf8f-d33026fdb219","command":"id:94","reason":"bad request","user":"","time":"2024-03-07T11:02:21Z","message":"disconnect after handling command"} {"level":"debug","client":"fd219032-aafe-4621-bf8f-d33026fdb219","duration":49.836208,"transport":"websocket","time":"2024-03-07T11:02:21Z","message":"client connection completed"} {"level":"debug","client":"fd219032-aafe-4621-bf8f-d33026fdb219","reason":"bad request","user":"","time":"2024-03-07T11:02:21Z","message":"closing client connection"} {"level":"debug","method":"GET","status":101,"path":"/connection/websocket","addr":"IP","duration":"150.265µs","time":"2024-03-07T11:02:22Z","message":"http request"} {"level":"debug","client":"db7b311c-665e-4532-ac50-76d05f46777c","transport":"websocket","time":"2024-03-07T11:02:22Z","message":"client connection established"} {"level":"trace","client":"db7b311c-665e-4532-ac50-76d05f46777c","command":"{\"id\":3}","user":"","time":"2024-03-07T11:02:22Z","message":"<--"} {"level":"info","client":"db7b311c-665e-4532-ac50-76d05f46777c","command":"id:3","reason":"bad request","user":"","time":"2024-03-07T11:02:22Z","message":"disconnect after handling command"} {"level":"debug","client":"db7b311c-665e-4532-ac50-76d05f46777c","duration":40.359138,"transport":"websocket","time":"2024-03-07T11:02:22Z","message":"client connection completed"} {"level":"debug","client":"db7b311c-665e-4532-ac50-76d05f46777c","reason":"bad request","user":"","time":"2024-03-07T11:02:22Z","message":"closing client connection"} {"level":"debug","method":"GET","status":101,"path":"/connection/websocket","addr":"IP","duration":"87.581µs","time":"2024-03-07T11:02:23Z","message":"http request"} {"level":"debug","client":"0c9e3806-336a-4b6a-8368-6ceee41a563c","transport":"websocket","time":"2024-03-07T11:02:23Z","message":"client connection established"} {"level":"trace","client":"0c9e3806-336a-4b6a-8368-6ceee41a563c","command":"{\"id\":3}","user":"","time":"2024-03-07T11:02:23Z","message":"<--"} {"level":"info","client":"0c9e3806-336a-4b6a-8368-6ceee41a563c","command":"id:3","reason":"bad request","user":"","time":"2024-03-07T11:02:23Z","message":"disconnect after handling command"}

from centrifugo.

FZambia avatar FZambia commented on June 18, 2024

Closing, hope it helped. Join our community channels if you have any questions

from centrifugo.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.