Skip to content
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

why not enable json type persistence parser? #4893

Open
zhangkyou opened this issue Jul 5, 2022 · 0 comments
Open

why not enable json type persistence parser? #4893

zhangkyou opened this issue Jul 5, 2022 · 0 comments

Comments

@zhangkyou
Copy link

zhangkyou commented Jul 5, 2022

Version of Cadence server, and client(which language)
This is very important to root cause bugs.

  • Server version: 0.23.1
  • Client version:
  • Client langauge:

Describe the bug
common/constants.go

// Data encoding types
const (
	EncodingTypeJSON     EncodingType = "json"
	EncodingTypeThriftRW EncodingType = "thriftrw"
	EncodingTypeGob      EncodingType = "gob"
	EncodingTypeUnknown  EncodingType = "unknow"
	EncodingTypeEmpty    EncodingType = ""
	EncodingTypeProto    EncodingType = "proto3"
)

the constant encoding types include json type.But in getEncoder/getDecoder(common/presistence/serialization/parser.go) it only enable 'thriftrw' and 'proto3' type.

func getEncoder(encoding common.EncodingType) (encoder, error) {
	switch encoding {
	case common.EncodingTypeThriftRW:
		return newThriftEncoder(), nil
	case common.EncodingTypeProto:
		return newProtoEncoder(), nil
	default:
		return nil, unsupportedEncodingError(encoding)
	}
}

To Reproduce
Is the issue reproducible?

  • [Yes]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant