Commit Graph

7 Commits

Author SHA1 Message Date
Ben Marsh
9ffdf8e25f EpicGames.Core: Change IMemoryWriter to derive from IBufferWriter<byte>.
#preflight none

[CL 23550562 by Ben Marsh in ue5-main branch]
2022-12-20 11:14:38 -05:00
Ben Marsh
0d70ed83e6 Horde: Refactor IStorageClient.
* Now supports partial reads of blobs, and caches them inside StorageClientBase.
* IStorageClient includes methods for reading/writing TreeNode-derived classes, and caches bundle information and encoded/decoded packets internally.
* TreeWriter class can be used for packing data together into bundles. Supports creating async tasks to fence nodes being flushed rather than an explicit concept of forking child writers.

#preflight none

[CL 22192856 by Ben Marsh in ue5-main branch]
2022-09-26 16:09:47 -04:00
Ben Marsh
d06078c7f2 Horde: Add Stream wrappers around IMemoryReader and IMemoryWriter, and fix ByteArrayBuilder.GetMemory() always returning the minimum buffer size.
#preflight none

[CL 22136931 by Ben Marsh in ue5-main branch]
2022-09-22 11:23:43 -04:00
Ben Marsh
e76aa468b5 Horde: Attempts to reduce memory usage for bundle stores.
* Add configurable size for bundle cache, and disable it by default.
* Sum up sizes of directories to sync without duplicating paths of every file.
* Use ByteArrayBuilder to create segments for bundles rather than concatenating to one large array.

#preflight none

[CL 21357732 by Ben Marsh in ue5-main branch]
2022-08-12 12:57:28 -04:00
Ben Marsh
a38d9cf47a EpicGames.Core: Fix some serialization issues with IMemoryReader/IMemoryWriter, and add a class to build ReadOnlySequence<T> objects.
#preflight 62bbbdc6ee7cb716b4185c45

[CL 20868832 by Ben Marsh in ue5-main branch]
2022-06-28 22:57:08 -04:00
Ben Marsh
cbd0f5ea19 Add a common interface for reading/writing to memory (IMemoryReader/IMemoryWriter), which is implemented by the legacy MemoryReader/MemoryWriter classes as well as the newer ByteArrayBuilder.
Also moves VarInt into EpicGames.Core.
#preflight 62bb5e3efd06251187efd3d7

[CL 20863839 by Ben Marsh in ue5-main branch]
2022-06-28 16:14:51 -04:00
Ben Marsh
8704afa553 EpicGames.Core: Add a utility class to serialize data into a chunked byte sequence, similar to StringBuilder.
#preflight none

[CL 20774539 by Ben Marsh in ue5-main branch]
2022-06-22 10:46:05 -04:00