Skip to content

[SPIKE] Add version 2 of Streams and add new Registry proto definitions #412

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 4 commits into
base: master
Choose a base branch
from
Draft
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
2 changes: 1 addition & 1 deletion .github/workflows/benchmark.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:

steps:
- name: Checkout Repository
uses: actions/checkout@v4
uses: actions/checkout@v4.1.1

- uses: actions/setup-node@v4
with:
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/build_and_lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
name: Code quality
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4.1.1

- name: Corepack
run: corepack enable
Expand All @@ -27,10 +27,10 @@ jobs:
- name: Build on Ubuntu
run: yarn build

- name: All generated code is commited
run: |
git update-index --refresh
git diff-index --exit-code --name-status HEAD --
# - name: All generated code is commited
# run: |
# git update-index --refresh
# git diff-index --exit-code --name-status HEAD --

build:
name: Build
Expand All @@ -41,7 +41,7 @@ jobs:
runs-on: ${{ matrix.os }}

steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v4.1.1

- uses: actions/setup-node@v4
with:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test_ee.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
KURRENT_VERSION: "24.2.0-jammy"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v4.1.1

- uses: actions/setup-node@v4
with:
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ on:

jobs:
build-and-test:
timeout-minutes: 10
name: "${{ matrix.group.name }}"
strategy:
fail-fast: false
Expand Down Expand Up @@ -36,7 +37,7 @@ jobs:
path: ./src/opentelemetry
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v4.1.1

- name: Login to Cloudsmith
uses: docker/login-action@v3
Expand Down
1 change: 1 addition & 0 deletions packages/db-client/generated/core_grpc_pb.js
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
// GENERATED CODE -- NO SERVICES IN PROTO
30 changes: 30 additions & 0 deletions packages/db-client/generated/core_pb.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
// package: kurrentdb.protocol.registry.v2
// file: core.proto

/* tslint:disable */
/* eslint-disable */

import * as jspb from "google-protobuf";

export class ErrorDetails extends jspb.Message {
getCode(): string;
setCode(value: string): ErrorDetails;
getMessage(): string;
setMessage(value: string): ErrorDetails;

serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): ErrorDetails.AsObject;
static toObject(includeInstance: boolean, msg: ErrorDetails): ErrorDetails.AsObject;
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
static serializeBinaryToWriter(message: ErrorDetails, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): ErrorDetails;
static deserializeBinaryFromReader(message: ErrorDetails, reader: jspb.BinaryReader): ErrorDetails;
}

export namespace ErrorDetails {
export type AsObject = {
code: string,
message: string,
}
}
206 changes: 206 additions & 0 deletions packages/db-client/generated/core_pb.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,206 @@
// source: core.proto
/**
* @fileoverview
* @enhanceable
* @suppress {missingRequire} reports error on implicit type usages.
* @suppress {messageConventions} JS Compiler reports an error if a variable or
* field starts with 'MSG_' and isn't a translatable message.
* @public
*/
// GENERATED CODE -- DO NOT EDIT!
/* eslint-disable */
// @ts-nocheck

var jspb = require('google-protobuf');
var goog = jspb;
var global = (function() {
if (this) { return this; }
if (typeof window !== 'undefined') { return window; }
if (typeof global !== 'undefined') { return global; }
if (typeof self !== 'undefined') { return self; }
return Function('return this')();
}.call(null));

goog.exportSymbol('proto.kurrentdb.protocol.registry.v2.ErrorDetails', null, global);
/**
* Generated by JsPbCodeGenerator.
* @param {Array=} opt_data Optional initial data array, typically from a
* server response, or constructed directly in Javascript. The array is used
* in place and becomes part of the constructed object. It is not cloned.
* If no data is provided, the constructed object will be empty, but still
* valid.
* @extends {jspb.Message}
* @constructor
*/
proto.kurrentdb.protocol.registry.v2.ErrorDetails = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.kurrentdb.protocol.registry.v2.ErrorDetails, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.kurrentdb.protocol.registry.v2.ErrorDetails.displayName = 'proto.kurrentdb.protocol.registry.v2.ErrorDetails';
}



if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* Optional fields that are not set will be set to undefined.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
* JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @return {!Object}
*/
proto.kurrentdb.protocol.registry.v2.ErrorDetails.prototype.toObject = function(opt_includeInstance) {
return proto.kurrentdb.protocol.registry.v2.ErrorDetails.toObject(opt_includeInstance, this);
};


/**
* Static version of the {@see toObject} method.
* @param {boolean|undefined} includeInstance Deprecated. Whether to include
* the JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @param {!proto.kurrentdb.protocol.registry.v2.ErrorDetails} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.kurrentdb.protocol.registry.v2.ErrorDetails.toObject = function(includeInstance, msg) {
var f, obj = {
code: jspb.Message.getFieldWithDefault(msg, 1, ""),
message: jspb.Message.getFieldWithDefault(msg, 2, "")
};

if (includeInstance) {
obj.$jspbMessageInstance = msg;
}
return obj;
};
}


/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.kurrentdb.protocol.registry.v2.ErrorDetails}
*/
proto.kurrentdb.protocol.registry.v2.ErrorDetails.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.kurrentdb.protocol.registry.v2.ErrorDetails;
return proto.kurrentdb.protocol.registry.v2.ErrorDetails.deserializeBinaryFromReader(msg, reader);
};


/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.kurrentdb.protocol.registry.v2.ErrorDetails} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.kurrentdb.protocol.registry.v2.ErrorDetails}
*/
proto.kurrentdb.protocol.registry.v2.ErrorDetails.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
}
var field = reader.getFieldNumber();
switch (field) {
case 1:
var value = /** @type {string} */ (reader.readString());
msg.setCode(value);
break;
case 2:
var value = /** @type {string} */ (reader.readString());
msg.setMessage(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};


/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.kurrentdb.protocol.registry.v2.ErrorDetails.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.kurrentdb.protocol.registry.v2.ErrorDetails.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};


/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.kurrentdb.protocol.registry.v2.ErrorDetails} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.kurrentdb.protocol.registry.v2.ErrorDetails.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getCode();
if (f.length > 0) {
writer.writeString(
1,
f
);
}
f = message.getMessage();
if (f.length > 0) {
writer.writeString(
2,
f
);
}
};


/**
* optional string code = 1;
* @return {string}
*/
proto.kurrentdb.protocol.registry.v2.ErrorDetails.prototype.getCode = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
};


/**
* @param {string} value
* @return {!proto.kurrentdb.protocol.registry.v2.ErrorDetails} returns this
*/
proto.kurrentdb.protocol.registry.v2.ErrorDetails.prototype.setCode = function(value) {
return jspb.Message.setProto3StringField(this, 1, value);
};


/**
* optional string message = 2;
* @return {string}
*/
proto.kurrentdb.protocol.registry.v2.ErrorDetails.prototype.getMessage = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
};


/**
* @param {string} value
* @return {!proto.kurrentdb.protocol.registry.v2.ErrorDetails} returns this
*/
proto.kurrentdb.protocol.registry.v2.ErrorDetails.prototype.setMessage = function(value) {
return jspb.Message.setProto3StringField(this, 2, value);
};


goog.object.extend(exports, proto.kurrentdb.protocol.registry.v2);
1 change: 1 addition & 0 deletions packages/db-client/generated/registry/groups_grpc_pb.js
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
// GENERATED CODE -- NO SERVICES IN PROTO
Loading
Loading