<FromGitter>
<andrewc910> Okay, I've been doing some research. Rails offers a websocket event loop that is pretty easy to hook into to do a periodic timer. It doesn't look like amber has such a complex setup. @eliasjpr how would you recommend I go about doing a timer in amber? I have only worked with the JavaScript event loop, never even thought about building one. I have also never worked with fibers, parallelism or concurrency. What do
<FromGitter>
... you recommend I read on to begin thinking about an implementation?
<FromGitter>
<andrewc910> I'm going through rails code rn to better understand but it could take a couple weeks as action cable is quite large and complex. I would prefer not having to study action cable to its fullest.
<FromGitter>
<andrewc910> So given that crystal can spawn millions of fibers on a 64bit machine. I am thinking that may be best?
<FromGitter>
<andrewc910> The user hits a page, that registers a new WS sub. Spawn a fiber that will do some action, then sleep for x, then do it again. When the user leaves the page, kill that fiber? Does anything sound inheritently wrong with that?