tgpholly/Revolution

Possibly add multi request handler functionality

Closed this issue · 13 comments

Currently Revolution only allows the use of a single request handler and if more than one request handler is included in the modules then the last one that was loaded will be used.

This shouldn't be the case and either

  • All request handlers that are loaded should be used when a request is taken in
  • User should be notified that there are multiple request handlers and the server will be closed.

Either one of these options can be done or if you have your own creative solution feel free to suggest it.

I'd say that if each request handler had flags attached to it's requests and a central module were used to detect the flag and then pass the request on to the appropriate module, may solve this problem

The idea is that the the main file will be the centrepoint of it and everything else stems from it, having one required module (consoleHandler) is bad enough.

logically said module would only have to be loaded in scenarios where multiple request handlers are loaded

Fair point actually. Could just be an optional module to enable multihandler functionality.
Still I would prefer it to be integrated into the main framework if possible.

it's an effective temporary solution and could eventually be merged into the main framework in theory.

All in all I would like to keep existing compatibility with existing modules such as EUS, as a compromise it could be an option in the config file?

that would work quite nicely
it may be worth updating existing modules to add compatibility

Yeah, could be a case of asking the user if they would like to load in compatibility mode with multirequest disabled. Or just flat out disabling multirequest in the framework from the module.

Because some can't be updated to handle stuff like this.

that makes sense

How about, if a module states it doesn't work with multireq then shutdown the server with a message saying so.

that should work

You know, thinking about it, this is a web server and it's not really needed.
The functionality could be added in a module if someone wished to have it so i'll close this.