The Sampler is responsible for generating SampleEvents, but does not actually do anything with those Samples. Functions such as logging, graphing, and watchdog notifications should be performed by SampleListeners.

Oracle ATG Web Commerce includes an example SampleListener called MemorySampler. This listener does nothing more than save a small history of the SampleEvents sent to it. You can view that history by viewing the MemorySampler component in the Component Browser.

The MemorySampler component that comes with Oracle ATG Web Commerce has a service name of /atg/dynamo/service/MemorySampler. Its configuration file, MemorySampler.properties, looks like this:

$class=atg.service.statistics.MemorySampler
sampleListSize=40

The sampleListSize property determines how many SampleEvents are stored before the MemorySampler starts discarding the oldest events.


Copyright © 1997, 2012 Oracle and/or its affiliates. All rights reserved.

Legal Notices