Skip to main content

muscles-data-elasticsearch

Elasticsearch adapter package for muscles-data.

This package is intentionally separate from muscles-data: the core package owns typed ports, resource runtime and diagnostics, while this package owns the Elasticsearch-backed SearchIndexPort implementation.

Usage

For application, register this adapter once when App builds its shared DataAdapterCatalog, alongside NativeSqlFactory and any other configured adapters:

catalog.register(ElasticsearchSearchFactory())

The search.elastic resource itself is declared in the application's central data.resources configuration shown below. A package resolves the port from the existing runtime; it does not build another catalog or DataRuntime:

from muscles.data.ports import SearchIndexPort

search = app.resource.connect("search.elastic", SearchIndexPort)

Resource config stays in the project:

data:
  resources:
    search.elastic:
      type: elasticsearch
      url_env: ELASTICSEARCH_URL
      api_key: !environ ELASTICSEARCH_API_KEY
      index: docs
      timeout: 3
      verify_certs: true

The adapter creates the Elasticsearch client and index lazily on search, index/delete, explicit native access or data.doctor. Application code should use SearchIndexPort; direct client access is only an advanced escape hatch with native_client: true.

Missing indexes are created with a default mapping for text, title and metadata; mapping and settings resource options can customize it. upsert_documents() uses Elasticsearch bulk operations.

See muscular-example/example_data_elasticsearch_1 for an executable example.

Metadata

Release files for muscles-data-elasticsearch 0.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for muscles-data-elasticsearch 0.2.0
File Size Uploaded Provenance Actions
muscles_data_elasticsearch-0.2.0.tar.gz 13.7 kB With provenance Details for muscles_data_elasticsearch-0.2.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for muscles-data-elasticsearch 0.2.0
File Interpreter ABI Platform Actions
muscles_data_elasticsearch-0.2.0-py3-none-any.whl Python 3 none any Details for muscles_data_elasticsearch-0.2.0-py3-none-any.whl

Total release size: 22.8 kB

Release files / muscles_data_elasticsearch-0.2.0.tar.gz

Download URL muscles_data_elasticsearch-0.2.0.tar.gz
Size 13.7 kB
Tags Source
SHA-256 checksum
How to use checksums
d04e5026ad971b05ef9d02e96054d5ec4b9e64383fa336d6c2ad8d1bd51da8ed
BLAKE2b-256 checksum
How to use checksums
ed042bca9942475b737b1b359cb40fadee150106fdc7bdb7c81203b9a71b32b1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 4, 2026.

Transparency log

Release files / muscles_data_elasticsearch-0.2.0-py3-none-any.whl

Download URL muscles_data_elasticsearch-0.2.0-py3-none-any.whl
Size 9.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
8aa674e2c5fe3c0b7b4488e7fb4f222de44211c7014e01c78870934e2527dc46
BLAKE2b-256 checksum
How to use checksums
623b51c573f67230dd74065c2b914e5600ae122fc0decc15723423ef83f056f9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 4, 2026.

Transparency log

Security for muscles-data-elasticsearch 0.2.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for muscles_data_elasticsearch-0.2.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 4, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page