c# - Can I use .NET Remoting for the communication between a console app & a process which has created by same console app?(Both are in the same server) -
i have developed backend console apps supposed run on server.
they called server process , server agent. server process create instances of server agents (as process) time time, here code calling server agent
private static void createupdatedbookingagent(updatedbooking oupdatedbooking) { try { //run console app string command = @"c:\serveragentconsole.exe"; string args = ("updatedbooking " + oupdatedbooking.meetingkey + " " + oupdatedbooking.serviceaccountemail.trim() + " " + oupdatedbooking.serviceaccountpassword.trim() + " " + oupdatedbooking.serviceaccountemail.trim()+ " " + oupdatedbooking.mailboxowneremail.trim() + " " + oupdatedbooking.method.trim() + " " + oupdatedbooking.exchangeurl + " " + oupdatedbooking.apiurl + " " + oupdatedbooking.subject + " " + oupdatedbooking.location + " " + oupdatedbooking.starttime + " " + oupdatedbooking.endtime).trim(); process process = new process(); process.startinfo.filename = command; process.startinfo.arguments = args; process.enableraisingevents = true; process.exited += new eventhandler(processexitedupdatedbooking); process.start(); } catch (exception ex) { console.writeline(ex.message); } }
my question is:
can use .net remoting this, mean way of doing this?
if not, there better way of passing data (arguments) server agent?
the server , client both must console application. according knowledge, can not benefit wcf in case. correct?
remoting or wcf ways this. should choose of "ipc" transports because restricted local machine communication. that's nice security guarantee.
note, remoting considered obsolete. .net framework source code has remoting feature behind #if feature_remoting
can delete feature framework.
make parent pass communication endpoint client. there security issue in sense on local machine might connect endpoint. simple strategy deal pass securely generated guid on command line child , make child use authenticate. or, base endpoint url on guid.
Comments
Post a Comment