{"record":{"id":"5c8dd4077754eaef","repo":"apache/beam","slug":"not-implemented-fielddescriptor-getmessagetype-getfullname","errorCode":null,"errorMessage":"Not implemented ${fieldDescriptor.getMessageType().getFullName()}","messagePattern":"Not implemented (.+?)","errorType":"exception","errorClass":"RuntimeException","httpStatus":null,"severity":"error","filePath":"sdks/java/io/google-cloud-platform/src/main/java/org/apache/beam/sdk/io/gcp/bigquery/TableRowToStorageApiProto.java","lineNumber":1982,"sourceCode":"          default:\n            return fieldValue.toString();\n        }\n      case BYTES:\n        switch (fieldDescriptor.getType()) {\n          case BYTES:\n            return BaseEncoding.base64().encode(((ByteString) fieldValue).toByteArray());\n          case STRING:\n            return BaseEncoding.base64()\n                .encode(((String) fieldValue).getBytes(StandardCharsets.UTF_8));\n          case MESSAGE:\n            Message message = (Message) fieldValue;\n            if (BYTES_VALUE_DESCRIPTOR_NAMES.contains(fieldDescriptor.getMessageType().getName())) {\n              ByteString byteString =\n                  (ByteString)\n                      message.getField(message.getDescriptorForType().findFieldByName(\"value\"));\n              return BaseEncoding.base64().encode(byteString.toByteArray());\n            }\n            throw new RuntimeException(\n                \"Not implemented \" + fieldDescriptor.getMessageType().getFullName());\n          default:\n            return fieldValue.toString();\n        }\n      case TIMESTAMP:\n        if (isProtoFieldTypeInteger(fieldDescriptor.getType())) {\n          long epochMicros = Long.valueOf(fieldValue.toString());\n          long epochSeconds = epochMicros / 1_000_000L;\n          long nanoAdjustment = (epochMicros % 1_000_000L) * 1_000L;\n          Instant instant = Instant.ofEpochSecond(epochSeconds, nanoAdjustment);\n          return LocalDateTime.ofInstant(instant, ZoneOffset.UTC).format(TIMESTAMP_FORMATTER);\n        } else if (fieldDescriptor.getType().equals(FieldDescriptor.Type.MESSAGE)) {\n          Message message = (Message) fieldValue;\n          String messageName = fieldDescriptor.getMessageType().getName();\n          if (TIMESTAMP_VALUE_DESCRIPTOR_NAMES.contains(\n              fieldDescriptor.getMessageType().getName())) {\n            Descriptor descriptor = message.getDescriptorForType();\n            long seconds = (long) message.getField(descriptor.findFieldByName(\"seconds\"));","sourceCodeStart":1964,"sourceCodeEnd":2000,"githubUrl":"https://github.com/apache/beam/blob/12126d8942aaf848030c478b4c6a28c6af861c66/sdks/java/io/google-cloud-platform/src/main/java/org/apache/beam/sdk/io/gcp/bigquery/TableRowToStorageApiProto.java#L1964-L2000","documentation":"When converting BYTES-typed TableRow fields whose value is a protobuf message, only recognized bytes-wrapper descriptor names (e.g. BytesValue) are handled; anything else hits this 'Not implemented' RuntimeException with the full message type name.","triggerScenarios":"A TableRow field of BYTES schema holds a protobuf message that is not a recognized BytesValue wrapper when TableRowToStorageApiProto.messageToValue processes it.","commonSituations":"Custom byte-wrapper messages generated from user protos, proto-derived rows fed to BigQueryIO with the Storage API method, or mismatched wrapper types after a proto regeneration.","solutions":["Wrap the bytes in google.protobuf.BytesValue or set a raw byte[]/ByteArray in the TableRow","Unwrap the custom message to a ByteString and base64-encode it into the TableRow yourself","Verify the field's full name against BYTES_VALUE_DESCRIPTOR_NAMES in TableRowToStorageApiProto","Upgrade Beam for possibly added support","Add the descriptor name to BYTES_VALUE_DESCRIPTOR_NAMES if appropriate"],"exampleFix":"// before\nrow.set(\"payload\", MyBlobProto.getDefaultInstance());\n// after\nrow.set(\"payload\", BytesValue.of(ByteString.copyFrom(bytes)));","handlingStrategy":"validation","validationCode":"if (fieldValue instanceof Message && !BYTES_VALUE_DESCRIPTOR_NAMES.contains(((Message) fieldValue).getDescriptorForType().getName())) {\n  throw new IllegalArgumentException(\"Unsupported bytes wrapper: \" + ((Message) fieldValue).getDescriptorForType().getFullName());\n}","typeGuard":"boolean isSupportedBytesWrapper(Object v) {\n  return !(v instanceof Message)\n      || BYTES_VALUE_DESCRIPTOR_NAMES.contains(((Message) v).getDescriptorForType().getName());\n}","tryCatchPattern":"try {\n  proto = TableRowToStorageApiProto.messageToValue(schema, row, options);\n} catch (RuntimeException e) {\n  if (e.getMessage().startsWith(\"Not implemented\")) { /* DLQ or legacy path */ } else throw e;\n}","preventionTips":["Store byte[] or BytesValue in BYTES fields, never custom messages","Unwrap to ByteString and base64-encode when building rows from protos","Check BYTES_VALUE_DESCRIPTOR_NAMES after Beam/protobuf upgrades"],"tags":["java","google-bigquery","protobuf","unimplemented"],"backgroundTag":"method-not-implemented","analyzedSha":"12126d8942aaf848030c478b4c6a28c6af861c66","analyzedAt":"2026-09-13T01:50:10.254Z","contentChangedAt":"2026-09-13T01:50:10.254Z","schemaVersion":2},"datasetVersion":"2026-09-20T03:17:13.778Z"}