Welcome Guest, Not a member yet? Register   Sign In
share data between server applications
#6

(08-17-2017, 04:37 AM)nasser.man Wrote:
(08-17-2017, 02:23 AM)josepostiga Wrote: You could do it in different ways.

1. You could create some API endpoints so the apps could communicate with each other;
2. You could whitelist each servers IP address and use multiple database connections to grab (and maybe cache, if possible) data to be used as needed;

Personally, independently of the type of information stored on each server, I'd go with option 1 and standardize the communications via an API.

EXACTLY! i want to create some api for applications so they could communicate to each other, but you think is it enough to limit IP whitelist and SSL for security?

how hide apis from anyone except this server application (and only my applications on the servers)?

i think i should create second application on the completely different server (server X), and if server A needs some data from server B, server A send request to server X and server X get needed data from server B and passes them tho server A. has this way any additional benefits?

and how i should use token or key or any thing else so servers recognize/validate requests?

Well, I'd go with a secret key sent with every request and if the supplied key is validated successfully on your server X, then the request is handled... With that, there's no need to "hide" your API as only the requests with the correct API KEY should be processed.

There's lots of examples throughout the Internet. Anything more specific, ask for help here.
Best regards,
José Postiga
Senior Backend Developer
Reply


Messages In This Thread
RE: share data between server applications - by josepostiga - 08-17-2017, 06:49 AM



Theme © iAndrew 2016 - Forum software by © MyBB