[ 
https://issues.apache.org/jira/browse/IGNITE-27824?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Dmitry Werner updated IGNITE-27824:
-----------------------------------
    Description: 
Currently, certain messages (such as GridIoMessage and GridIoUserMessage) 
contain the fields Object topic and byte[] topicBytes. The marshaling and 
unmarshaling logic is located in different places: for GridIoMessage, it is 
implemented inside the message itself; for GridIoUserMessage, it is handled 
externally in the GridIoManager.

The goal of this task is to incapsulate the marshaling/unmarshaling of the 
topic to bytes in a single location — specifically, in a new message called 
GridTopicMessage. This will eliminate code duplication.

  was:
Currently, GridIoMessage contains three fields related to the topic: Object 
topic, byte[] topicBytes, int topicOrd.
The topicBytes and topicOrd fields are sent over the network.

It is necessary to consider the possibility of refactoring GridIoMessage and 
other messages with similar logic to reduce duplication.
For example, create a new class GridTopicMeta (implements Message) and 
encapsulate all the logic related to the topic in it, while making GridTopic a 
simple enum.


> Reduce duplication in message topic handling
> --------------------------------------------
>
>                 Key: IGNITE-27824
>                 URL: https://issues.apache.org/jira/browse/IGNITE-27824
>             Project: Ignite
>          Issue Type: Task
>            Reporter: Dmitry Werner
>            Assignee: Dmitry Werner
>            Priority: Minor
>              Labels: IEP-132, ise
>          Time Spent: 0.5h
>  Remaining Estimate: 0h
>
> Currently, certain messages (such as GridIoMessage and GridIoUserMessage) 
> contain the fields Object topic and byte[] topicBytes. The marshaling and 
> unmarshaling logic is located in different places: for GridIoMessage, it is 
> implemented inside the message itself; for GridIoUserMessage, it is handled 
> externally in the GridIoManager.
> The goal of this task is to incapsulate the marshaling/unmarshaling of the 
> topic to bytes in a single location — specifically, in a new message called 
> GridTopicMessage. This will eliminate code duplication.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to