Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,4 @@ deps/*

.idea
.vscode
coverage
1 change: 0 additions & 1 deletion jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,3 @@ module.exports = {
'^.+\\.tsx?$': 'ts-jest',
},
};

9 changes: 9 additions & 0 deletions proto/test/schemaregistry/serde/cycle.proto
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
syntax = "proto3";

package test;
option go_package="../test";

message LinkedList {
int32 value = 1;
LinkedList next = 10;
}
11 changes: 11 additions & 0 deletions proto/test/schemaregistry/serde/dep.proto
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
syntax = "proto3";

package test;
option go_package="../test";

import "test/schemaregistry/serde/test.proto";

message DependencyMessage {
bool is_active = 1;
TestMessage test_messsage = 2;
}
22 changes: 22 additions & 0 deletions proto/test/schemaregistry/serde/example.proto
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
syntax = "proto3";

package test;
option go_package="../test";

import "confluent/meta.proto";

message Author {
string name = 1 [
(confluent.field_meta).tags = "PII"
];
int32 id = 2;
bytes picture = 3 [
(confluent.field_meta).tags = "PII"
];
repeated string works = 4;
}

message Pizza {
string size = 1;
repeated string toppings = 2;
}
59 changes: 59 additions & 0 deletions proto/test/schemaregistry/serde/nested.proto
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
syntax = "proto3";

package test;
option go_package="../test";

import "google/protobuf/timestamp.proto";

message UserId {
oneof user_id {
string kafka_user_id = 1;
int32 other_user_id = 2;
MessageId another_id = 3;
}
}

message MessageId {
string id = 1;
}

enum Status {
ACTIVE = 0;
INACTIVE = 1;
}

message ComplexType {
oneof some_val {
string one_id = 1;
int32 other_id = 2;
}
bool is_active = 3;
}

/*
* Complex message using nested protos and repeated fields
*/
message NestedMessage {
UserId user_id = 1;
bool is_active = 2;
repeated string experiments_active = 3;
google.protobuf.Timestamp updated_at = 4;
Status status = 5;
ComplexType complex_type = 6;
map<string, string> map_type = 7;
InnerMessage inner = 8;

message InnerMessage {
string id = 1 [json_name="id"];
repeated int32 ids = 2 [packed=true];
}

enum InnerEnum {
option allow_alias = true;
ZERO = 0;
ALSO_ZERO = 0;
}

reserved 14, 15, 9 to 11;
reserved "foo", "bar";
}
10 changes: 10 additions & 0 deletions proto/test/schemaregistry/serde/newerwidget.proto
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
syntax = "proto3";

package test;
option go_package="../test";

message NewerWidget {
string name = 1;
int32 length = 2;
int32 version = 3;
}
10 changes: 10 additions & 0 deletions proto/test/schemaregistry/serde/newwidget.proto
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
syntax = "proto3";

package test;
option go_package="../test";

message NewWidget {
string name = 1;
int32 height = 2;
int32 version = 3;
}
24 changes: 24 additions & 0 deletions proto/test/schemaregistry/serde/test.proto
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
syntax = "proto3";

package test;
option go_package="../test";

import "google/protobuf/descriptor.proto";

message TestMessage {
string test_string = 1;
bool test_bool = 2;
bytes test_bytes = 3;
double test_double = 4;
float test_float = 5;
fixed32 test_fixed32 = 6;
fixed64 test_fixed64 = 7;
int32 test_int32 = 8;
int64 test_int64 = 9;
sfixed32 test_sfixed32 = 10;
sfixed64 test_sfixed64 = 11;
sint32 test_sint32 = 12;
sint64 test_sint64 = 13;
uint32 test_uint32 = 14;
uint64 test_uint64 = 15;
}
10 changes: 10 additions & 0 deletions proto/test/schemaregistry/serde/widget.proto
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
syntax = "proto3";

package test;
option go_package="../test";

message Widget {
string name = 1;
int32 size = 2;
int32 version = 3;
}
102 changes: 102 additions & 0 deletions schemaregistry/google/type/calendar_period_pb.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,102 @@
// Copyright 2021-2024 Buf Technologies, Inc.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

// @generated by protoc-gen-es v2.0.0 with parameter "target=ts"
// @generated from file google/type/calendar_period.proto (package google.type, syntax proto3)
/* eslint-disable */

import type { GenEnum, GenFile } from "@bufbuild/protobuf/codegenv1";
import { enumDesc, fileDesc } from "@bufbuild/protobuf/codegenv1";

/**
* Describes the file google/type/calendar_period.proto.
*/
export const file_google_type_calendar_period: GenFile = /*@__PURE__*/
fileDesc("CiFnb29nbGUvdHlwZS9jYWxlbmRhcl9wZXJpb2QucHJvdG8SC2dvb2dsZS50eXBlKn8KDkNhbGVuZGFyUGVyaW9kEh8KG0NBTEVOREFSX1BFUklPRF9VTlNQRUNJRklFRBAAEgcKA0RBWRABEggKBFdFRUsQAhINCglGT1JUTklHSFQQAxIJCgVNT05USBAEEgsKB1FVQVJURVIQBRIICgRIQUxGEAYSCAoEWUVBUhAHQngKD2NvbS5nb29nbGUudHlwZUITQ2FsZW5kYXJQZXJpb2RQcm90b1ABWkhnb29nbGUuZ29sYW5nLm9yZy9nZW5wcm90by9nb29nbGVhcGlzL3R5cGUvY2FsZW5kYXJwZXJpb2Q7Y2FsZW5kYXJwZXJpb2SiAgNHVFBiBnByb3RvMw");

/**
* A `CalendarPeriod` represents the abstract concept of a time period that has
* a canonical start. Grammatically, "the start of the current
* `CalendarPeriod`." All calendar times begin at midnight UTC.
*
* @generated from enum google.type.CalendarPeriod
*/
export enum CalendarPeriod {
/**
* Undefined period, raises an error.
*
* @generated from enum value: CALENDAR_PERIOD_UNSPECIFIED = 0;
*/
CALENDAR_PERIOD_UNSPECIFIED = 0,

/**
* A day.
*
* @generated from enum value: DAY = 1;
*/
DAY = 1,

/**
* A week. Weeks begin on Monday, following
* [ISO 8601](https://en.wikipedia.org/wiki/ISO_week_date).
*
* @generated from enum value: WEEK = 2;
*/
WEEK = 2,

/**
* A fortnight. The first calendar fortnight of the year begins at the start
* of week 1 according to
* [ISO 8601](https://en.wikipedia.org/wiki/ISO_week_date).
*
* @generated from enum value: FORTNIGHT = 3;
*/
FORTNIGHT = 3,

/**
* A month.
*
* @generated from enum value: MONTH = 4;
*/
MONTH = 4,

/**
* A quarter. Quarters start on dates 1-Jan, 1-Apr, 1-Jul, and 1-Oct of each
* year.
*
* @generated from enum value: QUARTER = 5;
*/
QUARTER = 5,

/**
* A half-year. Half-years start on dates 1-Jan and 1-Jul.
*
* @generated from enum value: HALF = 6;
*/
HALF = 6,

/**
* A year.
*
* @generated from enum value: YEAR = 7;
*/
YEAR = 7,
}

/**
* Describes the enum google.type.CalendarPeriod.
*/
export const CalendarPeriodSchema: GenEnum<CalendarPeriod> = /*@__PURE__*/
enumDesc(file_google_type_calendar_period, 0);

Loading