Skip to main content

sow (instance statistics)

Clicking the sow link will list all available topics in the SOW for this AMPS instance. Selecting a single topic will list the following available statistics about the topic:

ElementDescriptionType
delete_countNumber of deletes processed by the SOW.cumulative
deletes_per_secNumber of deletes per second processed by the SOW.interval average
deviceDevice the topic is stored on, if applicable.fixed
historical_granularityThe granularity at which the SOW maintains history for this topic (if set).fixed
historical_windowThe window for which the SOW maintains history for this topic (if set).fixed
insert_countCount of the number of new records inserted into this topic.cumulative
inserts_per_secRate of inserts into this topic.interval average
memory_bytes

The number of bytes of memory used for this topic.

This metric includes:

  • messages stored in the topic
  • metadata for the messages in the topic
  • indices for the topic (both memo indices and hash indices)

Notice that, particularly when the topic is heavily indexed, this can be larger than the message size. Indices are not persisted, so this can also be larger than the space used for persisting the topic data.

See the section on Estimating AMPS Instance Memory Usage for details.

snapshot
mmapsThe number of memory maps used for this topic in the SOW.snapshot
message_typeMessage type for this topic.fixed
pathFile system location of the SOW topics file store.fixed
queries_per_secRate of queries for this SOW topic.interval average
query_countNumber of queries processed for this topic.cumulative
record_size

Record size for the topic in the SOW.

For SOW files created with current versions of AMPS, this will always return the same value.

fixed
resident_percent

Percentage of the storage of this topic that is currently resident in memory.

Messages that are not currently in memory will need to be retrieved from storage before they are delivered. When part of a topic is not resident, either the instance is under memory pressure or the messages (if any) in that part of the topic have not been recently updated or delivered.

snapshot
slab_countThe total number of slabs allocated for this SOW topic.snapshot
slab_sizeThe slab size for this SOW topic.fixed
stored_bytesNumber of bytes stored for this topic.snapshot
topicName of this SOW topic.fixed
update_countNumber of updates to existing records processed by this topic.cumulative
updates_per_secNumber of updates to existing records per second.interval average
valid_keys

Number of distinct messages in the SOW - defined by the SOW topic key.

For topics that maintain a history, this shows the total number of messages that the SOW maintains, which may be larger than the number of messages that would be returned by a query at the current time, or the number of messages that would be returned by a query at a historical point in time.

snapshot

Statistics Database Tables: ISOW_STATIC, ISOW_DYNAMIC

Admin Path: /amps/instance/sow/<identifier>/<metric>

Sample amps-sqlite3 query:

SELECT iso8601_local(timestamp), topic, deletes_per_sec, inserts_per_sec, updates_per_sec, valid_keys
FROM ISOW
GROUP BY topic
ORDER BY topic, timestamp

This query shows the overall activity and number of records available for each SOW topic in the instance. Notice that the activity fields are averaged over the sample interval, while the number of valid keys is a snapshot at each sample.