Giter Club home page Giter Club logo

Comments (15)

StefanS-O avatar StefanS-O commented on June 15, 2024 2

I will start looking into this after launch, this is not a milestone 1 issue and also needs decissions from @ChrisLAS where this should be hosted.

from jupiterbroadcasting.com.

reesericci avatar reesericci commented on June 15, 2024 1

CF KV is an excellent solution, I just didn't want to use it if JB wasn't going to utilize CF workers for deploying this.

from jupiterbroadcasting.com.

reesericci avatar reesericci commented on June 15, 2024 1

I also built it on top of the Deno runtime which is not supported by CF, only themselves (Deno Deploy) and Netlify from what I remember.

from jupiterbroadcasting.com.

elreydetoda avatar elreydetoda commented on June 15, 2024 1

Deno isn't node so it wouldn't work

Ya, I was mainly asking if you knew the runtime that they use, not trying to say deno is node 🙃

from jupiterbroadcasting.com.

elreydetoda avatar elreydetoda commented on June 15, 2024 1

for realtime updates Cloudflare's Pub/Sub: https://developers.cloudflare.com/pub-sub/ could possibly work instead of self-hosting a pub/sub solution.
As it turns out, redis has a builtin Pub/Sub function: https://redis.io/docs/manual/pubsub/

Cool! So redis could be used for local dev and Cloudflare could be used for prod?

I wouldn't start working on modifing it (unless you want to) until you get a JB person's (or others via proxy (@StefanS-O or someone similar) ) opinion which solution they'd like more. (Self-hosting redis, cloudflare KV or Pub/Sub, etc...)

It's honestly up to them for whatever is easiest to implement/maintain + what's needed.

I was honestly just asking, because I was curious 😅

from jupiterbroadcasting.com.

reesericci avatar reesericci commented on June 15, 2024

I got a basic deno serverless/edge function working that stores a JSON object that looks like this in redis:

{ 
  "title": "Jupiter Broadcasting,
  "chatroom": "irc.geekshed.net"
}

then makes it accessible from a GET request (e.g. when the page loads) and allows POST/DELETE requests with a JWT signed with an RSA key pair to update that object

I'm unsure if it's a good idea to set up a system to notify clients, people viewing the website or possibly a background service worker, about any changes realtime instead of the website checking whenever it's loaded. Then clients could be notified right away that JB went live, but it's a complex system to set up and would require a server to handle the subscriptions. (because the clients would be behind NAT and a callback URL wouldn't work) I don't think regular HTTP polling is a good idea because of bandwidth costing money.

from jupiterbroadcasting.com.

reesericci avatar reesericci commented on June 15, 2024

Serverless function gist: https://gist.github.com/reesericci/2875f2049993c0fea7b67abf1eb1984a

from jupiterbroadcasting.com.

reesericci avatar reesericci commented on June 15, 2024

@StefanS-O is there any pipeline for deploying a serverless function? (i.e. vercel, netlify, cloudflare workers, deno, etc)

from jupiterbroadcasting.com.

elreydetoda avatar elreydetoda commented on June 15, 2024

@StefanS-O is there any pipeline for deploying a serverless function? (i.e. vercel, netlify, cloudflare workers, deno, etc)

I know I'm not Stefan, but from my observation of the infrastructure there isn't. If you just do an nslookup on the website domain:

$ nslookup jupiterbroadcasting.net 8.8.8.8
Server:         8.8.8.8
Address:        8.8.8.8#53

Non-authoritative answer:
Name:   jupiterbroadcasting.net
Address: 142.132.186.250

And a whois on the returned IP address, you'll see that it's an IP address controlled by hetzner.com (which is a hosting company similar to Linode).

If they use more of cloudflare (reasons mentioned here), you should be able to use cloudflare workers.

from jupiterbroadcasting.com.

elreydetoda avatar elreydetoda commented on June 15, 2024

Also, I know I haven't really commented on this issue before, and am definitely not very familiar with redis, but if you're looking for a KV store is there a reason for not using a hosted service like this: https://www.cloudflare.com/products/workers-kv/

I've never used it before, but just thinking of ways to lighten the amount of services that JB'll have to run initially to get the website up and running. I'd imagine if they want to host a redis instance later on (since self-hosting is something JB does) that'd be doable, but just to initially launch without an extra 2-3 services (search + s3 endpoint where some other services talked about).

from jupiterbroadcasting.com.

elreydetoda avatar elreydetoda commented on June 15, 2024

Ya, IIRC CF works run their own version of a node runtime, right? (Only heard about it on podcasts)

from jupiterbroadcasting.com.

reesericci avatar reesericci commented on June 15, 2024

Deno isn't node so it wouldn't work

from jupiterbroadcasting.com.

reesericci avatar reesericci commented on June 15, 2024

for realtime updates Cloudflare's Pub/Sub: https://developers.cloudflare.com/pub-sub/ could possibly work instead of self-hosting a pub/sub solution.

from jupiterbroadcasting.com.

reesericci avatar reesericci commented on June 15, 2024

As it turns out, redis has a builtin Pub/Sub function: https://redis.io/docs/manual/pubsub/

from jupiterbroadcasting.com.

gerbrent avatar gerbrent commented on June 15, 2024

feature completed by #378

from jupiterbroadcasting.com.

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.