MC-API / Issues

Public issue tracker for mc-api.net
https://mc-api.net
2 stars 0 forks source link

Notices #31

Closed njb-said closed 8 years ago

njb-said commented 8 years ago

Make a way to add notices to homepage without having to restart servers or update static repository (redis?)

nathantowell commented 8 years ago

Does the server load the resources at start or for each request? I guess you could have the server check mongo for a notice in it's region.

njb-said commented 8 years ago

Right now, the server downloads the static git repository when it starts up to get the html files. And can be updated whenever on the server by just replacing the html file with something else. I want to make a way to show a notice or something on the homepage but I don't want it to increase the page load time. So I am thinking of having a task running in the background which checks redis or mongo, haven't decided which yet for any notices that should be displayed, if there are some then it will save them into memory and then when a http request comes in it will add the notices seamlessly onto the page. (Check trello @ImNatho)

That's the plan, probably will change a bit though.. :stuck_out_tongue:

nathantowell commented 8 years ago

What about a javascript that checks xx.mc-api.net/backend/errors and gets a json return of current errors? That page would then check redis/mongo