Installing and Using ObjectWalker


I came across and would love to use it but I don’t know how to install it. For example I would like to see all of the objects in my Datastore/MyNamespace/Cloud/Vm/Provisioning/StateMachines/Methods/amazon_postProvision method.

Once it is installed would this be how to use it?

# amazon_PostProvision method
$evm.log("info", "Starting post provision method for aws vm")
$evm.log("info", "Finished post provision method for aws vm")

Documentation on $evm.root


To use objectWalker, you need to first create a method and corresponding instance in your namespace somewhere. The instance schema should just have a simple execute stage to run the method. Paste the objectWalker code into the method.

To run it, just call this instance from anywhere in the automation engine, for example from a stage in the provisioning state machine…

or from a button…

or even using $evm.instantiate(/Bit63/Bit63/Methods/objectWalker) from within your own method.

objectWalker writes its output to automation.log, so you can either just tail that log to see the output, or copy the objectWalkerReader.rb script to somewhere on your appliance, ssh in, and run it. If you run objectWalkerReader with no arguments it will just print the most recent objectWalker dump. Otherwise use -l to list objectWalker dumps in automation.log

./objectWalkerReader.rb -l
Found objectWalker dump at 2014-09-17T13:28:42.052043
Found objectWalker dump at 2014-09-17T13:34:52.649359
Found objectWalker dump at 2014-09-17T15:06:29.250086

and then -t to pick one of the timestamps:

./objectWalkerReader.rb -t 2014-09-18T09:44:27.146812
objectWalker 1.0 - EVM Automate Method Started
objectWalker: Dumping $evm.root
objectWalker: $evm.root.ae_provider_category = infrastructure (type: String)
objectWalker: $evm.root.class = Methods (type: String)
objectWalker: $evm.root.instance = objectWalker (type: String)
objectWalker: $evm.root[‘miq_server’] => # MiqAeMethodService::MiqAeServiceMiqServer:0x00000008f242b8 (type: DRb::DRbObject)
| objectWalker: $evm.root[‘miq_server’].build = 20140822170824_3268809 (type: String)

Hope this helps,