ControlSystemStudio / phoebus

A framework and set of tools to monitor and operate large scale control systems, such as the ones in the accelerator community.
http://phoebus.org/
Eclipse Public License 1.0
90 stars 90 forks source link

Phoebus services for production #370

Open shroffk opened 5 years ago

shroffk commented 5 years ago

As the alarm services are being prepared for deployment in production. FRIB has requested that the simple phoebus services be wrapped as springboot services.

Spring boot provides a simple lightweight modular solution to packaging our services to that they can be easily deployed, monitored, etc... while still staying away for heavy application ee servers.

kasemir commented 5 years ago

Well, not requiring springboot seems simpler than requiring it. At SNS we're running the alarm server as a linux service under procserv, basically like this:

[Service]
Environment=JAVA_HOME=/home/controls/css/jdk-10
Environment=SERVER=/home/controls/css/phoebus-alarm-server
Environment=PORT=4609
Environment=CONFIG=IHC
Environment=PATH=/home/controls/css/jdk-10/bin:/usr/bin
ExecStart=/usr/bin/procServ --foreground --noautorestart --name alarm-server --chdir ${SERVER} --logfile ${SERVER}/console.log ${PORT} ./alarm-server.sh -config ${CONFIG}

If you want to also wrap it with springboot, OK, but we need to still have a plain executable for the alarm server (and archive engine).

shroffk commented 5 years ago

I have just looking into this @berryma4 and FRIB can comment more thoroughly on this.

My initial look seems to suggest that the minimal setup would allow for the above use case. I do like the idea of continuing the support simple use cases for development and testing.

shroffk commented 5 years ago

So the way springboot has been incorporated you have a jar that can be run in a way that fits your deployment strategy (we will iron out the wrinkles as we go).

We now have a jar, with all the dependencies, and an embedded web server available so people can use phoebus services which can be made available as a downloadable jar and can be run as simply as java -jar service.jar

shroffk commented 5 years ago

This issue will be part of the discussion at the upcoming cs-studio developers meeting. Georg will be talking about it as a subject matter expert