mjeri
Repos
38
Followers
29
Following
6

The Cloud Native Application Proxy

40590
4261

RabbitMQ Bundle for the Symfony web framework

1183
369

A GO API library for working with Marathon

198
124

Resources and scripts to produce a nice backdrop with near realtime cloudmaps & live satellite/orbit prediction using xplanet

0
0

Server Side Events client and server for Go

0
0

kubefmt is a tool inspired by `go fmt` that formats your kubernetes yaml files by a predictable schema

0
0

Events

TypeScript compile errors after adding the library

I got it to compile for now if I add skipLibCheck to my tsconfig. But seems to be a quite unclean solution. So keeping the issue open.

Created at 2 weeks ago
TypeScript compile errors after adding the library

Hi and thank you for the lib! ⭐

I'm currently struggling to get it up and running in a NodeJS application developed with TypeScript. After just having done a yarn add @kafkajs/confluent-schema-registry (^3.3.0 in my package.json) I get a lot of TypeScript compile errors. Do you have some advice how I can mitigate those or do you have some recommendation with which settings TypeScript needs to be configured to make it work? Or is there a minimal NodeJS version required? We're currently running node v16.14.2.

Our current tsconfig.json looks like this:

{
  "compilerOptions": {
    "target": "es6",
    "module": "commonjs",
    "lib": ["es6"],
    "declaration": true,
    "outDir": "lib",
    "rootDir": "src",
    "strict": true,
    "noImplicitAny": true,
    "strictPropertyInitialization": false,
    "noUnusedLocals": true,
    "types": ["jest", "node"],
    "esModuleInterop": true,
    "experimentalDecorators": true,
    "emitDecoratorMetadata": true,
    "resolveJsonModule": true
  },
  "include": ["src/**/*"]
}

TypeScript compile errors I'm getting:

../../../node_modules/@kafkajs/confluent-schema-registry/node_modules/ajv/dist/types/jtd-schema.d.ts:93:14 - error TS2456: Type alias 'JTDDataDef' circularly references itself.

