- Cache route path regexes.
- Support
float
data type.
- Fix codegen bug when copying a nullable field when nullable references are not enabled.
- Drop support for end-of-life frameworks.
- Use roll forward with .NET tools.
- Bump
MessagePack
andSystem.Text.Json
versions to address vulnerabilities. - Fix codegen bug when copying a nullable field.
- Allow missing or empty HTTP content to be treated as an empty DTO for backward compatibility with method bodies that previously had no fields.
- Improve nullable analysis of
ServiceResult.Error
.
- Support events.
- Don't use
ToArray
unless needed for JSON source generation.
- Support metadata-based source generation for
System.Text.Json
via--json-source-gen
and--json-source-gen-if
. It is optional because it significantly increases assembly size and slightly decreases performance. It may be worth considering for its other benefits.
- Convert
Microsoft.AspNetCore.*
exceptions to errors.
- Add
SystemTextJsonServiceSerializer.ConfigureJsonSerializerOptions
.
- Add
ServiceResultUtility.TryGetValue
. - Add .NET 8 targets.
- Add
RequestReadyAsync
override toHttpClientService
.
- Add
HttpClientServiceSettings.Clone
. - Support collection syntax with MessagePack properties.
- Throw
ArgumentNullException
instead ofNullReferenceException
when usingServiceDelegators.Validate
with a null request.
- Add option for default namespace, used when not specified in the FSD.
- Make it easier to switch between
ServiceObject
and a DTO.
- Support
datetime
.
- Allow named floating point literals.
- Support reading string from Boolean or number.
- Support reading Boolean from string.
- Support
extern
data and enum types.
- Update dependencies, including Newtonsoft.Json.
- Add .NET 7; remove .NET Core 3.1 and .NET 5.
- Support nullable fields.
- Add
--disable-chunked-transfer
to conformance app. - Trim beginning slash from path in conformance tester.
- Don't escape "unsafe" punctuation and non-ASCII when writing JSON.
- Avoid broken default serialization when using JToken with System.Text.Json.
- Don't use wildcard media type from
Accept
header (e.g.*/*
ortext/*
) directly asContent-Type
of response.
- Support MessagePack for serialization.
- To use faster/smaller indexed keys, add
[msgpack(key: 0)]
,[msgpack(key: 1)]
, etc. to the data fields in your FSD. - Use
--msgpack
withfsdgencsharp
to generate MessagePack-compatible DTOs. - Reference the
Facility.Core.MessagePack
NuGet package in your client and/or service. - For clients, set
HttpClientServiceSettings.ContentSerializer
toMessagePackServiceSerializer.Instance
to send and receive MessagePack (rather than JSON) by specifyingapplication/msgpack
in theContent-Type
andAccept
headers. - For servers, set
ServiceHttpHandlerSettings.ContentSerializer
toHttpContentSerializer.Combine(SystemTextJsonServiceSerializer.Instance, MessagePackServiceSerializer.Instance)
to support JSON by default but use MessagePack whenapplication/msgpack
is specified in theAccept
header.
- To use faster/smaller indexed keys, add
- Improve API for accessing or mutating service objects.
- Allow service objects to be mutated via
AsJObject
orAsJsonObject
. Add clarifying comments. - Add
ToJObject
andToJsonObject
for safer access.
- Allow service objects to be mutated via
- Add .NET 6 targets.
- Catch
UriFormatException
on request.
- Support fixing snake case in definitions.
- Improve performance of
NewtonsoftJsonServiceSerializer.Clone
.
- Fix build that didn't work properly on .NET 5 or .NET Core 3.1.
- Generated delegating service class as a partial class.
- Support
Newtonsoft.Json.Linq
properties withSystemTextJsonServiceSerializer
.
- Use conformance data that serializes precisely.
- Serialize and deserialize JSON using
System.Text.Json
and async I/O.- Old clients and services will continue to use
Newtonsoft.Json
(Json.NET) until code is regenerated, after whichSystem.Text.Json
will be used unlessContentSerializer
is set toNewtonsoftJsonServiceSerializer.Instance
. - ASP.NET Core applications that continue to use Json.NET will need to set
AllowSynchronousIO
to true, since Json.NET doesn't support async serialization.
- Old clients and services will continue to use
- Use chunked transfer encoding. Add
DisableChunkedTransfer
setting.- DTOs are no longer serialized to/from an intermediate memory stream, which should improve performance and memory usage on clients and servers.
- Use
ServiceObject
instead ofJObject
for FSDobject
fields. This is a breaking change in generated DTOs that useobject
. - Support .NET 6.
- Add .NET 6 support to tools.
- Fix nullability of generated
Equals
. - Drop .NET Core 2.1 support from tools.
- Fix bug when calling
IsDefined
on default enums.
- Don't do cache lookup when not needed.
- Add explicit visibility to code-generated fields.
- Fix bug when comparing default enums.
- Generate string constants for enums.
- Create standard validating delegator.
- Support DTO validation with
[validate]
fields.
- Fix bug where HTTP path was not case-insensitive when path variables were used.
- HTTP query parameter names should be case-insensitive.
- Add some conformance tests for case insensitivity.
- Support bytes/strings as request/response body fields.
- Support custom content type on request/response body fields.
- Support
Content-Type
as header fields.
- Update dependencies.
- Support and generate delegating implementations of services.
- Allow default cancellation token on public client methods.
- Add .NET 5 support to
fsdgencsharp
andFacilityConformance
. - Nullable reference improvement to
ServiceResult.GetValueOrDefault
.
- Simplify generated null check.
- Add .NET Standard 2.1 target.
- Make
ServiceResult<T>.GetValueOrDefault
maybe null.
- Only load JSON streams into memory when
ForceAsyncIO
is set. - Add
JsonHttpContentSerializer.MemoryStreamCreator
.
- Load JSON request streams into memory to avoid synchronous I/O, which ASP.NET Core doesn't allow by default. (This was already true for JSON responses.)
- Add .NET Core App 3.1 support to
fsdgencsharp
andFacilityConformance
. - A few nullable reference improvements.
- Update
Facility.Definition
andFacility.CodeGen.Console
.
- Support shorthand for required attribute, e.g.
string!
.
- Support DTO validation, specifically for
[required]
fields.
- Support nullable references.
- Use
--nullable
to generate code with nullable references. - Add
ServiceResult.ToFailure
.
- Expose
BaseUri
to derivedHttpClientService
. - Stop using
System.Net.Http
reference. - Minor optimization in
HttpClientService
.
- Stop using
System.Net.Http
NuGet package.
- Upgrade to .NET Standard 2.0.
- Upgrade NuGet dependencies, including
Facility.Definition
andFacility.CodeGen.Console
. - Convert
fsdgencsharp
to a .NET Core Global Tool. - Drop
--csproj
support fromfsdgencsharp
(SDK-style projects don't need it.) - Support static
CSharpGenerator.GenerateCSharp
for C# build scripts. - Publish
Facility.ConformanceApi
library andFacilityConformance
tool. - Allow null
ServiceHttpHandlerSettings
.
- Start tracking version history.