Colin said:
The question is, can I store each COM object in a separate process, ignoring
anything to do with what I should be doing. Can I do it?
We are resigning ourselves to writing a PERL daemon that will do this now I
think as IIS just won't allow us to.
I am assuming that you are running some ASP pages and that they will
communicate (pass data to/from) the appropriate "COM object in a
separate process" using some form of Inter-Process Communication(IPC).
Assuming the above is correct, then you can communicate with a
particular process (one representing a particular user) using TCP/IP
sockets, named pipes, DDE or file/stream I/O (there are other methods,
e.g., shared-memory configurations, but I haven't used them under Windows).
Easy way: assign unique port numbers (e.g., 127.0.0.1:8080,
127.0.0.1:8081, 127.0.0.1:8082, etc.) to each user and, on system
startup, start a separate resident TCP/IP (or easier, HTTP listener
process for each user. When a listener receives a request it
authenticates the request, processes it using the COM component and
returns a result. If the listener doesn't respond within an appropriate
time, a timeout should occur and appropriate action taken. The ASP page
could use the ServerXMLHTTP object to send a request to the appropriate
listener and fetch the response.
As an aside, note that what you describe is a "Web Service" (roughly, a
function call performed over a network) so under some circumstances you
_might_ want to look at the tools (e.g., Visual Studio, Perl SOAP
http://search.cpan.org/search?query=SOAP&mode=all ) you have available
for turning your component into a formal Web Service (although I don't
recommend that initially since it may introduce some unwelcome and
unnecessary complexity).
Good Luck,
Michael D. Kersey