views:

232

answers:

2

What is the best way to access a running mono application via the command line (Linux/Unix)?

Example: a mono server application is running and I want to send commands to it using the command line in the lightest/fastest way possible, causing the server to send back a response (e.g. to stdout).

+1  A: 

I would say make a small, simple controller program that takes in your required command line arguments and uses remoting to send the messages to the running daemon.

This would be similar to the tray icon controller program talking to the background service that is prevalent in most Windows service patterns.

Geoffrey Chetwood
A: 

@Rich B: This is definately a suitable solution, which I already had implemented - however on the server I have to use, the remoting approach takes around 350ms for a single request.

I've measured the time on the server side of the request handling - the request is handled in less than 10ms, so it has to be the starting of the client program and the tcp connection, that takes up the time.

Hence the hope that I can find another way to post the requests to the server application.

Grimtron