93 declare type JTDDataDef<S, D extends Record<string, unknown>> = (S extends {
                ~~~~~~~~~~

../../../node_modules/@kafkajs/confluent-schema-registry/node_modules/ajv/dist/types/jtd-schema.d.ts:95:5 - error TS2315: Type 'JTDDataDef' is not generic.

95 } ? JTDDataDef<D[S["ref"]], D> : S extends {
       ~~~~~~~~~~~~~~~~~~~~~~~~~~

../../../node_modules/@kafkajs/confluent-schema-registry/node_modules/ajv/dist/types/jtd-schema.d.ts:105:5 - error TS2315: Type 'JTDDataDef' is not generic.

105 } ? JTDDataDef<E, D>[] : S extends {
        ~~~~~~~~~~~~~~~~

../../../node_modules/@kafkajs/confluent-schema-registry/node_modules/ajv/dist/types/jtd-schema.d.ts:110:47 - error TS2315: Type 'JTDDataDef' is not generic.

110     -readonly [K in keyof S["properties"]]-?: JTDDataDef<S["properties"][K], D>;
                                                  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

../../../node_modules/@kafkajs/confluent-schema-registry/node_modules/ajv/dist/types/jtd-schema.d.ts:112:55 - error TS2315: Type 'JTDDataDef' is not generic.

112     -readonly [K in keyof S["optionalProperties"]]+?: JTDDataDef<S["optionalProperties"][K], D>;
                                                          ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

../../../node_modules/@kafkajs/confluent-schema-registry/node_modules/ajv/dist/types/jtd-schema.d.ts:118:47 - error TS2315: Type 'JTDDataDef' is not generic.

118     -readonly [K in keyof S["properties"]]-?: JTDDataDef<S["properties"][K], D>;
                                                  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

../../../node_modules/@kafkajs/confluent-schema-registry/node_modules/ajv/dist/types/jtd-schema.d.ts:120:55 - error TS2315: Type 'JTDDataDef' is not generic.

120     -readonly [K in keyof S["optionalProperties"]]+?: JTDDataDef<S["optionalProperties"][K], D>;
                                                          ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

../../../node_modules/@kafkajs/confluent-schema-registry/node_modules/ajv/dist/types/jtd-schema.d.ts:123:20 - error TS2315: Type 'JTDDataDef' is not generic.

123 } ? Record<string, JTDDataDef<V, D>> : S extends {
                       ~~~~~~~~~~~~~~~~

../../../node_modules/@kafkajs/confluent-schema-registry/node_modules/ajv/dist/types/jtd-schema.d.ts:127:32 - error TS2315: Type 'JTDDataDef' is not generic.

127     [K in keyof S["mapping"]]: JTDDataDef<S["mapping"][K], D> & {
                                   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

../../../node_modules/@kafkajs/confluent-schema-registry/node_modules/ajv/dist/types/jtd-schema.d.ts:135:5 - error TS2315: Type 'JTDDataDef' is not generic.

135 } ? JTDDataDef<S, S["definitions"]> : JTDDataDef<S, Record<string, never>>;
        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

../../../node_modules/@kafkajs/confluent-schema-registry/node_modules/ajv/dist/types/jtd-schema.d.ts:135:39 - error TS2315: Type 'JTDDataDef' is not generic.

135 } ? JTDDataDef<S, S["definitions"]> : JTDDataDef<S, Record<string, never>>;
                                          ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

../../../node_modules/avsc/types/index.d.ts:150:41 - error TS2304: Cannot find name 'Blob'.

150 export function createBlobDecoder(blob: Blob, opts?: Partial<DecoderOptions>): streams.BlockDecoder;

../../../node_modules/mappersmith/gateway/fetch.d.ts:18:46 - error TS2694: Namespace 'globalThis' has no exported member 'Response'.

18     createResponse(fetchResponse: globalThis.Response, data: string | ArrayBuffer | Buffer): Response<import("../response").ParsedJSON>;
                                                ~~~~~~~~

../../../node_modules/mappersmith/gateway/types.d.ts:17:35 - error TS2304: Cannot find name 'XMLHttpRequest'.

17     configure?: ((xmlHttpRequest: XMLHttpRequest) => void) | null;
                                     ~~~~~~~~~~~~~~

../../../node_modules/mappersmith/gateway/types.d.ts:19:50 - error TS2304: Cannot find name 'RequestInit'.

19 declare type FetchGatewayConfiguration = Partial<RequestInit>;
                                                    ~~~~~~~~~~~

../../../node_modules/mappersmith/gateway/xhr.d.ts:13:37 - error TS2304: Cannot find name 'XMLHttpRequest'.

13     configureBinary(xmlHttpRequest: XMLHttpRequest): void;
                                       ~~~~~~~~~~~~~~

../../../node_modules/mappersmith/gateway/xhr.d.ts:14:38 - error TS2304: Cannot find name 'XMLHttpRequest'.

14     configureTimeout(xmlHttpRequest: XMLHttpRequest): void;
                                        ~~~~~~~~~~~~~~

../../../node_modules/mappersmith/gateway/xhr.d.ts:15:40 - error TS2304: Cannot find name 'XMLHttpRequest'.

15     configureCallbacks(xmlHttpRequest: XMLHttpRequest): void;
                                          ~~~~~~~~~~~~~~

../../../node_modules/mappersmith/gateway/xhr.d.ts:17:36 - error TS2304: Cannot find name 'XMLHttpRequest'.

17     createResponse(xmlHttpRequest: XMLHttpRequest): Response<import("../response").ParsedJSON>;
                                      ~~~~~~~~~~~~~~

../../../node_modules/mappersmith/gateway/xhr.d.ts:18:32 - error TS2304: Cannot find name 'XMLHttpRequest'.

18     setHeaders(xmlHttpRequest: XMLHttpRequest, customHeaders: Headers): void;
                                  ~~~~~~~~~~~~~~

../../../node_modules/mappersmith/gateway/xhr.d.ts:19:18 - error TS2304: Cannot find name 'XMLHttpRequest'.

19     createXHR(): XMLHttpRequest;
                    ~~~~~~~~~~~~~~

../../../node_modules/mappersmith/manifest.d.ts:10:19 - error TS2304: Cannot find name 'fetch'.

10     fetch: typeof fetch | null;

Any help would be highly appreciated!

Created at 2 weeks ago
Created at 2 weeks ago
Created at 1 month ago
Created at 1 month ago
issue comment
Allow throwing on no initial offset

Just wanted to revive this issue by showing interest and I think it would still be a very valuable addition!

Created at 2 months ago
ES256 signature not valid

Ping

Created at 2 months ago
issue comment
Unexpected error "Offset out of range" causes the consumer group to drop messages

We experienced the same error message and had the case that one consumer group would start fromBeginning (as per setting), which was unintended for us.

Could this be also related when a consumer group wants to read messages from a partition, but the partition moved to another broker and the client/consumer would need to switch now the new partition? This is only a guess from our side, there were "things" going on with our Kafka cluster as this was during a node pool upgrade on a Kubernetes cluster.

The Kafka server version we're using is 3.2.0 currently setup with the Strimzi operator.

Created at 2 months ago