generated from CDCgov/template
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'origin/develop'
- Loading branch information
Showing
90 changed files
with
4,515 additions
and
606 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -18,4 +18,4 @@ jobs: | |
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Run Gradle Test | ||
run: ./gradlew test | ||
run: ./gradlew test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
313 changes: 301 additions & 12 deletions
313
...raphql-ktor/src/main/kotlin/gov/cdc/ocio/processingstatusapi/loaders/UploadStatsLoader.kt
Large diffs are not rendered by default.
Oops, something went wrong.
17 changes: 17 additions & 0 deletions
17
...graphql-ktor/src/main/kotlin/gov/cdc/ocio/processingstatusapi/models/ReportContentType.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
package gov.cdc.ocio.processingstatusapi.models | ||
|
||
/** | ||
* Enumeration of the possible sort orders for queries. | ||
*/ | ||
enum class ReportContentType (val type: String){ | ||
JSON("application/json"), | ||
JSON_SHORT("json"), | ||
BASE64("base64"); | ||
|
||
companion object { | ||
fun fromString(type: String): ReportContentType { | ||
return values().find { it.type.equals(type, ignoreCase = true) } | ||
?: throw IllegalArgumentException("Unsupported content type: $type") | ||
} | ||
} | ||
} |
13 changes: 13 additions & 0 deletions
13
...ktor/src/main/kotlin/gov/cdc/ocio/processingstatusapi/models/query/PendingUploadCounts.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
package gov.cdc.ocio.processingstatusapi.models.query | ||
|
||
import com.expediagroup.graphql.generator.annotations.GraphQLDescription | ||
|
||
@GraphQLDescription("Collection of undelivered uploads found") | ||
data class PendingUploadCounts( | ||
|
||
@GraphQLDescription("Total number of undelivered uploads.") | ||
var totalCount: Long = 0, | ||
|
||
@GraphQLDescription("Provides a list of all the uploads that have not been delivered. This means, the upload started, but according to the upload status reports we did not receive 100% of the expected chunks.") | ||
var pendingUploads: List<UnDeliveredUpload> = listOf() | ||
) |
13 changes: 13 additions & 0 deletions
13
...l-ktor/src/main/kotlin/gov/cdc/ocio/processingstatusapi/models/query/UnDeliveredUpload.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
package gov.cdc.ocio.processingstatusapi.models.query | ||
|
||
import com.expediagroup.graphql.generator.annotations.GraphQLDescription | ||
|
||
@GraphQLDescription("Collection of undelivered found") | ||
data class UnDeliveredUpload( | ||
|
||
@GraphQLDescription("UploadId of the file that is not delivered.") | ||
var uploadId: String? = null, | ||
|
||
@GraphQLDescription("Filename of the file that is not delivered.") | ||
var filename: String? = null | ||
) |
13 changes: 13 additions & 0 deletions
13
.../src/main/kotlin/gov/cdc/ocio/processingstatusapi/models/query/UnDeliveredUploadCounts.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
package gov.cdc.ocio.processingstatusapi.models.query | ||
|
||
import com.expediagroup.graphql.generator.annotations.GraphQLDescription | ||
|
||
@GraphQLDescription("Collection of undelivered uploads found") | ||
data class UnDeliveredUploadCounts( | ||
|
||
@GraphQLDescription("Total number of undelivered uploads.") | ||
var totalCount: Long = 0, | ||
|
||
@GraphQLDescription("Provides a list of all the uploads that have not been delivered. This means, the upload started, but according to the upload status reports we did not receive 100% of the expected chunks.") | ||
var unDeliveredUploads: List<UnDeliveredUpload> = listOf() | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
12 changes: 12 additions & 0 deletions
12
...-ktor/src/main/kotlin/gov/cdc/ocio/processingstatusapi/models/reports/inputs/DataInput.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
package gov.cdc.ocio.processingstatusapi.models.reports.inputs | ||
|
||
import com.expediagroup.graphql.generator.annotations.GraphQLDescription | ||
|
||
@GraphQLDescription("Input type for tags") | ||
data class DataInput( | ||
@GraphQLDescription("Tag key") | ||
val key: String, | ||
|
||
@GraphQLDescription("Tag value") | ||
val value: String | ||
) |
12 changes: 12 additions & 0 deletions
12
...ktor/src/main/kotlin/gov/cdc/ocio/processingstatusapi/models/reports/inputs/IssueInput.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
package gov.cdc.ocio.processingstatusapi.models.reports.inputs | ||
|
||
import com.expediagroup.graphql.generator.annotations.GraphQLDescription | ||
|
||
@GraphQLDescription("Input type for issues") | ||
data class IssueInput( | ||
@GraphQLDescription("Issue code") | ||
val code: String? = null, | ||
|
||
@GraphQLDescription("Issue description") | ||
val description: String? = null | ||
) |
19 changes: 19 additions & 0 deletions
19
...ain/kotlin/gov/cdc/ocio/processingstatusapi/models/reports/inputs/MessageMetadataInput.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
package gov.cdc.ocio.processingstatusapi.models.reports.inputs | ||
|
||
import com.expediagroup.graphql.generator.annotations.GraphQLDescription | ||
import gov.cdc.ocio.processingstatusapi.models.submission.Aggregation | ||
|
||
@GraphQLDescription("Input type for message metadata") | ||
data class MessageMetadataInput( | ||
@GraphQLDescription("Unique Identifier for that message") | ||
val messageUUID: String? = null, | ||
|
||
@GraphQLDescription("MessageHash value") | ||
val messageHash: String? = null, | ||
|
||
@GraphQLDescription("Single or Batch message") | ||
val aggregation: Aggregation? = null, | ||
|
||
@GraphQLDescription("Message Index") | ||
val messageIndex: Int? = null | ||
) |
55 changes: 55 additions & 0 deletions
55
...tor/src/main/kotlin/gov/cdc/ocio/processingstatusapi/models/reports/inputs/ReportInput.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
package gov.cdc.ocio.processingstatusapi.models.reports.inputs | ||
|
||
import com.expediagroup.graphql.generator.annotations.GraphQLDescription | ||
import java.time.OffsetDateTime | ||
|
||
@GraphQLDescription("Input type for creating or updating a report") | ||
data class ReportInput( | ||
@GraphQLDescription("Identifier of the report recorded by the database") | ||
val id: String? = null, | ||
|
||
@GraphQLDescription("Upload identifier this report belongs to") | ||
val uploadId: String? = null, | ||
|
||
@GraphQLDescription("Unique report identifier") | ||
val reportId: String? = null, | ||
|
||
@GraphQLDescription("Data stream ID") | ||
val dataStreamId: String? = null, | ||
|
||
@GraphQLDescription("Data stream route") | ||
val dataStreamRoute: String? = null, | ||
|
||
@GraphQLDescription("Date/time of when the upload was first ingested into the data-exchange") | ||
val dexIngestDateTime: OffsetDateTime? = null, | ||
|
||
@GraphQLDescription("Message metadata") | ||
val messageMetadata: MessageMetadataInput? = null, | ||
|
||
@GraphQLDescription("Stage info") | ||
val stageInfo: StageInfoInput? = null, | ||
|
||
@GraphQLDescription("Tags") | ||
val tags: List<TagInput>? = null, | ||
|
||
@GraphQLDescription("Data") | ||
val data: List<DataInput>? = null, | ||
|
||
@GraphQLDescription("Indicates the content type of the content; e.g. JSON, XML") | ||
val contentType: String? = null, | ||
|
||
@GraphQLDescription("Jurisdiction report belongs to; set to null if not applicable") | ||
val jurisdiction: String? = null, | ||
|
||
@GraphQLDescription("Sender ID this report belongs to; set to null if not applicable") | ||
val senderId: String? = null, | ||
|
||
@GraphQLDescription("Data Producer ID stated in the report; set to null if not applicable") | ||
val dataProducerId: String? = null, | ||
|
||
@GraphQLDescription("Content of the report. If the report is JSON then the content will be a map, otherwise, it will be a string") | ||
var content : String? = null, | ||
|
||
@GraphQLDescription("Timestamp when the report was recorded in the database") | ||
val timestamp: OffsetDateTime? = null | ||
) |
29 changes: 29 additions & 0 deletions
29
.../src/main/kotlin/gov/cdc/ocio/processingstatusapi/models/reports/inputs/StageInfoInput.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
package gov.cdc.ocio.processingstatusapi.models.reports.inputs | ||
|
||
import com.expediagroup.graphql.generator.annotations.GraphQLDescription | ||
import gov.cdc.ocio.processingstatusapi.models.submission.Status | ||
import java.time.OffsetDateTime | ||
|
||
@GraphQLDescription("Input type for stage info") | ||
data class StageInfoInput( | ||
@GraphQLDescription("Service") | ||
val service: String? = null, | ||
|
||
@GraphQLDescription("Stage name a.k.a action") | ||
val action: String? = null, | ||
|
||
@GraphQLDescription("Version") | ||
val version: String? = null, | ||
|
||
@GraphQLDescription("Status- SUCCESS OR FAILURE") | ||
val status: Status? = null, | ||
|
||
@GraphQLDescription("Issues array") | ||
val issues: List<IssueInput>? = null, | ||
|
||
@GraphQLDescription("Start processing time") | ||
val startProcessingTime: OffsetDateTime? = null, | ||
|
||
@GraphQLDescription("End processing time") | ||
val endProcessingTime: OffsetDateTime? = null | ||
) |
12 changes: 12 additions & 0 deletions
12
...l-ktor/src/main/kotlin/gov/cdc/ocio/processingstatusapi/models/reports/inputs/TagInput.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
package gov.cdc.ocio.processingstatusapi.models.reports.inputs | ||
|
||
import com.expediagroup.graphql.generator.annotations.GraphQLDescription | ||
|
||
@GraphQLDescription("Input type for tags") | ||
data class TagInput( | ||
@GraphQLDescription("Tag key") | ||
val key: String, | ||
|
||
@GraphQLDescription("Tag value") | ||
val value: String | ||
) |
Oops, something went wrong.