-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Write Metrics to BigQuery (#1696)
feat: Write Metrics to BigQuery
- Loading branch information
1 parent
f3b1a8a
commit 7428e7c
Showing
21 changed files
with
2,184 additions
and
19 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
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,6 @@ | ||
package(default_visibility = ["//visibility:public"]) | ||
|
||
alias( | ||
name = "storage", | ||
actual = "@maven//:com_google_cloud_google_cloud_bigquerystorage", | ||
) |
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
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
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
63 changes: 63 additions & 0 deletions
63
src/main/kotlin/org/wfanet/measurement/kingdom/deploy/gcloud/job/BUILD.bazel
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,63 @@ | ||
load("@rules_java//java:defs.bzl", "java_binary") | ||
load("@wfa_rules_kotlin_jvm//kotlin:defs.bzl", "kt_jvm_library") | ||
load("//src/main/docker:macros.bzl", "java_image") | ||
|
||
kt_jvm_library( | ||
name = "operational_metrics_export_job", | ||
srcs = ["OperationalMetricsExportJob.kt"], | ||
runtime_deps = ["@wfa_common_jvm//imports/java/io/grpc/netty"], | ||
deps = [ | ||
":operational_metrics_export", | ||
"//imports/java/com/google/cloud/bigquery/storage", | ||
"//src/main/kotlin/org/wfanet/measurement/kingdom/deploy/common/server:utils", | ||
"//src/main/proto/wfa/measurement/internal/kingdom:measurements_service_kt_jvm_grpc_proto", | ||
"@wfa_common_jvm//imports/java/com/google/cloud/bigquery", | ||
"@wfa_common_jvm//imports/java/picocli", | ||
"@wfa_common_jvm//imports/kotlin/kotlinx/coroutines:core", | ||
"@wfa_common_jvm//src/main/kotlin/org/wfanet/measurement/common", | ||
"@wfa_common_jvm//src/main/kotlin/org/wfanet/measurement/common/crypto:signing_certs", | ||
"@wfa_common_jvm//src/main/kotlin/org/wfanet/measurement/common/grpc", | ||
], | ||
) | ||
|
||
java_binary( | ||
name = "OperationalMetricsExportJob", | ||
main_class = "org.wfanet.measurement.kingdom.deploy.gcloud.job.OperationalMetricsExportJobKt", | ||
runtime_deps = [":operational_metrics_export_job"], | ||
) | ||
|
||
java_image( | ||
name = "operational_metrics_export_job_image", | ||
binary = ":OperationalMetricsExportJob", | ||
main_class = "org.wfanet.measurement.kingdom.deploy.gcloud.job.OperationalMetricsExportJobKt", | ||
visibility = ["//src:docker_image_deployment"], | ||
) | ||
|
||
kt_jvm_library( | ||
name = "operational_metrics_export", | ||
srcs = ["OperationalMetricsExport.kt"], | ||
visibility = ["//src/test/kotlin/org/wfanet/measurement/kingdom/deploy/gcloud/job:__pkg__"], | ||
deps = [ | ||
":stream_writer_factory", | ||
"//imports/java/com/google/cloud/bigquery/storage", | ||
"//src/main/kotlin/org/wfanet/measurement/api:public_api_version", | ||
"//src/main/kotlin/org/wfanet/measurement/api/v2alpha:packed_messages", | ||
"//src/main/proto/wfa/measurement/api/v2alpha:measurement_spec_kt_jvm_proto", | ||
"//src/main/proto/wfa/measurement/internal/kingdom:measurements_service_kt_jvm_grpc_proto", | ||
"//src/main/proto/wfa/measurement/internal/kingdom/bigquerytables:operational_metrics_dataset_kt_jvm_proto", | ||
"@wfa_common_jvm//imports/java/com/google/cloud/bigquery", | ||
"@wfa_common_jvm//imports/kotlin/kotlinx/coroutines:core", | ||
"@wfa_common_jvm//src/main/kotlin/org/wfanet/measurement/common", | ||
"@wfa_common_jvm//src/main/kotlin/org/wfanet/measurement/common/identity", | ||
"@wfa_common_jvm//src/main/kotlin/org/wfanet/measurement/gcloud/common", | ||
], | ||
) | ||
|
||
kt_jvm_library( | ||
name = "stream_writer_factory", | ||
srcs = ["StreamWriterFactory.kt"], | ||
visibility = ["//src/test/kotlin/org/wfanet/measurement/kingdom/deploy/gcloud/job:__pkg__"], | ||
deps = [ | ||
"//imports/java/com/google/cloud/bigquery/storage", | ||
], | ||
) |
Oops, something went wrong.