• Bug
  • Status: Open
  • 2 Major
  • Resolution:
  • prodmgmt
  • Reporter: tgautier
  • August 28, 2008
  • 0
  • Watchers: 0
  • March 19, 2010

Description

In the admin console, I press start, then stop.

However, to use tc-stats.sh , I have to do the following:

tmac:bin tgautier$ ./tc-stats.sh startup

Started up. tmac:bin tgautier$ ./tc-stats.sh –host localhost –port 9520 createSession 345 Session ‘345’ created. tmac:bin tgautier$ ./tc-stats.sh –host localhost –port 9520 startCapturing Capturing started. tmac:bin tgautier$ ./tc-stats.sh –host localhost –port 9520 stopCapturing Capturing stopped. tmac:bin tgautier$ ./tc-stats.sh –host localhost –port 9520 closeSession Active session closed.

A total of 5 operations vs. two. Why?

Comments

Alex Miller 2008-08-28

I agree.

Using the multiple commands per command line you can make it 0.64% better:

[~/Work/Components/terracotta-2.6.2/bin]$ ./tc-stats.sh startup createSession 1 startCapturing

Started up. Session ‘1’ created. Capturing started. [~/Work/Components/terracotta-2.6.2/bin]$ ./tc-stats.sh closeSession shutdown Active session closed. Shutdown finished.

Geert Bevin 2008-08-29

The reason why there are individual commands is that you still need to configure the capturing session with all the stats that should actually be captured.

Usually even, after starting up, you first need to get the list of supported statistics from the cluster and work with those. Creating a capturing session without adding stats to capture is not something that people will usually do.

Also, the admin console automatically generates the session name by using a time stamp. This works for the user since he can select the existing session from a GUI list. Using such a timestamp as a automatically generated session name on the command line would make it very tedious to refer to that session afterwards.

I’m sure that the command line can be optimized, but there are simply more parameters to work with and setup because there is no visual user interface.

We could look into making a curses visual text interface, which would give you a similar experience to the current admin console.