Back

[FEAT] Disable websocket from console

  • 0
  • Self Hosted
Bouahaza
8 Jun, 2023, 10:44

Is it a way to disable websocket from console ? I remove service from docker-compose but it's instanciate on console whatever page I'm on (to know realtime connections stats I thinks ?)

TypeScript
appwrite                      | [Error] Timestamp: 2023-06-08T10:43:38+00:00
appwrite                      | [Error] Type: Utopia\Exception
appwrite                      | [Error] Message: Not Found
appwrite                      | [Error] File: /usr/src/code/vendor/utopia-php/framework/src/App.php
appwrite                      | [Error] Line: 803
TypeScript
Realtime got disconnected. Reconnect will be attempted in 10 seconds. 
TL;DR
The user wants to disable the websocket from the console and is looking for a way to do it. They have tried removing the service from docker-compose but it still gets instantiated on the console. They encountered an error message related to the websocket and received a "Realtime got disconnected" message. They suggested implementing a feature to disable the websocket from the console. There is currently no solution mentioned in the thread.
joeyouss
8 Jun, 2023, 13:36

Hey

joeyouss
8 Jun, 2023, 13:37

seems like it isnt possible as of now, but would make a cool feature request

Bouahaza
8 Jun, 2023, 14:07
Bouahaza
8 Jun, 2023, 14:07

[FEAT] Disable websocket from console

Drake
8 Jun, 2023, 14:27

why did you disable it from docker-compose?

Bouahaza
8 Jun, 2023, 14:27

Cause I don't need it

Drake
8 Jun, 2023, 14:28

but the console does 😜 does the realtime container really use that much resources?

Bouahaza
8 Jun, 2023, 14:29

Use for stats on dashboard only no ?

Bouahaza
8 Jun, 2023, 14:30

Not much, but while we don't need.. WE also disable mail and sms workers

Drake
8 Jun, 2023, 14:30

for automatically updating things like:

  • when an attribute is ready
  • custom domain gets verified
  • function build is complete
  • function execution status
Bouahaza
8 Jun, 2023, 14:31

Ok, then I'll just remove traefik config on so, should be ok right ? While it use docker network to communicate

Drake
8 Jun, 2023, 14:33

that won't work because then nothing would be able to connect...and the console needs to connect

Bouahaza
8 Jun, 2023, 14:33

Oh yes from console, I forget it..

Bouahaza
8 Jun, 2023, 14:36

It's from 1.3.7 no ? Cause before I havn't this errors

Drake
8 Jun, 2023, 16:29

im pretty sure we've always used realtime in the console

Bouahaza
8 Jun, 2023, 16:32

Just find that it's because on local we use dev.my.company.com domain, with SSL certificate error, wich stop ServiceWorker loading. So it can't connect to realtime workers, and don't emit logs

Bouahaza
8 Jun, 2023, 16:33

That's why I thinks it's new 😅

Bouahaza
8 Jun, 2023, 16:40

FYI, in our case, realtime will not works on console (for production) cause we can only connect to console via ssh tunnel and domain set on .env file isn't a real domain. To access appwrite API, we use multiples cloudflare workers wich connect to appwrite via docker network via cloudflare tunnel. So in our case it make sense to completly disable realtime worker (having to refresh the interface isn't a big deal) but I understand that you can't fit all differents workflow.

Thinks it can be usefull to be able to completly disable realtime via project settings, like disable graphql, or (better) via .env

Drake
8 Jun, 2023, 16:46

ya disabling realtime via project settings could be a good idea.

Bouahaza
8 Jun, 2023, 16:49

I update github issue accordingly

Reply

Reply to this thread by joining our Discord

Reply on Discord

Need support?

Join our Discord

Get community support by joining our Discord server.

Join Discord

Get premium support

Join Appwrite Pro and get email support from our team.

Learn more