Added static terminate method to gracefully close the framework when running as a windows service.
Added static terminate method to gracefully close the framework when running as a windows service.

Gluewine/Gluewine,sergeds/Gluewine,sergeds/Gluewine,gevaerts/Gluewine,gevaerts/Gluewine,Gluewine/Gluewine,Gluewine/Gluewine,gevaerts/Gluewine,sergeds/Gluewine