Hi, I am trying to write Protobuf to Parquet forma...
# troubleshooting
z
Hi, I am trying to write Protobuf to Parquet format and save the output in s3
Copy code
val s3Sink = FileSink
      .forBulkFormat[LogMessage](outputPath, ParquetProtoWriters.forType(classOf[LogMessage]))
      .withBucketAssigner(new LogMsgBucketAssigner)
      .build()
I am getting the below error.
Copy code
inferred type arguments [kong.model.analytics.gateway_log.LogMessage] do not conform to method forType's type parameter bounds [T <: com.google.protobuf.Message]
      .forBulkFormat[LogMessage](outputPath, ParquetProtoWriters.forType(classOf[LogMessage]))
Proto definition
Copy code
syntax = "proto2";

import "google/protobuf/timestamp.proto";

package kong.model.analytics;


message LogMessage {
  required string message = 1;
  required string node_id = 2;
  required string control_plane_id = 3;
  required bool is_composite_cp = 4;
  required string organization_id = 5;
  required google.protobuf.Timestamp timestamp = 6;
}
what is wrong with my setup?
Figured it out myself. I needed the java protobuf code. https://scalapb.github.io/docs/generated-code#java-conversions
d
πŸ‘