#1 2018-06-26 20:04:48

Codorna
Member
Registered: 2018-06-26
Posts: 21

Context on URL

I've been using mormot for some interface based services for a while, and there's a new project I have to do that I just don't know how I should be doing it,

I'd like to have a server controlling a lot of different databases, the database would be in the URL, example :

localhost:8080/root/db1/customers
localhost:8080/root/db2/customers
localhost:8080/root/db3/customers

...

The problem is that I don't know the names of those dbs, if they don't exist they should be created at runtime.

Idea would be an interface,

ISampleFunctions = interface ...
TSampleFunctionsService = class(ISampleFunctions) ...

What could be done? Override Process, and then create the TRest/TSQL at run time ? but how could I then redirect it?

Thank you.

Last edited by Codorna (2018-06-26 20:33:58)

Offline

#2 2018-06-29 11:53:02

Codorna
Member
Registered: 2018-06-26
Posts: 21

Re: Context on URL

Anyone?

I'm not sure if I was clear enough but the main problem is I need the same service connecting to different databases, that must possibly be created at runtime.

Offline

Board footer

Powered by FluxBB