Skip to content

armgit / xerj

Public Imported from GitHub
0

AI search engine and MCP server for bots and agents. One Rust binary indexes code, docs, logs, JSONL/CSV and PDFs for BM25 full-text, vector and hybrid search, code search without grep, agent memory and RAG. Elasticsearch-compatible API; Corpus Hub serves hundreds of reference memory corpora.

1.3 KB
Raw Blame
---
 teardown:

  - do:
      cluster.put_settings:
        body:
          persistent:
            search.max_keep_alive: null
            search.default_keep_alive: null

---
"Max keep alive":

  - do:
      index:
        index:  test_scroll
        id:     "1"
        body:   { foo: 1 }

  - do:
      index:
        index:  test_scroll
        id:     "2"
        body:   { foo: 1 }

  - do:
      indices.refresh: {}

  - do:
      cluster.put_settings:
        body:
          persistent:
            search.default_keep_alive: "1m"
            search.max_keep_alive: "1m"

  - do:
      catch: /.*Keep alive for.*is too large.*/
      search:
        rest_total_hits_as_int: true
        index: test_scroll
        size: 1
        scroll: 2m
        sort: foo
        body:
          query:
            match_all: {}

  - do:
      search:
        rest_total_hits_as_int: true
        index: test_scroll
        size: 1
        scroll: 1m
        sort: foo
        body:
          query:
            match_all: {}

  - set: {_scroll_id: scroll_id}
  - match: {hits.total:      2    }
  - length: {hits.hits:      1    }

  - do:
      catch: /.*Keep alive for.*is too large.*/
      scroll:
        rest_total_hits_as_int: true
        scroll_id: $scroll_id
        scroll: 3m