Author Topic: Maybe... Websockets?!!  (Read 1560 times)

0 Members and 1 Guest are viewing this topic.

Offline username1565

  • Occasional poster
  • *
  • Posts: 35
    • View Profile
Maybe... Websockets?!!
« on: October 23, 2019, 01:14:52 AM »
Is there any ability for HFS to working with WEBSOCKETS?
I cann't found keyword "websockets" on this forum.
Can you realize this ability? In this case, users can chat with server, using only one connection,
and no need to send many XHR-queries and open many connections.
I have Websocket server, writted on c# here: https://github.com/username1565/Fleck2
See source code, and this issue: https://github.com/username1565/Fleck2/issues/1
For introduction, and test this, if you still have not work with Websockets.

Have a nice day!
« Last Edit: October 23, 2019, 01:16:56 AM by username1565 »

Offline rejetto

  • Administrator
  • Tireless poster
  • *
  • Posts: 13010
    • View Profile
Re: Maybe... Websockets?!!
« Reply #1 on: October 23, 2019, 12:44:23 PM »
hi, websockets are nice, but hfs is missing much more basic features, considering its file-server nature :)

Offline Mars

  • Operator
  • Tireless poster
  • *****
  • Posts: 1911
    • View Profile
Re: Maybe... Websockets?!!
« Reply #2 on: October 23, 2019, 08:41:30 PM »
@1565

You can convert your websockets server as a proxy to translate request to hfs with some spécial section

Offline username1565

  • Occasional poster
  • *
  • Posts: 35
    • View Profile
Re: Maybe... Websockets?!!
« Reply #3 on: October 23, 2019, 10:11:32 PM »
@1565

You can convert your websockets server as a proxy to translate request to hfs with some spécial section
Ok. Good. But I think, will be better to you can realize this as separate internal module.
For example, to do live updating the dynamic data, or chat, or show the stats about downloading on the webpage,
will be better to keep one connection with client,
and do not accept from this client many connections, after sending each query on the server,
which will be closed by client, after receive response.
But if you offer to open many connections on the proxy, then this websocket-connection have no any sence,
and server loading still not will be lower. ;D

hi, websockets are nice, but hfs is missing much more basic features, considering its file-server nature :)
I just leaved it here, because if you have free time, you can just for fun, see the documentation, about how it works,
and see that source code, about how to implement it, up to .NET Framework 2.0,
and maybe, using this code, you can implement this too, but on Objective Pascal, and more easy.

Cheers!
« Last Edit: October 23, 2019, 10:17:11 PM by username1565 »

Offline bmartino1

  • Tireless poster
  • ****
  • Posts: 887
  • I'm only trying to help i mean no offense.
    • View Profile
    • My HFS Google Drive Shared Link
Re: Maybe... Websockets?!!
« Reply #4 on: October 26, 2019, 09:41:10 PM »
may be with ubuntu wine and some iptable/ firewall commands.
I'm only trying to help i mean no offense.
thank you for your time and patience,
Bmartino1

Offline rejetto

  • Administrator
  • Tireless poster
  • *
  • Posts: 13010
    • View Profile
Re: Maybe... Websockets?!!
« Reply #5 on: January 30, 2020, 06:06:28 PM »
my attempt at building HFS 3 included websockets, with real-time refreshing of the file list :)
https://github.com/rejetto/hfs

sadly i don't have currently time to bring on that project

Offline dj

  • Tireless poster
  • ****
  • Posts: 166
  • 👣 🐾
    • View Profile
    • PWAs
Re: Maybe... Websockets?!!
« Reply #6 on: February 01, 2020, 07:20:11 AM »
you can use Server-sent events

I've used it last in Video player to watch with friends and earlier in my Chat application

Offline rejetto

  • Administrator
  • Tireless poster
  • *
  • Posts: 13010
    • View Profile
Re: Maybe... Websockets?!!
« Reply #7 on: February 03, 2020, 03:59:05 PM »
SSE is interesting for cases when it's hard to get websockets.
At work we created something very similar 1 year ago, not knowing this standard, otherwise we would have followed it.
Pity Edge doesn't support it.

Offline dj

  • Tireless poster
  • ****
  • Posts: 166
  • 👣 🐾
    • View Profile
    • PWAs
Re: Maybe... Websockets?!!
« Reply #8 on: February 03, 2020, 05:11:18 PM »
Edge79 (is being rolled out. I don't have it yet) supports it

in my aforementioned apps I fallback to polling if not supported


Offline rejetto

  • Administrator
  • Tireless poster
  • *
  • Posts: 13010
    • View Profile
Re: Maybe... Websockets?!!
« Reply #9 on: February 04, 2020, 03:37:12 PM »