All Downloads are FREE. Search and download functionalities are using the official Maven repository.

kin2.zipkin-storage-cassandra.3.4.1.source-code.zipkin2-schema.cql Maven / Gradle / Ivy

CREATE KEYSPACE IF NOT EXISTS zipkin2
  WITH replication = {'class': 'SimpleStrategy', 'replication_factor': '1'}
  AND durable_writes = false;

CREATE TYPE IF NOT EXISTS zipkin2.endpoint (
    service      text,
    ipv4         inet,
    ipv6         inet,
    port         int,
);

CREATE TYPE IF NOT EXISTS zipkin2.annotation (
    ts bigint,
    v  text,
);

CREATE TABLE IF NOT EXISTS zipkin2.span (
    trace_id            text, // when strictTraceId=false, only contains right-most 16 chars
    ts_uuid             timeuuid,
    id                  text,
    trace_id_high       text, // when strictTraceId=false, contains left-most 16 chars if present
    parent_id           text,
    kind                text,
    span                text, // span.name
    ts                  bigint,
    duration            bigint,
    l_ep                Endpoint,
    r_ep                Endpoint,
    annotations         list>,
    tags                map,
    debug               boolean,
    shared              boolean,
    PRIMARY KEY (trace_id, ts_uuid, id)
)
    WITH CLUSTERING ORDER BY (ts_uuid DESC)
    AND compaction = {'class': 'org.apache.cassandra.db.compaction.TimeWindowCompactionStrategy'}
    AND default_time_to_live =  604800
    AND gc_grace_seconds = 3600
    AND read_repair_chance = 0
    AND dclocal_read_repair_chance = 0
    AND speculative_retry = '95percentile'
    AND comment = 'Primary table for holding trace data';

CREATE TABLE IF NOT EXISTS zipkin2.dependency (
    day          date,
    parent       text,
    child        text,
    errors       bigint,
    calls        bigint,
    PRIMARY KEY (day, parent, child)
)
    WITH compaction = {'class': 'org.apache.cassandra.db.compaction.LeveledCompactionStrategy', 'unchecked_tombstone_compaction': 'true', 'tombstone_threshold': '0.2'}
    AND default_time_to_live =  259200
    AND gc_grace_seconds = 3600
    AND read_repair_chance = 0
    AND dclocal_read_repair_chance = 0
    AND comment = 'Holder for each days generation of zipkin2.DependencyLink';




© 2015 - 2025 Weber Informatics LLC | Privacy Policy