diff --git a/src/main/kotlin/org/wfanet/measurement/loadtest/dataprovider/SyntheticGeneratorEdpSimulatorRunner.kt b/src/main/kotlin/org/wfanet/measurement/loadtest/dataprovider/SyntheticGeneratorEdpSimulatorRunner.kt index 29403af9504..d87c5c392cc 100644 --- a/src/main/kotlin/org/wfanet/measurement/loadtest/dataprovider/SyntheticGeneratorEdpSimulatorRunner.kt +++ b/src/main/kotlin/org/wfanet/measurement/loadtest/dataprovider/SyntheticGeneratorEdpSimulatorRunner.kt @@ -17,6 +17,7 @@ package org.wfanet.measurement.loadtest.dataprovider import com.google.protobuf.DescriptorProtos import com.google.protobuf.Descriptors import com.google.protobuf.DynamicMessage +import com.google.protobuf.ExtensionRegistry import com.google.protobuf.Message import com.google.protobuf.TypeRegistry import java.io.File @@ -175,7 +176,9 @@ class SyntheticGeneratorEdpSimulatorRunner : EdpSimulatorRunner() { files: Iterable ): List { return files.map { file -> - file.inputStream().use { input -> DescriptorProtos.FileDescriptorSet.parseFrom(input) } + file.inputStream().use { input -> + DescriptorProtos.FileDescriptorSet.parseFrom(input, EXTENSION_REGISTRY) + } } } @@ -198,6 +201,11 @@ class SyntheticGeneratorEdpSimulatorRunner : EdpSimulatorRunner() { TestEvent.getDescriptor().file) .asIterable() + private val EXTENSION_REGISTRY = + ExtensionRegistry.newInstance() + .also { EventAnnotationsProto.registerAllExtensions(it) } + .unmodifiable + init { check(TestEvent.getDescriptor().fullName == TEST_EVENT_MESSAGE_TYPE) check(