1

Each time I create a software at some point I wish to provide a way for users to control it programatically.

So far I explored the following paths:

  1. Implement the core of it as a library (dll/so, jar, TCL package...)
  2. Embed a scripting engine (tried TCL)
  3. Implement the core of it as a server using socket programming

The library approach does not cost much extra effort for the developer but is not exactly user friendly for "small" tasks.

The scripting engine approach is user friendly as long as you picked his favorite language. It may be rather slow and in any case has some impact on the software architecture, build flow, distribution... in the end I think it is the one which requires the most efforts for the developer.

The server option has the benefit of letting the user choose his favorite language and has the greatest decoupling with the user code.

First question is "are there other approaches ?"

Second question is about performances: I am wondering how the server approach compares with scripting engines. I understand that this is dependent on which scripting engine is considered as well as which OS, that's why I ask SO rather than just bench-marking on my computer at home...

acapola
  • 1,078
  • 1
  • 12
  • 23

0 Answers0