04-27-2022, 01:59 PM
Hi,
I mentioned before in a previous thread that I am in the process of creating a Push notification service Client/Server. I am almost finished except for that I want to keep track of user status on client machines and update the service on the server side with this status. For example, if the user is logged in/out of our system, Busy with a task or not and if the PC is locked.
Now, I want to write directly from TIdHttp client to an TIdHttpServer but http servers in indy does not implement the OnExecute event handler like TCP servers do.
I don't want to get into the process of adding another TCP server on the push service because it will damage the structure of that type of server we have. It is similar to RAD server where the actual resource is inside a dll and the host app (server) only has 1 http server.
We can add a TCP server inside the dll resource itself but I don't want to have 2 connections from the same client just for the sake keeping track of user status.
So, my questions are:
If I put a TCP server in the dll resource, is there a way to redirect the http connection from the client made with the http server (host app) to the TCP server inside the dll?
If I didn't use the TCP server inside the dll. Can expose the "OnExecute" event handler from TIdHttpServer? I want to be able to use TIdHttp.WriteRFC from the client side and read that on the server side. I don't want to use POST/PUT http requests for updating users status, I want this to use the minimum amount of data possible when send status pings to the push server.
I hope I demonstrated the full issue because I won't be able to share any code it is a very big project and also I am not allowed to.
Any help will be appreciated.
Thanks in advance
I mentioned before in a previous thread that I am in the process of creating a Push notification service Client/Server. I am almost finished except for that I want to keep track of user status on client machines and update the service on the server side with this status. For example, if the user is logged in/out of our system, Busy with a task or not and if the PC is locked.
Now, I want to write directly from TIdHttp client to an TIdHttpServer but http servers in indy does not implement the OnExecute event handler like TCP servers do.
I don't want to get into the process of adding another TCP server on the push service because it will damage the structure of that type of server we have. It is similar to RAD server where the actual resource is inside a dll and the host app (server) only has 1 http server.
We can add a TCP server inside the dll resource itself but I don't want to have 2 connections from the same client just for the sake keeping track of user status.
So, my questions are:
If I put a TCP server in the dll resource, is there a way to redirect the http connection from the client made with the http server (host app) to the TCP server inside the dll?
If I didn't use the TCP server inside the dll. Can expose the "OnExecute" event handler from TIdHttpServer? I want to be able to use TIdHttp.WriteRFC from the client side and read that on the server side. I don't want to use POST/PUT http requests for updating users status, I want this to use the minimum amount of data possible when send status pings to the push server.
I hope I demonstrated the full issue because I won't be able to share any code it is a very big project and also I am not allowed to.
Any help will be appreciated.
Thanks in advance