Without knowing many details, it seems like your approach seems reasonable. I'd have expected that your configuration service would act as both a client (using the REST service to download configuration) and a server (providing config information over UNIX sockets), but I don't really know much about your particular set up.
To turn the program into a service, you could follow the steps for "Writing A Twisted Plugin" , or "Using the Twisted Application Framework" .
Thanks, Carl Waldbieser
On Tue, Oct 17, 2017 at 5:12 AM, Daniel Doron firstname.lastname@example.org wrote:
Sorry in advance for sending this to both Twisted mailing list. i was not sure for which was it was most appropriate.
I have a design in which I would like to have a Twisted Application which would periodically connect to a REST Server to pull configuration information, i.e. as client and upon receiving that information and processing would communicate spawn 1 or more clients connecting to local process via Unix sockets to send them configuration information. I think I understand how the standard approach would be:
- create a function that would be called with callLater/LoopingCall
- in that function create my client, connect to the REST Server, get
- Do you think my approach is correct? Essentially as explained I
need a service/daemon to periodically connect ot one server to pull information and then connect to other local process to forward them the relevant configuration. 2. How do I turn this into a twisted plugin? (daemon)
Twisted-web mailing list Twistedemail@example.com https://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-web