[
https://issues.apache.org/jira/browse/HDDS-2270?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Arpit Agarwal reassigned HDDS-2270:
-----------------------------------
Assignee: Attila Doroszlai (was: Tsz-wo Sze)
> Avoid buffer copying in ContainerStateMachine.loadSnapshot/persistContainerSet
> ------------------------------------------------------------------------------
>
> Key: HDDS-2270
> URL: https://issues.apache.org/jira/browse/HDDS-2270
> Project: Hadoop Distributed Data Store
> Issue Type: Improvement
> Components: Ozone Datanode
> Reporter: Tsz-wo Sze
> Assignee: Attila Doroszlai
> Priority: Major
>
> ContainerStateMachine:
> - In loadSnapshot(..), it first reads the snapshotFile to a byte[] and then
> parses it to ContainerProtos.Container2BCSIDMapProto. The buffer copying can
> be avoided.
> {code}
> try (FileInputStream fin = new FileInputStream(snapshotFile)) {
> byte[] container2BCSIDData = IOUtils.toByteArray(fin);
> ContainerProtos.Container2BCSIDMapProto proto =
> ContainerProtos.Container2BCSIDMapProto
> .parseFrom(container2BCSIDData);
> ...
> }
> {code}
> - persistContainerSet(..) has similar problem.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]