|
|
Service used for tracking web traffic. This is not designed to be highly available or completely accurate. It is stored in memory and not persistent.
Method DetailautoCommit(boolean enabled) Enables or disables auto-commit. When enabled, the tracker runs the auto serialization process as soon as either the event or page inventory reaches its limit, then resets both inventories so tracking can continue. The serialization process stores the summarized payload to the storage provider, runs the terminate workflow, or both, depending on which are set. Default is false.
Parameters:
Since: 08-28-2026 int getBadRequests() Returns the number of logged pages that look like bad/bot requests-- those not ending in .htm, .html, .do or .json. .txt is excluded from the count only for robots.txt, and .xml is excluded from the count only for sitemap.xml. Returns: int Since: 08-20-2026 int getCommitCount() Returns the number of times auto-commit has run the auto serialization process for this tracker. Returns: int Since: 08-28-2026 String getStorageProvider() Returns the name of the storage provider used to store the summarized payload when the session ends, if set. Returns: String Since: 08-20-2026 String getTerminateWorkflow() Returns the name of the session termination workflow, if set. Returns: String Since: 08-20-2026 logEvent(String eventId, String eventData) Adds the event to the log, with a timestamp. Max length of eventId and eventData are 1000 each and they are truncated to the limit.
Parameters:
Since: 08-20-2026 logPage(String url) Adds or updates the page/navigation count. Max length of the url is 1000 and it is truncated to the limit.
Parameters:
Since: 08-20-2026 setEventLimit(int limit) Sets the limit to the total number of events to log. Stops logging when reached. Default is 100, max is 1000.
Parameters:
Since: 08-20-2026 setPageLimit(int limit) Sets the limit to the total number of pages to log. Stops logging when reached. Default is 100, max is 1000.
Parameters:
Since: 08-20-2026 setProperty(String key, String value) Sets a property that can be retrieved in the summary payload. Max length of key and value are 1000 each and they are truncated to the limit.
Parameters:
Since: 08-20-2026 setStorageProvider(String name) Sets the name of the storage provider to store the summarized payload to when the session ends. Set this to null to not store. Throws if the storage provider does not exist.
Parameters:
Since: 08-20-2026 setTerminateWorkflow(String workflow) Sets the console system workflow to run when the session ends. Set this to null to not run workflow. Throws if the workflow does not exist or is not a console system workflow.
Parameters:
Since: 08-20-2026 setUserAgent(String userAgent) Overrides the user agent recorded for this tracker and re-evaluates whether it is a bot. Intended for developer testing of bot detection and the trackBots setting.
Parameters:
Since: 08-28-2026 Payload summarize() Returns a payload containing the data and two lists- events and pages. Returns: Payload Since: 08-20-2026 terminate(boolean log) Deletes this tracker and removes from the sessions storage. If log is true, the storage provider upload and terminate workflow (if set) are run immediately before the tracker is removed.
Parameters:
Since: 08-20-2026 String toString() Returns a description of this object. Returns: String Since: 08-20-2026 trackBots(boolean track) Enables or disables tracking of bots. Whether the current user agent is a bot is determined once when the tracker is created. When disabled and the tracker was created for a bot, all tracking is ignored-- events and pages are not logged, and no serialization or terminate workflow is ever run for this tracker. Default is true.
Parameters:
Since: 08-28-2026 |
||||||||||||||||||||||||||||||||||||
| Copyright © 2006 - 2026, ContractPal, Inc. All rights reserved. | API Date: Aug 29, 2026 06:29 AM |