You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Next »

Search Procedure API Service

Service to search by procedures/registry public data

Description

Service sync procedures/registry/auctions data and provide search with elasticsearch.
Search provided on top of the public data only, as it synchronized from the public data source.
For the full-text search, there is `full_text_search` field. It`s a service field, not shown by public api.

Swagger documentation

Search endpoints listed - https://procedure-dev.prozorro.sale/api/doc/search, search fold.

Software requirements

  • python3.9
  • Elasticsearch
  • aiohttp

System requirements

  • Make
  • Docker
  • docker-compose

Usage

Building an image

make docker-build

Run


make run

Remove running services

make remove-compose

Running integration tests

make test-integration

Build sphinx docs based on the docstring description.

make build-docs

Build sphinx docs based on the docstring description.

make clean-docs

Elastic indexes description

There are multiple indexes built on service with standard naming patterns:

  • Procedures (k8s_namespace)_procedures_(procedure_type).
    • Example: ``prozorro_dev_procedures_basicsell``
  • Registry:
    • (k8s_namespace)_registry
    • (k8s_namespace)_action
    • (k8s_namespace)_lease

Create indexes for elastic

python3 -m prozorro_sale.create_indexes -u localhost -i procedures


This will create 2 indexes:

  • main index for procedures (name: procedures-<VERSION>, alias: procedures)
  • timestamp index for sync (name: procedures_ts)

CLI script for ops

[More information: ](./docs/cli.md)

Indexing WorkFlow

[More information: ](./docs/indexing-workflow.md)

  • No labels