Added counters and timers to script processing.

Metrics are now wrapped around script engine processing in Gremlin Extension and RexPro.