I am logging the client request of a soap service using TROIndyHTTPServer.OnReadFromStream, and logging the client IP address via TRORemoteDataModule.GetDispatchInfo. These are two different events, and from what I understand could be happening in two different threads when the server is under load (my understanding is that TRORemoteDataModule is created in seperate thread per request).
How can I obtain the client request string from the TRORemoteDatamodule in a thread-safe manner in order to do something like:
Log(vClientIP, vRequestStr);
I see no way to reference the main datamodule that contains the ROServer from within the _IMPL class.
Thanks Evgeny, but my question really was - “How do I pass the request string from the main form to an instance of the TRORemoteDataModule”? The creation of this datamodule does not seem to occur in an event that I can intercept. Ideally (I think), I would override the contructor of the datamodule to accept this string. Then within the GetDispatchInfo event, I can combine the ip address with the request string and make a single log entry.