Skip to content

Commit

Permalink
Fix newest AWS updates failing on localstack
Browse files Browse the repository at this point in the history
  • Loading branch information
ChaoticTempest committed Jun 17, 2024
1 parent 3fcb70f commit 7273245
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM rust:1.71 AS builder
FROM rust:1.78 AS builder
WORKDIR /tmp/

# Copy from nearcore:
Expand Down
5 changes: 3 additions & 2 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -243,13 +243,13 @@ async fn handle_message(
client.clone(),
bucket.clone(),
block_json,
format!("{}/block.json", base_key).to_string(),
format!("{}/{}/block.json", bucket, base_key).to_string(),
)
.await;

// Shards
for shard in streamer_message.shards.iter() {
let key = format!("{}/shard_{}.json", base_key, shard.shard_id);
let key = format!("{}/{}/shard_{}.json", bucket, base_key, shard.shard_id);
let shard_json =
serde_json::to_value(shard).expect("Failed to serialize IndexerShard to JSON");
put_object_or_retry(client.clone(), bucket.clone(), shard_json, key).await;
Expand Down Expand Up @@ -293,6 +293,7 @@ async fn put_object_or_retry(
metrics::RETRY_COUNT.inc();
tracing::warn!(
target: INDEXER,
?err,
"Failed to put {} to S3, retrying",
&filename
);
Expand Down

0 comments on commit 7273245

Please sign in to comment.