EventStore / EventStoreDB-Client-Java

Official Asynchronous Java 8+ Client Library for EventStoreDB 20.6+
https://eventstore.com
Apache License 2.0
63 stars 20 forks source link

Updating projections with a non-JS handler type using the gRPC client #210

Closed fxshlein closed 1 year ago

fxshlein commented 1 year ago

Describe the bug When updating projections over gRPC, the server seems to always assume that the projection has the type JS. When trying to update the internal projections, specifically $by_category, this results in an error: "Line 2: Unexpected end of input".

To Reproduce Using the java client:

client.update("$by_category", "first\r\n:");

(where client is the EventStoreDBProjectionManagementClient instance)

Expected behavior The handler type should be configurable through the client.

Actual behavior The handler type for gRPC seems to be hard coded here.

Config/Logs/Screenshots This message is logged:

Updating '"$by_category"' projection source to '"first\r\n:"' (Requested type is: '"JS"')

EventStore details

Additional context It seems like this has already been fixed for the C# client: https://github.com/EventStore/EventStore/issues/1451

DEV-123