Elasticsearch Flashcards

(10 cards)

1
Q

What is Elasticsearch?

A

A distributed search and analytics engine designed for fast querying over large datasets and stores data as JSON documents. Elasticsearch is also part of the ELK stack (Elasticsearch, Logstash, Kibana), widely used for logs, observability, and analytics.

Elasticsearch is commonly used in:

  • Search bars (news, e-commerce, documentation)
  • Content discovery tools
  • Dashboards and analytics
  • Log and metrics analysis

It supports:

  • Full-text search
  • Fuzzy search (“did you mean…?”)
  • autocomplete and suggestions
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What is an index in Elasticsearch?

A

A collection of JSON documents grouped under a name, similar to a database table.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What is a document in Elasticsearch?

A

A JSON object stored inside an index; equivalent to a row in SQL.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What is a schema (mapping) in Elasticsearch?

A

A definition of fields and their data types for an index.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What type of queries does Elasticsearch support?

A

Full-text queries for text fields and exact-match queries for keyword fields.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What is a full-text query in Elasticsearch?

A

A query that analyzes text and searches indexed documents for relevant, tokenized matches within a field.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What is an exact-match query in Elasticsearch?

A

A query that searches for exact terms in fields of type keyword.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

How do you index a document in Elasticsearch?

A

Using POST /<index>/_doc with a JSON body containing the document.</index>

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

How do you update a document in Elasticsearch?

A

Using POST /<index>/_update/<id> with partial fields to modify.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

How do you search documents in Elasticsearch?

A

Using POST ` /<index>/_search` with a query body defining match or term queries.</index>

How well did you know this?
1
Not at all
2
3
4
5
Perfectly