Hi,

After poking through the tpserver-cpp console code, I've formulated a
possible (more specific) plan for tackling the server configuration
protocol.

First, I would make the interactive console optional, with a command
line switch to toggle it on or off. I would also make it possible to
specify what to log to (i.e. syslog, file) on the command line. Next,
I would add a new protocol alongside the TP protocol, on a different
port. It would function using much of the same code as the TP
protocol. It would have its own set of frames, and a separate
authentication list. Command frames would hook the same functions as
the commands on the console.

Once the protocol is implemented, I would create a configuration
client which precisely emulates the local interactive console, by
parsing commands into configuration protocol frames and response
frames into interactive output. The actual console for this would be
implemented in a separate library, including the command set itself.
This would include the interactive configuration thing with a series
of questions. Once it is working the internal console would be
replaced with the stuff from the library (the drawback here is that
now the internal console is going through the protocol middleman, but
the alternative -- keeping both implementations -- seems like a
maintenance nightmare, and this way there is no more tprl in
tpserver-cpp proper). Other specialized configuration clients (e.g.,
single-player mode) would use the protocol directly as needed.

Thoughts? Ideas? This is obviously evolving very rapidly right now. :)

For now, my plan is to go through the existing console functionality
and draft up a configuration protocol specification in the style of
the TP protocol spec
(http://thousandparsec.net/tp/dev/documents/protocol3.php).

Questions:

1. What should the default behaviour be: interactive console or daemon?

2. Any particular preference about the configuration ports? I was
thinking 6925/6926.

Any and all advice is appreciated! Thank you.

-- 
Aaron Mavrinac
www.mavrinac.com

PGP Public Key: http://www.mavrinac.com/pgp.asc
_______________________________________________
tp-devel mailing list
[email protected]
http://www.thousandparsec.net/tp/mailman.php/listinfo/tp-devel

Reply via email to