Skip to content

Commit

Permalink
switch to async signer auth
Browse files Browse the repository at this point in the history
  • Loading branch information
pudo committed Oct 21, 2024
1 parent 00a0933 commit 1c26099
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions yente/provider/opensearch.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import logging
from typing import Any, Dict, List, Optional, cast
from typing import AsyncIterator
from opensearchpy import AsyncOpenSearch, AWSV4SignerAuth
from opensearchpy import AsyncOpenSearch, AWSV4SignerAsyncAuth
from opensearchpy.helpers import async_bulk, BulkIndexError
from opensearchpy.exceptions import NotFoundError, TransportError

Expand Down Expand Up @@ -41,7 +41,7 @@ async def create(cls) -> "OpenSearchProvider":
if service not in ["es", "aoss"]:
raise RuntimeError(f"Invalid OpenSearch service: {service}")
credentials = Session().get_credentials()
kwargs["http_auth"] = AWSV4SignerAuth(
kwargs["http_auth"] = AWSV4SignerAsyncAuth(
credentials,
settings.OPENSEARCH_REGION,
settings.OPENSEARCH_SERVICE,
Expand Down

0 comments on commit 1c26099

Please sign in to comment.