• 0 Posts
  • 103 Comments
Joined 1 year ago
cake
Cake day: December 18th, 2023

help-circle

  • All answers you got here are good, but it depends how simple do you want it.

    Your current solution doesn’t meet one of your criteria already. The code that produces the data cannot run for an extended period of time if it keeps all data in memory and only writes it at shutdown (or USR1).

    It would be trivial to modify the program to write on every new data point collected. Then you just tail that file from the Webserver process.

    You could use more performant solutions, like explicit pipes, Unix sockets, websockets, or even shared memory, but keeping it simple is often the best way. This makes your data collection better (no memory “leaks”) without really adding code, you could in fact remove code (USR1 handling).








  • Tja@programming.devtoTechnology@lemmy.worldruh roh
    link
    fedilink
    English
    arrow-up
    1
    ·
    13 days ago

    The author doesn’t consent to you blocking ads, simple as that. Might consent to skipping. Some. In certain situations.

    A shop giving you a free sample of cheese doesn’t mean you can fill your pockets with the contents of the cash register.