Skip to content

Commit

Permalink
Merge branch 'main' into feature/ism_transform
Browse files Browse the repository at this point in the history
  • Loading branch information
tanqiuliu authored Jul 1, 2023
2 parents 6a75695 + bdc9dad commit 10ba7c5
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 8 deletions.
9 changes: 4 additions & 5 deletions .github/workflows/maven-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,10 @@ name: Publish snapshots to maven
on:
workflow_dispatch:
push:
branches: [
main
1.*
2.*
]
branches:
- main
- '[0-9]+.[0-9]+'
- '[0-9]+.x'

jobs:
build-and-publish-snapshots:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -363,7 +363,9 @@ data class Transform(
groups.add(Dimension.parse(xcp))
}
}
AGGREGATIONS_FIELD -> aggregations = AggregatorFactories.parseAggregators(xcp)
AGGREGATIONS_FIELD -> {
AggregatorFactories.parseAggregators(xcp)?.let { aggregations = it }
}
CONTINUOUS_FIELD -> continuous = xcp.booleanValue()
USER_FIELD -> {
user = if (xcp.currentToken() == Token.VALUE_NULL) null else User.parse(xcp)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -208,6 +208,7 @@ fun mockSnapshotInfo(
endTime: Long = randomNonNegativeLong(),
reason: String? = null, // reason with valid string leads to FAILED snapshot state
policyName: String = "daily-snapshot",
remoteStoreIndexShallowCopy: Boolean = randomBoolean(),
): SnapshotInfo {
val result = SnapshotInfo(
SnapshotId(name, UUIDs.randomBase64UUID()),
Expand All @@ -220,6 +221,7 @@ fun mockSnapshotInfo(
emptyList(),
false,
mapOf("sm_policy" to policyName),
remoteStoreIndexShallowCopy
)
return result
}
Expand All @@ -231,6 +233,7 @@ fun mockSnapshotInfo(
*/
fun mockInProgressSnapshotInfo(
name: String = randomAlphaOfLength(10),
remoteStoreIndexShallowCopy: Boolean = randomBoolean(),
): SnapshotInfo {
val entry = SnapshotsInProgress.Entry(
Snapshot("repo", SnapshotId(name, UUIDs.randomBase64UUID())),
Expand All @@ -245,6 +248,7 @@ fun mockInProgressSnapshotInfo(
"",
mapOf("sm_policy" to "daily-snapshot"),
Version.CURRENT,
remoteStoreIndexShallowCopy
)
return SnapshotInfo(entry)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -321,7 +321,7 @@ class TransformRunnerIT : TransformRestTestCase() {
assertTrue("Target transform index was not created", indexExists(transform.targetIndex))
}

waitFor(Instant.ofEpochSecond(60)) {
waitFor(Instant.ofEpochSecond(180)) {
val transformJob = getTransform(transformId = transform.id)
assertNotNull("Transform job doesn't have metadata set", transformJob.metadataId)
val transformMetadata = getTransformMetadata(transformJob.metadataId!!)
Expand Down Expand Up @@ -504,7 +504,7 @@ class TransformRunnerIT : TransformRestTestCase() {
assertTrue("Target transform index was not created", indexExists(transform.targetIndex))
}

waitFor(Instant.ofEpochSecond(60)) {
waitFor(Instant.ofEpochSecond(180)) {
val transformJob = getTransform(transformId = transform.id)
assertNotNull("Transform job doesn't have metadata set", transformJob.metadataId)
val transformMetadata = getTransformMetadata(transformJob.metadataId!!)
Expand Down

0 comments on commit 10ba7c5

Please sign in to comment.