, secret_access_key: impl Into, session_token: Option, expires_after: Option, provider_name: &'static str, ) -> Self ``` Anyone have an idea of why the dispatch failure may be happening on Tigris?"> Tigris Upload Failed to Dispatch - Tigris - LLM Cache

Tigris Upload Failed to Dispatch - Tigris

Tigris Upload Failed to Dispatch

Hi, I’m trying to use Tigris to upload a few images using aws-sdk-s3 Rust crate. Here is a snippet:

pub async fn example(
    access_key_id: String,
    secret_access_key: String,
    bucket_name: String,
    key: String,
    data: Vec<u8>,
) -> Result<()> {
    let creds = Credentials::new(
        access_key_id,
        secret_access_key,
        None,
        None,
        "provider_name",
    );

let config = aws_config::defaults(BehaviorVersion::latest())
        .credentials_provider(creds)
        .region(Region::new("auto"))
        .load()
        .await;

let client = S3Client::new(&config);
    let data = ByteStream::from(data);

client
        .put_object()
        .bucket(bucket_name)
        .key(&key)
        .body(data)
        .send()
        .await
        .map_err(|e| anyhow::anyhow!(e))?;

Ok(())
}

let config = aws_config::defaults(BehaviorVersion::latest()) .credentials_provider(creds) .region(Region::new("auto")) .load() .await;

let client = S3Client::new(&config); let data = ByteStream::from(data);

client .put_object() .bucket(bucket_name) .key(&key) .body(data) .send() .await .map_err(|e| anyhow::anyhow!(e))?;

Ok(()) }


I’m getting back a dispatch error from the `put_object()` call:

Tigris PUT Failed: dispatch failure


Tigris PUT Failed: dispatch failure


I’ve verified that all my credentials are populating from environment variables. This is the signature for `Credentials::new`:

pub fn new( access_key_id: impl Into, secret_access_key: impl Into, session_token: Option, expires_after: Option, provider_name: &'static str, ) -> Self


Anyone have an idea of why the dispatch failure may be happening on Tigris?

## Solution

The snippet looks good, could you also try by explicitly setting the Tigris URL?

let config = aws_config::defaults(BehaviorVersion::latest()) .credentials_provider(creds) .region(Region::new("auto")) .endpoint_url("https://fly.storage.tigris.dev") .load() .await;


Let me know if that works.

Thank you that solved the problem I was having.