Define rule for object's header JSON marshaling #49

Closed
opened 2025-12-28 18:12:20 +00:00 by sami · 1 comment
Owner

Originally created by @carpawell on GitHub (Jun 4, 2021).

Originally assigned to: @carpawell on GitHub.

There is a need to get objects's header in JSON format in neo-go codebase. Now ToV2 func is used for obtaining v2 object structure and than v2's JSON marshaling is called.

It seems that using v2 abstractions outside api-go repository is unwanted behaviour. But addition header related methods to pkg/object is also not really good solution.

Therefore, we need to define what is canonical way to marshal object's header.

Originally created by @carpawell on GitHub (Jun 4, 2021). Originally assigned to: @carpawell on GitHub. There is a need to get objects's header in JSON format in neo-go codebase. Now `ToV2` func is used for obtaining v2 object structure and than `v2`'s JSON marshaling is called. It seems that using `v2` abstractions outside api-go repository is unwanted behaviour. But addition header related methods to `pkg/object` is also not really good solution. Therefore, we need to define what is canonical way to marshal object's header.
sami 2025-12-28 18:12:20 +00:00
Author
Owner

@carpawell commented on GitHub (Jun 7, 2021):

After discussion, it was decided to add a method for marshaling an object's header in JSON format to the highest object structure.

@carpawell commented on GitHub (Jun 7, 2021): After discussion, it was decided to add a method for marshaling an object's header in JSON format to the highest object structure.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
nspcc-dev/neofs-api-go#49
No description provided.