Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
languagebash
DOMAIN=domain-for-versioning && curl -s "$ESIP:9200/$ESINDEX/_search?q=stype:DOMAIN+AND+name:$DOMAIN&pretty" | jq -r '.hits.hits[]._source.etag'

Get Bucket id (context id)

from Swarm by domain name

...

  • You can remove the name:domain-for-versioning if you know the bucket name is unique among domains. You can leave it off if you aren't sure but might get multiple results to sort through.

Stream count

...

by

...

bucket (

...

context id)

Code Block
languagebash
CONTEXTID=<contextid> && curl -s -XPOST -H "Content-Type: application/json" --data-binary '{"query":{"bool":{"must":[{"match":{"contextid":"'"$CONTEXTID"'"}}]}}}' "$ESIP:9200/$ESINDEX/_search?pretty&q=contextid:$CONTEXTIDcount" | jq '.count'

Stream count by Domain (domain id)

Code Block
languagebash
DOMAINID=<domainid> && curl -s -XPOST -H "Content-Type: application/json" --data-binary '{"query":{"bool":{"must":[{"match":{"domainid":"'"$DOMAINID"'"}}]}}}' "$ESIP:9200/$ESINDEX/_count" | jq '.hits.total.valuecount'