Releases: OpenRIAServices/OpenRiaServices
Releases · OpenRIAServices/OpenRiaServices
5.4.0-preview.1
- Add version of code generation which allows server project to be .NET 6 or later
- Works with dotnet build
A complete sample with WPF core and Asp.Net Core can be found at https://github.com/OpenRIAServices/Samples/tree/main/WpfCore_AspNetCore
What's Changed
- [AspNetCore]: Set more metadata on endpoints and allow conventions per service by @Daniel-Svensson in #425
- [CodeGen] Support net6+ on server by @lindellhugo @SandstromErik @Daniel-Svensson in #414
Full Changelog: v5.3.1...v5.4.0-preview.1
5.3.1 / EfCore 2.0.2 / Aspnetcore 0.3.0
5.3.1 with EFCore 2.0.2 and AspNetCore 0.3.0
- Code Generation
- Switch to using Mono.Cecil to parse pdb files during code generation (#410)
This should make it possible to use portable and embedded pdb's on the server
- Switch to using Mono.Cecil to parse pdb files during code generation (#410)
- AspNetCore
- New extension method to add OpenRiaServices to services.
services.AddOpenRiaServices<T>()
- New extension method to add OpenRiaServices to pipeline.
endpoints.MapOpenRiaServices(opt => opt.AddDomainService<T>())
- Add Net7 build target to support "Finally Conventions" (
IEndpointConventionBuilder.Finally
) - Add
OpenRiaServices.Server.DomainOperationEntry
to endpoint metadata- This allows end user to easier implement additional conventions (such as Open Api or similar)
- Copy
AuthorizationAttribute
s to endpoint metadata for queries and invokes to support AspNetCore Authorization- Attributes can be set on either method or class level
- Fixed serialization of sizes larger than 1 GB
- New extension method to add OpenRiaServices to services.
Other
- Updated nuget packages
5.3.0 / EfCore 2.0.1 / Aspnetcore 0.2.1
5.3.0 with EFCore 2.0.1
- Fix shadow property issue in EF Core DB Context extensions (#397):
- Based on Allianz PR #393
- Fix bug with shadowproperties being marked as modified when performing AttachAsModified in DbContextEFCoreExtensions
- DomainServiceTestHost improvements 1 (#395):
- Allow usage of CRUD-methods ending with Async in testhost.
- DomainServiceTestHost improvements 2 (#396):
- Add support for async IEnumerable queries in test host, i.e. querys returning
async Task<IEnumerable<
- Add support for async IEnumerable queries in test host, i.e. querys returning
Other
- Fixed github Code QL validation of builds
- Updated nuget packages
5.2.0 / EfCore 2.0.0 / Aspnetcore 0.2.0
AspNetCore 0.2.0
- Fix data corruption bug in 0.1.2 for large requests (#379)
- Prevent problem where output buffer becomes incorrect when parsing large requests from the client on x86 systems.
- Improved handling of operation cancelled exceptions (#381) by @SandstromErik
- Swallow or return completed task instead of throwing OperationCanceledExceptions
The release also contains the following fixes since 0.1.0 (0.1.2 was unlisted due to data corruption)
- AspNetCore: Prevention for DOS attacks where attacker specify large content-length #373
- AspNetCore: Use route order 0 instead of 1 (#357)
EFCore 2.0.0
- Support for EF Core 6.0 (#385) - by @lindellhugo with help from @ehsangfls code
- Added support for EF Core 6.0 (requires net 6.0)
- Added support for new EF Core attributes
ValueGenerated.OnUpdate
andValueGenerated.OnUpdateSometimes
(only EF Core 6)
5.2.0
- Client: Make construktors for Operation classes public to make them more testable (#387)
- Add new public constructors to LoadOperation, InvokeOperation and SubmitOperation
- DomainServiceTestHost improvements (#386):
- Add constructor which accept a single user (IPrincipal)
- BREAKING CHANGE: Constructor taking in Func<> and user does no longer accept null "user"
- use constructor without user in order to use the "default" user
- pass in an "unauthenticated" user to use an "unauthenticated" user
- Remove WCF Depdendency from tooling (#377)
Other
- Updated nuget packages used in tests (#382)
5.1.2 / AspNetCore 0.1.2
5.1.1
5.1.0
Overview / Major features
- Support for NET 6
- Support for EntityFrameworkCore via
OpenRiaServices.Server.EntityFrameworkCore
- New
BinaryHttpDomainClientFactory
which is aHttpClient
based transport on client (without WCF dependency) which works with Blazor (With sample in samples directory).
DomainContext.DomainClientFactory = new OpenRiaServices.Client.DomainClients.BinaryHttpDomainClientFactory(....)
{
ServerBaseUri = "https://YOUR_SERVER_URI"
};
- Server Dependency Injection support
- Allow injecting services to parameters using attribute
InjectParametersAttribute
- ValidationContext And AuthorizationContext will also be able to resolve services using
GetService(Type)
from the configuredIServiceProvider
- Add a new
IServiceProvider
setting to allow resolving services via Microsoft DI #340 when using WCF Hosting
- Allow injecting services to parameters using attribute
// Setup DI
var serviceCollection = new ServiceCollection();
serviceCollection.AddDomainServices(ServiceLifetime.Transient);
var serviceProvider = serviceCollection.BuildServiceProvider();
// Setup OpenRiaServices to use container
var config = OpenRiaServices.Hosting.Wcf.Configuration.Internal.DomainServiceHostingConfiguration.Current;
config.ServiceProvider = serviceProvider;
What's new since 5.1.0-preview5
- NEW: Package OpenRiaServices.Hosting.AspNetCore, OpenRiaServices.Server.EntityFrameworkCore
- Fix bug #348 System.IndexOutOfRangeException when domain query is executed which can happen if invoking methods concurrently on DomainClient
- DbDomainService now has a constructor which takes a DbContext in order to support Dependency Injection
- DbDomainService will no longer create a separate DbContext to resolve conflicts (if the method to create DbContext was overridden and returned a fixed instance it could lead to problems with incorrect conflict detection)
- Improve Tooling support for projects targeting multiple TargetFrameworks #352
- This fix ensures that sdk style implicit included code files are detected for server projects targeting multiple target frameworks.
Infreastructure
- Allow C# 10 #354
- Support for VS 2022
v4.6.4
5.1.0-preview5
- Make it possible to Cache invokes #332
- Introduce caching for Invoke operations by refactoring and using the same logic as for Querys
- Allow method (parameter) injection #339
- Allow parameters of type CancellationToken for all kinds of service methods
- Make the generated method return ValueTask so that the UnwrapTaskResult logic from ReflectionDomainServiceDescriptionProvider can be removed (and better performance)
- Allow injecting services to parameters using attribute InjectParametersAttribute
- Add a new IServiceProvider setting to allow resolving services via Microsoft DI #340
Add a new IServiceProvider setting toDomainServiceHostingConfiguration
The service provider must support scopes.
Example usage for use in Global Init/Startup.
// Setup DI
var serviceCollection = new ServiceCollection();
serviceCollection.AddDomainServices(ServiceLifetime.Transient);
var serviceProvider = serviceCollection.BuildServiceProvider();
// Setup OpenRiaServices to use container
var config = OpenRiaServices.Hosting.Wcf.Configuration.Internal.DomainServiceHostingConfiguration.Current;
config.ServiceProvider = serviceProvider;