You might have observed that every time you start a process from RFID Manager, both the methods Deploy and Init of every event handler (EH) in the process are called. This raises the question: why have these two separate methods at all?

The answer lies in user account permissions. While calling the Deploy method of an EH, the RfidService impersonates the caller's identity. All other methods of an EH (including Init) are executed with the identity of RfidWorkerProcessAcc. If an EH wants to do some setup kind of work that requires higher priviledges (such as creating a database) that are not available to RfidWorkerProcessAcc, it is expected to put this work inside the Deploy method.

Of course, stuff like creating a new database is a one time thing and shouldn't need to be done every time a process is started. In fact RfidClientConsole.exe's startprocess command does not call Deploy at all, only doing an Init for starting the process. RFID Manager has taken the safe option of calling the Deploy every time. An EH is expected to be tolerant of being deployed multiple times.