TimeOut SendReplyMessage (Is this possible)

Hi.

Is it possible to Send a message to a Service with a Timeout. The Service then
issues a request to a user application. If the user application doesn’t respond
within its own TimeOut period the Service replies to the driver that it wishes
the driver to wait a little bit longer. The driver then reissues a wait TimeOut
without sending a new message and waiting on and with the previous data.

For example, every 3 seconds the service sends a reply to the driver informing
it, it wishes the driver to wait some more time. If nothing is received the
driver calls the STATUS_TIMEOUT event. The Service is assumed to be
inaccessible. If there is no Timeout error, once the service has finished it changes one Boolean value in the return structure to TRUE and the driver processes something different.

If you need more clarification please let me know. This is an attempt to try to
rid the driver of NULL TimeOut events.

N.

You have already proposed one solution which you could implement. I mean a heartbeat timer.
You could also implement a shared event which you could use in both - user mode, where works your Service, and in kernel mode, where works your driver. Here is an article which explains how you could use shared events.
http://download.microsoft.com/download/e/b/a/eba1050f-a31d-436b-9281-92cdfeae4b45/KM-UMGuide.doc

Igor Sharovar

The problem is I am using threads on the Service and I cannot be 100% sure I would be receving the reissued FltSendMessage on the same thread. (Ideally, no new Message is sent but a section of code is executed if the Service hasn’t replied and if the Service does reply with true then it waits on the previous FltSendMessage for another 3 seconds.)

RE: TimeOut SendReplyMessage (Is this possible)


You have already proposed one solution which you could implement. I mean a
heartbeat timer.
You could also implement a shared event which you could use in both - user mode,
where works your Service, and in kernel mode, where works your driver. Here is
an article which explains how you could use shared events.
http://download.microsoft.com/download/e/b/a/eba1050f-a31d-436b-9281-92cdfeae4b45
/KM-UMGuide.doc

Igor Sharovar

The problem with a heartbeat timer is I am using threads in the Service and I cannot be certain that the thread I am using will pick the reissued FltSendMessage. Another may. (What would be perfect would be to issue the FltSendMessage, and wait the 3 seconds, if the Service replies true, then without reissuing the FltSendMessage, it waits for a reply for another 3 seconds, again if the Service replies true it waits again if not then some other code is executed.)


RE: TimeOut SendReplyMessage (Is this possible)


You have already proposed one solution which you could implement. I mean a
heartbeat timer.
You could also implement a shared event which you could use in both - user mode,
where works your Service, and in kernel mode, where works your driver. Here is
an article which explains how you could use shared events.
http://download.microsoft.com/download/e/b/a/eba1050f-a31d-436b-9281-92cdfeae4b45
/KM-UMGuide.doc

Igor Sharovar

Am I able to reply?

Hi.

I don?t know if I can make replies.

My problem is that I am using threads inside the Service and I cannot be certain when I issue a FltMessageSend() that it will be picked up by the previous thread. Ideally what I would like is a function in the driver which sends FltMessageSend() but when the Service uses Reply the driver executes a piece of code before re-issuing the FltMessageSend without sending data but listening on the same MessageId as before.

>Ideally what I would like is a function in the driver which sends FltMessageSend() but when the >Service uses Reply the driver executes a piece of code before re-issuing the FltMessageSend without >sending data but listening on the same MessageId as before.
Could you specify your problem in more details? It is not clear what you want.

Igor Sharovar

I solved the problem.

The solution was to create my own MessageId’s.

The Driver created its own unique MessageId and sent this to the Application. The Application then sends back the same Message ID and it’s message.

The problem was solved. Thanks for being here.