Skip to content

Issue creating new plugin repositories #384

@ctrl-schaff

Description

@ctrl-schaff

With new plugins, during the build phase if an elasticsearch repository hasn't been created prior to completing the build then the following error can be found in the logs

SNAPSHOT_CONFIG = {
   ...
   "env" : {
       "s3_pending" : {
           "cloud" : {
               "type" : "aws", 
           },
           "repository" : {
               "name" : "pending_%(build_config.name)s_repository",
               "type" : "s3",
               "settings" : {
                   "bucket": "biothings-es8-snapshots",
                   "base_path": "pending/%(build_config.name)s"
               }
           },
           "indexer" : {
               "env" : "su10",
           },
           "monitor_delay" : 10
       }
   ...
}
Encountered an error:
Installation error: Snapshot 'hmdb_20240716_gaantjja' doesn't exist

Jul 16 11:38:27 su06 python[2762268]: INFO:elastic_transport.transport:GET http://pending-api-es.ci.transltr.io:9200/_snapshot/pending_hmdb_repository/hmdb_20240716_gaantjja [status:404 duration:0.414s]
Jul 16 11:38:27 su06 python[2762268]: ERROR:hub:err Snapshot 'hmdb_20240716_gaantjja' doesn't exist
Jul 16 11:38:27 su06 python[2762268]: Traceback (most recent call last):
Jul 16 11:38:27 su06 python[2762268]: File "/opt/home/pending/venv/lib/python3.10/site-packages/biothings/utils/es.py", line 897, in get_snapshots
Jul 16 11:38:27 su06 python[2762268]: snapshots = self._es.snapshot.get(
Jul 16 11:38:27 su06 python[2762268]: File "/opt/home/pending/venv/lib/python3.10/site-packages/elasticsearch/_sync/client/utils.py", line 446, in wrapped
Jul 16 11:38:27 su06 python[2762268]: return api(*args, **kwargs)
Jul 16 11:38:27 su06 python[2762268]: File "/opt/home/pending/venv/lib/python3.10/site-packages/elasticsearch/_sync/client/snapshot.py", line 563, in get
Jul 16 11:38:27 su06 python[2762268]: return self.perform_request( # type: ignore[return-value]
Jul 16 11:38:27 su06 python[2762268]: File "/opt/home/pending/venv/lib/python3.10/site-packages/elasticsearch/_sync/client/_base.py", line 423, in perform_request
Jul 16 11:38:27 su06 python[2762268]: return self._client.perform_request(
Jul 16 11:38:27 su06 python[2762268]: File "/opt/home/pending/venv/lib/python3.10/site-packages/elasticsearch/_sync/client/_base.py", line 271, in perform_request
Jul 16 11:38:27 su06 python[2762268]: response = self._perform_request(
Jul 16 11:38:27 su06 python[2762268]: File "/opt/home/pending/venv/lib/python3.10/site-packages/elasticsearch/_sync/client/_base.py", line 352, in _perform_request
Jul 16 11:38:27 su06 python[2762268]: raise HTTP_EXCEPTIONS.get(meta.status, ApiError)(
Jul 16 11:38:27 su06 python[2762268]: elasticsearch.NotFoundError: NotFoundError(404, 'snapshot_missing_exception', '[pending_hmdb_repository:hmdb_20240716_gaantjja] is missing')

Metadata

Metadata

Assignees

Labels

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions