there is a DummyManager to control pop up and friends. Stef On Jan 20, 2011, at 9:39 PM, Igor Stasenko wrote:
Hello folks.
I'd like to ask, if there any 'standartized' instruments for headless images (or alike).
I need a simple things: - redirect all ToolSet/UIManager messages to Transcript - redirect Transcript logging to file or stdout
in short, these tools should serve a simple, yet important purpose: - if image runs in headless mode, it should suppress anything which expecting user interaction (like showing warnings with 'continue' button) and either log such messages to file or simply quit image with error message.
Without such tool it is quite difficult to monitor, what happens with your headless image.. unless you have RFB installed.. but that is different and unrelated story.
I did a prototype once for Hydra (you can check it at SqS/HydraVM/HydraVM.mcz package) there are two subclasses: - MorphicUIManager subclass: #HydraUIManager - StandardToolSet subclass: #HydraDebugToolSet
and - WriteStream subclass: #HydraTranscript
which can be installed as a Transcript.
And in order to prepare image to run in headless mode, i issued: ToolSet unregister: StandardToolSet. ToolSet register: HydraDebugToolSet. UIManager default: HydraUIManager new.
Also, HydraTranscript startUp does something like:
TranscriptStream newTranscript: (self basicNew initialize on: (String new: 1000))
With that i could run the image in headless mode, knowing that in case of error or warning etc, all will be redirected to transcript, moreover i even stopped the UI process, so it never run on headless images.
I wonder if there are other work, which can offer similar, and is there any way to detect that image are running in headless mode?
-- Best regards, Igor Stasenko AKA sig.