Skip to content
This repository was archived by the owner on Nov 15, 2023. It is now read-only.
This repository was archived by the owner on Nov 15, 2023. It is now read-only.

Refactor "JsonMetadata" into simple "Metadata" #721

@gavofyork

Description

@gavofyork

The runtime metadata is a hybrid Encoded set of JSON strings and names. Aside from being rather hacky, this is problematic for the purposes of API cleanliness where we want the client to be agnostic to the precise nature of the runtime (particularly allowing for the possibility that the metadata is of a different format to that expected).

It should be refactored into a purely Encoded data blob and a structure that can Encode/Decode it but also specifies a version id in case the format changes and dispensing with the JSON encoding completely. This has a few benefits including:

  • Reduces human-readable string bloat in the runtime.
  • Ensure that the client doesn't need to be aware of the internal data and thus doesn't create a reverse dependency back to the runtime.

We can implement a general Codec-decoding framework for Javascript in order to allow the JSON to be recreated in middleware.

Metadata

Metadata

Assignees

Labels

I7-refactorCode needs refactoring.

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions