Skip to content
This repository was archived by the owner on Jun 18, 2025. It is now read-only.

correctness of ContentTypeJson valueΒ #191

@karthiksedoc

Description

@karthiksedoc

Looks like the following:

	eventData := esdb.EventData{
		ContentType: esdb.ContentTypeJson,
		EventType:   "TestEvent",
		Data:        data,
	}

in https://github.com/EventStore/EventStore-Client-Go/blob/c29aa7d3ce9c0aadc7d2bfa3dd060f2865efb227/samples/quickstart.go#L42C21-L42C36 is incorrect , does it have to be int as in below?

https://github.com/EventStore/EventStore-Client-Go/blob/c29aa7d3ce9c0aadc7d2bfa3dd060f2865efb227/esdb/event_data.go#L12

the following code works for me:

	eventData := esdb.EventData {
		ContentType: 1,
		EventType: "TestEvent",
		Data: data,
	}

So, the ContentType: esdb.ContentTypeJson need to be changed to ContentType: 1 ?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions