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.

The Oracle Commerce Platform 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 the Oracle Commerce Platform 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, 2016 Oracle and/or its affiliates. All rights reserved. Legal Notices