Commit Graph

41 Commits

Author SHA1 Message Date
Ben Marsh
32ab8d1b88 CS: Support for serialization and deserialization of polymorphic class hierarchies into compact binary.
The base class in a hierarchy must have the [CbPolymorphic] attribute, and derived classes must have the [CbDiscriminator] attribute, giving an identifier to indicate the derived type.

#preflight none
#p4v-preflight-copy 18635755
#preflight 61e6d83a7f0c4b5aad620c89

[CL 18640150 by Ben Marsh in ue5-main branch]
2022-01-18 10:30:25 -05:00
Ben Marsh
17fda19db7 CS: Support for serialization and deserialization of polymorphic class hierarchies.
The base class in a hierarchy must have the [CbPolymorphic] attribute, and derived classes must have the [CbDiscriminator] attribute, giving an identifier to indicate the derived type.

#preflight none
#preflight 61e600aa3778a195de94dc27

[CL 18635774 by Ben Marsh in ue5-main branch]
2022-01-17 18:52:44 -05:00
Ben Marsh
edb86dcf5b Horde: Fix build error.
#preflight none

[CL 18630244 by Ben Marsh in ue5-main branch]
2022-01-16 18:52:58 -05:00
Ben Marsh
9e6e68ba17 CS: Add overloads for commonly serialized compact binary types.
#preflight 61e4a67d7b0f77175a5d6621

[CL 18630220 by Ben Marsh in ue5-main branch]
2022-01-16 18:26:30 -05:00
Ben Marsh
5e131f7ddc CS: Rename compact binary files to match the classes they contain.
#preflight none

[CL 18628533 by Ben Marsh in ue5-main branch]
2022-01-15 13:33:44 -05:00
Ben Marsh
7e7bec2660 Horde: Include hourly rate for using an agent in returned agent and job documents.
Global config file now includes a list of conditions which are evaluated against an agent's properties. The first condition that matches specifies the rate for the agent. This should give us plenty of flexibility in pricing out esoteric configurations dependent on factors like instance type, OS, etc...

Rates are cached in Redis and re-evaluated every 5 minutes.

#fyi Josh.Engebretson
#preflight none

[CL 18469963 by Ben Marsh in ue5-main branch]
2021-12-15 14:47:12 -05:00
Ryan Durand
bcac0e411f Fix symbols publishing for Horde.Agent builds.
#rnx
#jira none
#rb ben.marsh

[CL 18423821 by Ryan Durand in ue5-main branch]
2021-12-09 15:21:08 -05:00
Ben Marsh
e1cb80903f Horde: Fix tests in serialization library.
#fyi Ryan.Durand

[CL 18271689 by Ben Marsh in ue5-main branch]
2021-11-23 12:18:30 -05:00
Ben Marsh
c3df64ec48 Horde: Add support for directly serializing raw compact binary objects. Fixes the /api/v1/objects endpoint when given a compact binary content type.
#fyi Joe.Kirchoff

[CL 17889706 by Ben Marsh in ue5-main branch]
2021-10-21 16:14:26 -04:00
Ben Marsh
e68d68c639 Horde: Add convenience methods in CompactBinarySerializer to read/write from byte spans.
[CL 17721938 by Ben Marsh in ue5-main branch]
2021-10-05 11:16:41 -04:00
Ben Marsh
2f6b890df1 Horde: Reduce memory usage when capturing workspace (part 2)
* Added UTF8 native version of fstat record to avoid unnecessary conversions
* Avoid conversion to/from UTF8 strings when converting Perforce records into CB objects
* Fixed implicit conversion of string to UTF8 string in argument check
* Converted ViewMap to use UTF8 strings

[CL 17601088 by Ben Marsh in ue5-main branch]
2021-09-22 17:34:10 -04:00
Ben Marsh
2d70fb8adc Horde: Reduce memory usage when querying workspace state (pt 1)
* CbWriter instances may now be cleared, and can cache allocated buffers between uses.
* Records may now be returned using IAsyncEnumerable<T> allowing them to be processed as they are received, and removing the need to allocate large numbers of temporary objects.

[CL 17599803 by Ben Marsh in ue5-main branch]
2021-09-22 16:10:08 -04:00
Ben Marsh
0318e8cb19 Horde: Add compact binary and string conversion classes for condition objects, and embed them directly in agent requirements. Simplifies unification of agent specifications.
[CL 17484376 by Ben Marsh in ue5-main branch]
2021-09-10 19:05:19 -04:00
Ben Marsh
8e42d6fdde Horde: Add support for serializing ReadOnlyMemory<> and byte arrays to reflection-based CB serializer.
[CL 17432013 by Ben Marsh in ue5-main branch]
2021-09-04 10:26:56 -04:00
Ben Marsh
5ea27fc47c Horde: Allow requesting objects in JSON format using a ".json" suffix on the URL. Compact binary objects will automatically be transcoded.
[CL 17409520 by Ben Marsh in ue5-main branch]
2021-09-02 17:47:31 -04:00
Ben Marsh
342edb1d81 Horde: Fixup compute API to use CbObjectAttachment/CbBinaryAttachment types where appropriate.
#fyi Joe.Kirchoff

[CL 17409049 by Ben Marsh in ue5-main branch]
2021-09-02 16:57:20 -04:00
Ben Marsh
177ad8c2ac Horde: Add compact binary request/response support to objects controller.
[CL 17405657 by Ben Marsh in ue5-main branch]
2021-09-02 13:44:25 -04:00
Ben Marsh
0d875b2910 Horde: Add CbObjectAttachment and CbBinaryAttachment classes to reference typed data by class. We need to distinguish between the two types rather than relying solely on a hash value.
#fyi Joe.Kirchoff

[CL 17391146 by Ben Marsh in ue5-main branch]
2021-09-01 15:22:32 -04:00
Ben Marsh
77210c0efc Horde: Fix DateTime CB serialization tests.
[CL 17368297 by Ben Marsh in ue5-main branch]
2021-08-31 10:56:03 -04:00
Ben Marsh
564ecec2bb Horde: Add support for serializing requests and responses as compact binary objects.
[CL 17250722 by Ben Marsh in ue5-main branch]
2021-08-20 14:28:49 -04:00
Ben Marsh
ef5988a226 Horde: Include file and directory sizes in DirectoryTree objects, as well as file attributes.
#fyi Joe.Kirchoff

[CL 17235171 by Ben Marsh in ue5-main branch]
2021-08-19 12:03:00 -04:00
Ben Marsh
75a96a6ac6 Allow serializing structs to compact binary objects using reflection, and automatically instantiate converter types with the same generic arguments as the tagged class if necessary.
[CL 17171079 by Ben Marsh in ue5-main branch]
2021-08-14 17:47:38 -04:00
Ben Marsh
36646e683f Add support for serializing int, DateTime, Nullable, and enum types to compact binary through reflection.
Also fix deserialized DateTime values being treated as local times rather than UTC.

[CL 17161724 by Ben Marsh in ue5-main branch]
2021-08-12 20:15:32 -04:00
jonathan adamczewski
db8046e278 Move DotNETCommon/BuildUtilities to Shared/EpicGames.Build
Also moves DotNETCommon/Metadata.cs to Shared/Metadata.cs

#jira none
#rb tim.smith

[CL 17116964 by jonathan adamczewski in ue5-main branch]
2021-08-10 11:08:41 -04:00
Ben Marsh
7572b4ed1a Horde: Support serialization of bool values to compact binary objects through attribute-driven serialization.
[CL 17094350 by Ben Marsh in ue5-main branch]
2021-08-07 10:41:52 -04:00