Skip to content

Commit

Permalink
Destination S3-V2: Maybe fix metadata issue (#52703)
Browse files Browse the repository at this point in the history
  • Loading branch information
johnny-schmidt authored Feb 3, 2025
1 parent e021e47 commit 5d2ba55
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ class ObjectStorageDestinationState(
return client
.list(pathFactory.getLongestStreamConstantPrefix(stream, isStaging = false))
.filter { matcher.match(it.key) != null }
.toList() // Force the list call to complete before initiating metadata calls
.mapNotNull { obj ->
val generationId =
client.getMetadata(obj.key)[METADATA_GENERATION_ID_KEY]?.toLongOrNull() ?: 0L
Expand All @@ -65,7 +66,6 @@ class ObjectStorageDestinationState(
null
}
}
.toList()
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ class S3Client(
lastKey = obj.key
emit(S3Object(obj.key!!, bucketConfig))
} // null contents => empty list, not error
if (client.listObjects(request).isTruncated == false) {
if (response.isTruncated == false) {
break
}
request = request.copy { marker = lastKey }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ data:
connectorSubtype: file
connectorType: destination
definitionId: 4816b78f-1489-44c1-9060-4b19d5fa9362
dockerImageTag: 1.5.0-rc.17
dockerImageTag: 1.5.0-rc.18
dockerRepository: airbyte/destination-s3
githubIssueLabel: destination-s3
icon: s3.svg
Expand Down
1 change: 1 addition & 0 deletions docs/integrations/destinations/s3.md
Original file line number Diff line number Diff line change
Expand Up @@ -544,6 +544,7 @@ To see connector limitations, or troubleshoot your S3 connector, see more [in ou

| Version | Date | Pull Request | Subject |
|:------------|:-----------|:-----------------------------------------------------------|:-----------------------------------------------------------------------------------------------------------------------------------------------------|
| 1.5.0-rc.18 | 2025-01-29 | [52703](https://github.com/airbytehq/airbyte/pull/52703) | Force list call evaluation before making head calls |
| 1.5.0-rc.17 | 2025-01-29 | [52610](https://github.com/airbytehq/airbyte/pull/52642) | Pin CDK 0.296 |
| 1.5.0-rc.16 | 2025-01-29 | [52610](https://github.com/airbytehq/airbyte/pull/52610) | Fix assume role behavior |
| 1.5.0-rc.15 | 2025-01-23 | [52103](https://github.com/airbytehq/airbyte/pull/52103) | Make the connector use our non root base image. |
Expand Down

0 comments on commit 5d2ba55

Please sign in to comment.