Skip to content

Commit

Permalink
# 1.2.0
Browse files Browse the repository at this point in the history
- Upgrade ServiceBricks Version and all related packages to latest version
- Fix for AzureDataTables to associate queries for CacheKey to PartitionKey
- Fix for Cosmos to remove indexes from modelbuilder
- Fix for Cosmos to remove HasPartition from modelbuilder for .NET 9 using compiler directive
- Fix for MongoDb to associate queries for CacheKey to Id and mappingprofile changes
- Fix for MongoDb to change Id to Bson.string type and store CacheKey instead of an objectid
- Remove resources folder from webapp projects
  • Loading branch information
Danny Logsdon committed Jan 14, 2025
1 parent ded06b7 commit 84573a9
Show file tree
Hide file tree
Showing 121 changed files with 3,616 additions and 211 deletions.
18 changes: 18 additions & 0 deletions ReleaseNotes.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,21 @@
# 1.2.0
- Upgrade ServiceBricks Version and all related packages to latest version
- Fix for AzureDataTables to associate queries for CacheKey to PartitionKey
- Fix for Cosmos to remove indexes from modelbuilder
- Fix for Cosmos to remove HasPartition from modelbuilder for .NET 9 using compiler directive
- Fix for MongoDb to associate queries for CacheKey to Id and mappingprofile changes
- Fix for MongoDb to change Id to Bson.string type and store CacheKey instead of an objectid
- Remove resources folder from webapp projects

# 1.1.3
- Upgrade ServiceBricks Version

# 1.1.2
- Upgrade ServiceBricks Version

# 1.1.1
- Upgrade ServiceBricks Version

# 1.1.0
- Official Production Release

Expand Down
73 changes: 73 additions & 0 deletions ServiceBricksCacheV1.sln
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,28 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ServiceBricks.Cache.XunitNe
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ServiceBricks.Cache.Microservice", "src\V1\ServiceBricks.Cache.Microservice\ServiceBricks.Cache.Microservice.csproj", "{F7B7F3B2-7A30-482A-A9A5-CCF3DAEB4A76}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Net9", "Net9", "{4792F5F1-BDD8-431B-828E-0035791CF035}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ServiceBricks.Cache.AzureDataTables.XunitNet9", "src\V1\Tests\ServiceBricks.Cache.AzureDataTables.XunitNet9\ServiceBricks.Cache.AzureDataTables.XunitNet9.csproj", "{29D705AE-0C96-433D-ACF5-0A37B095DF28}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ServiceBricks.Cache.Client.XunitNet9", "src\V1\Tests\ServiceBricks.Cache.Client.XunitNet9\ServiceBricks.Cache.Client.XunitNet9.csproj", "{DCEF54FB-E227-4992-8FDF-4BC7AAD69154}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ServiceBricks.Cache.Cosmos.XunitNet9", "src\V1\Tests\ServiceBricks.Cache.Cosmos.XunitNet9\ServiceBricks.Cache.Cosmos.XunitNet9.csproj", "{C2647AED-0576-4C04-821D-18D3C1086EE4}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ServiceBricks.Cache.InMemory.XunitNet9", "src\V1\Tests\ServiceBricks.Cache.InMemory.XunitNet9\ServiceBricks.Cache.InMemory.XunitNet9.csproj", "{78F48946-B740-4D5F-9BD9-7F91B1AC3C73}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ServiceBricks.Cache.MongoDb.XunitNet9", "src\V1\Tests\ServiceBricks.Cache.MongoDb.XunitNet9\ServiceBricks.Cache.MongoDb.XunitNet9.csproj", "{435207BC-6ABF-4E71-8E9F-E5D12228A5CF}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ServiceBricks.Cache.Postgres.XunitNet9", "src\V1\Tests\ServiceBricks.Cache.Postgres.XunitNet9\ServiceBricks.Cache.Postgres.XunitNet9.csproj", "{68FDB266-6AC3-4418-833A-CC84067DF737}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ServiceBricks.Cache.Sqlite.XunitNet9", "src\V1\Tests\ServiceBricks.Cache.Sqlite.XunitNet9\ServiceBricks.Cache.Sqlite.XunitNet9.csproj", "{297E5DAF-9B29-4249-8DD1-85A6012E58BE}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ServiceBricks.Cache.SqlServer.XunitNet9", "src\V1\Tests\ServiceBricks.Cache.SqlServer.XunitNet9\ServiceBricks.Cache.SqlServer.XunitNet9.csproj", "{CA332462-763C-4AF7-9FEB-B45122A93514}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ServiceBricks.Cache.XunitNet9", "src\V1\Tests\ServiceBricks.Cache.XunitNet9\ServiceBricks.Cache.XunitNet9.csproj", "{F816A557-0B64-435E-BD66-25182664E4D4}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WebAppNet9", "src\V1\Tests\WebAppNet9\WebAppNet9.csproj", "{35F68E59-3F8C-495C-A10F-780FD9942384}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand Down Expand Up @@ -263,6 +285,46 @@ Global
{F7B7F3B2-7A30-482A-A9A5-CCF3DAEB4A76}.Debug|Any CPU.Build.0 = Debug|Any CPU
{F7B7F3B2-7A30-482A-A9A5-CCF3DAEB4A76}.Release|Any CPU.ActiveCfg = Release|Any CPU
{F7B7F3B2-7A30-482A-A9A5-CCF3DAEB4A76}.Release|Any CPU.Build.0 = Release|Any CPU
{29D705AE-0C96-433D-ACF5-0A37B095DF28}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{29D705AE-0C96-433D-ACF5-0A37B095DF28}.Debug|Any CPU.Build.0 = Debug|Any CPU
{29D705AE-0C96-433D-ACF5-0A37B095DF28}.Release|Any CPU.ActiveCfg = Release|Any CPU
{29D705AE-0C96-433D-ACF5-0A37B095DF28}.Release|Any CPU.Build.0 = Release|Any CPU
{DCEF54FB-E227-4992-8FDF-4BC7AAD69154}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{DCEF54FB-E227-4992-8FDF-4BC7AAD69154}.Debug|Any CPU.Build.0 = Debug|Any CPU
{DCEF54FB-E227-4992-8FDF-4BC7AAD69154}.Release|Any CPU.ActiveCfg = Release|Any CPU
{DCEF54FB-E227-4992-8FDF-4BC7AAD69154}.Release|Any CPU.Build.0 = Release|Any CPU
{C2647AED-0576-4C04-821D-18D3C1086EE4}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{C2647AED-0576-4C04-821D-18D3C1086EE4}.Debug|Any CPU.Build.0 = Debug|Any CPU
{C2647AED-0576-4C04-821D-18D3C1086EE4}.Release|Any CPU.ActiveCfg = Release|Any CPU
{C2647AED-0576-4C04-821D-18D3C1086EE4}.Release|Any CPU.Build.0 = Release|Any CPU
{78F48946-B740-4D5F-9BD9-7F91B1AC3C73}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{78F48946-B740-4D5F-9BD9-7F91B1AC3C73}.Debug|Any CPU.Build.0 = Debug|Any CPU
{78F48946-B740-4D5F-9BD9-7F91B1AC3C73}.Release|Any CPU.ActiveCfg = Release|Any CPU
{78F48946-B740-4D5F-9BD9-7F91B1AC3C73}.Release|Any CPU.Build.0 = Release|Any CPU
{435207BC-6ABF-4E71-8E9F-E5D12228A5CF}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{435207BC-6ABF-4E71-8E9F-E5D12228A5CF}.Debug|Any CPU.Build.0 = Debug|Any CPU
{435207BC-6ABF-4E71-8E9F-E5D12228A5CF}.Release|Any CPU.ActiveCfg = Release|Any CPU
{435207BC-6ABF-4E71-8E9F-E5D12228A5CF}.Release|Any CPU.Build.0 = Release|Any CPU
{68FDB266-6AC3-4418-833A-CC84067DF737}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{68FDB266-6AC3-4418-833A-CC84067DF737}.Debug|Any CPU.Build.0 = Debug|Any CPU
{68FDB266-6AC3-4418-833A-CC84067DF737}.Release|Any CPU.ActiveCfg = Release|Any CPU
{68FDB266-6AC3-4418-833A-CC84067DF737}.Release|Any CPU.Build.0 = Release|Any CPU
{297E5DAF-9B29-4249-8DD1-85A6012E58BE}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{297E5DAF-9B29-4249-8DD1-85A6012E58BE}.Debug|Any CPU.Build.0 = Debug|Any CPU
{297E5DAF-9B29-4249-8DD1-85A6012E58BE}.Release|Any CPU.ActiveCfg = Release|Any CPU
{297E5DAF-9B29-4249-8DD1-85A6012E58BE}.Release|Any CPU.Build.0 = Release|Any CPU
{CA332462-763C-4AF7-9FEB-B45122A93514}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{CA332462-763C-4AF7-9FEB-B45122A93514}.Debug|Any CPU.Build.0 = Debug|Any CPU
{CA332462-763C-4AF7-9FEB-B45122A93514}.Release|Any CPU.ActiveCfg = Release|Any CPU
{CA332462-763C-4AF7-9FEB-B45122A93514}.Release|Any CPU.Build.0 = Release|Any CPU
{F816A557-0B64-435E-BD66-25182664E4D4}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{F816A557-0B64-435E-BD66-25182664E4D4}.Debug|Any CPU.Build.0 = Debug|Any CPU
{F816A557-0B64-435E-BD66-25182664E4D4}.Release|Any CPU.ActiveCfg = Release|Any CPU
{F816A557-0B64-435E-BD66-25182664E4D4}.Release|Any CPU.Build.0 = Release|Any CPU
{35F68E59-3F8C-495C-A10F-780FD9942384}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{35F68E59-3F8C-495C-A10F-780FD9942384}.Debug|Any CPU.Build.0 = Debug|Any CPU
{35F68E59-3F8C-495C-A10F-780FD9942384}.Release|Any CPU.ActiveCfg = Release|Any CPU
{35F68E59-3F8C-495C-A10F-780FD9942384}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand Down Expand Up @@ -302,6 +364,17 @@ Global
{C836AEFC-1E29-4901-B3EE-A06296EC94EE} = {2A107B89-703B-4FC1-B7CA-1EE63FC05110}
{75B2418D-22F1-447A-B95C-49233B864D31} = {2A107B89-703B-4FC1-B7CA-1EE63FC05110}
{973BD18A-86A0-4F55-A624-6F66519B12A6} = {3788051A-9941-4C44-9E4C-BC073F69DD2F}
{4792F5F1-BDD8-431B-828E-0035791CF035} = {FAFF233D-FB99-4FA7-A412-E58ED97CE3C2}
{29D705AE-0C96-433D-ACF5-0A37B095DF28} = {4792F5F1-BDD8-431B-828E-0035791CF035}
{DCEF54FB-E227-4992-8FDF-4BC7AAD69154} = {4792F5F1-BDD8-431B-828E-0035791CF035}
{C2647AED-0576-4C04-821D-18D3C1086EE4} = {4792F5F1-BDD8-431B-828E-0035791CF035}
{78F48946-B740-4D5F-9BD9-7F91B1AC3C73} = {4792F5F1-BDD8-431B-828E-0035791CF035}
{435207BC-6ABF-4E71-8E9F-E5D12228A5CF} = {4792F5F1-BDD8-431B-828E-0035791CF035}
{68FDB266-6AC3-4418-833A-CC84067DF737} = {4792F5F1-BDD8-431B-828E-0035791CF035}
{297E5DAF-9B29-4249-8DD1-85A6012E58BE} = {4792F5F1-BDD8-431B-828E-0035791CF035}
{CA332462-763C-4AF7-9FEB-B45122A93514} = {4792F5F1-BDD8-431B-828E-0035791CF035}
{F816A557-0B64-435E-BD66-25182664E4D4} = {4792F5F1-BDD8-431B-828E-0035791CF035}
{35F68E59-3F8C-495C-A10F-780FD9942384} = {4792F5F1-BDD8-431B-828E-0035791CF035}
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {65CAA504-F611-4706-99C4-A400709A871D}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ public override IResponse ExecuteRule(IBusinessRuleContext context)
ApiConcurrencyByUpdateDateRule<CacheData, CacheDataDto>.Register(BusinessRuleRegistry.Instance);
CacheDataCreateRule.Register(BusinessRuleRegistry.Instance);
DomainQueryPropertyRenameRule<CacheData>.Register(BusinessRuleRegistry.Instance, "StorageKey", "PartitionKey");
DomainQueryPropertyRenameRule<CacheData>.Register(BusinessRuleRegistry.Instance, "CacheKey", "PartitionKey");

return response;
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<Version>1.1.3</Version>
<Version>1.2.0</Version>
<Description>The open source microservices platform. Visit https://ServiceBricks.com to learn more.</Description>
<PackageId>ServiceBricks.Cache.AzureDataTables</PackageId>
<Title>ServiceBricks.Cache.AzureDataTables</Title>
<AssemblyTitle>ServiceBricks.Cache.AzureDataTables</AssemblyTitle>
<Authors>holomodular</Authors>
<Company>HoloModular LLC</Company>
<Product>ServiceBricks</Product>
<TargetFrameworks>net6.0;net7.0;net8.0</TargetFrameworks>
<TargetFrameworks>net6.0;net7.0;net8.0;net9.0</TargetFrameworks>
<Nullable>disable</Nullable>
<Copyright>Copyright © 2024 HoloModular LLC. All Rights Reserved. Visit https://HoloModular.com to learn more.</Copyright>
<PackageProjectUrl>https://ServiceBricks.com</PackageProjectUrl>
Expand All @@ -36,6 +36,6 @@
<ProjectReference Include="..\ServiceBricks.Cache\ServiceBricks.Cache.csproj" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="ServiceBricks.Core" Version="1.1.3" />
<PackageReference Include="ServiceBricks.Core" Version="1.2.0" />
</ItemGroup>
</Project>
20 changes: 18 additions & 2 deletions src/V1/ServiceBricks.Cache.Cosmos/Model/CacheCosmosContext.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
using Microsoft.EntityFrameworkCore;
using ServiceBricks.Cache.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Diagnostics;

namespace ServiceBricks.Cache.Cosmos
{
Expand Down Expand Up @@ -34,9 +35,24 @@ protected override void OnModelCreating(ModelBuilder builder)

// AI: Create the model for each table
builder.Entity<CacheData>().HasKey(key => key.CacheKey);
builder.Entity<CacheData>().HasPartitionKey(key => key.CacheKey);
builder.Entity<CacheData>().HasIndex(key => new { key.ExpirationDate }); // For background process
builder.Entity<CacheData>().ToContainer(CacheCosmosConstants.GetContainerName(nameof(CacheData)));
#if NET9_0
#else
builder.Entity<CacheData>().HasPartitionKey(key => key.CacheKey);
#endif
}

/// <summary>
/// OnConfiguring
/// </summary>
/// <param name="optionsBuilder"></param>
protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder)
{
#if NET9_0
optionsBuilder.ConfigureWarnings(w => w.Ignore(CosmosEventId.SyncNotSupported));
#endif

base.OnConfiguring(optionsBuilder);
}

/// <summary>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<Version>1.1.3</Version>
<Version>1.2.0</Version>
<Description>The open source microservices platform. Visit https://ServiceBricks.com to learn more.</Description>
<PackageId>ServiceBricks.Cache.Cosmos</PackageId>
<Title>ServiceBricks.Cache.Cosmos</Title>
<AssemblyTitle>ServiceBricks.Cache.Cosmos</AssemblyTitle>
<Authors>holomodular</Authors>
<Company>HoloModular LLC</Company>
<Product>ServiceBricks</Product>
<TargetFrameworks>net6.0;net7.0;net8.0</TargetFrameworks>
<TargetFrameworks>net6.0;net7.0;net8.0;net9.0</TargetFrameworks>
<Nullable>disable</Nullable>
<Copyright>Copyright © 2024 HoloModular LLC. All Rights Reserved. Visit https://HoloModular.com to learn more.</Copyright>
<PackageProjectUrl>https://ServiceBricks.com</PackageProjectUrl>
Expand All @@ -36,7 +36,7 @@
<ProjectReference Include="..\ServiceBricks.Cache.EntityFrameworkCore\ServiceBricks.Cache.EntityFrameworkCore.csproj" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="ServiceBricks.Core" Version="1.1.3" />
<PackageReference Include="ServiceBricks.Core" Version="1.2.0" />
</ItemGroup>

</Project>
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<Version>1.1.3</Version>
<Version>1.2.0</Version>
<Description>The open source microservices platform. Visit https://ServiceBricks.com to learn more.</Description>
<PackageId>ServiceBricks.Cache.EntityFrameworkCore</PackageId>
<Title>ServiceBricks.Cache.EntityFrameworkCore</Title>
<AssemblyTitle>ServiceBricks.Cache.EntityFrameworkCore</AssemblyTitle>
<Authors>holomodular</Authors>
<Company>HoloModular LLC</Company>
<Product>ServiceBricks</Product>
<TargetFrameworks>net6.0;net7.0;net8.0</TargetFrameworks>
<TargetFrameworks>net6.0;net7.0;net8.0;net9.0</TargetFrameworks>
<Nullable>disable</Nullable>
<Copyright>Copyright © 2024 HoloModular LLC. All Rights Reserved. Visit https://HoloModular.com to learn more.</Copyright>
<PackageProjectUrl>https://ServiceBricks.com</PackageProjectUrl>
Expand All @@ -36,6 +36,6 @@
<ProjectReference Include="..\ServiceBricks.Cache\ServiceBricks.Cache.csproj" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="ServiceBricks.Core" Version="1.1.3" />
<PackageReference Include="ServiceBricks.Core" Version="1.2.0" />
</ItemGroup>
</Project>
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<Version>1.1.3</Version>
<Version>1.2.0</Version>
<Description>The open source microservices platform. Visit https://ServiceBricks.com to learn more.</Description>
<PackageId>ServiceBricks.Cache.InMemory</PackageId>
<Title>ServiceBricks.Cache.InMemory</Title>
<AssemblyTitle>ServiceBricks.Cache.InMemory</AssemblyTitle>
<Authors>holomodular</Authors>
<Company>HoloModular LLC</Company>
<Product>ServiceBricks</Product>
<TargetFrameworks>net6.0;net7.0;net8.0</TargetFrameworks>
<TargetFrameworks>net6.0;net7.0;net8.0;net9.0</TargetFrameworks>
<Nullable>disable</Nullable>
<Copyright>Copyright © 2024 HoloModular LLC. All Rights Reserved. Visit https://HoloModular.com to learn more.</Copyright>
<PackageProjectUrl>https://ServiceBricks.com</PackageProjectUrl>
Expand All @@ -36,7 +36,7 @@
<ProjectReference Include="..\ServiceBricks.Cache.EntityFrameworkCore\ServiceBricks.Cache.EntityFrameworkCore.csproj" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="ServiceBricks.Core" Version="1.1.3" />
<PackageReference Include="ServiceBricks.Core" Version="1.2.0" />
</ItemGroup>

</Project>
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<Version>1.1.3</Version>
<Version>1.2.0</Version>
<Description>The open source microservices platform. Visit https://ServiceBricks.com to learn more.</Description>
<PackageId>ServiceBricks.Cache.Microservice</PackageId>
<Title>ServiceBricks.Cache.Microservice</Title>
<AssemblyTitle>ServiceBricks.Cache.Microservice</AssemblyTitle>
<Authors>holomodular</Authors>
<Company>HoloModular LLC</Company>
<Product>ServiceBricks</Product>
<TargetFrameworks>net6.0;net7.0;net8.0</TargetFrameworks>
<TargetFrameworks>net6.0;net7.0;net8.0;net9.0</TargetFrameworks>
<Nullable>disable</Nullable>
<Copyright>Copyright © 2024 HoloModular LLC. All Rights Reserved. Visit https://HoloModular.com to learn more.</Copyright>
<Copyright>Copyright © 2025 HoloModular LLC. All Rights Reserved. Visit https://HoloModular.com to learn more.</Copyright>
<PackageProjectUrl>https://ServiceBricks.com</PackageProjectUrl>
<PackageIcon>logo.png</PackageIcon>
<PackageTags>servicebricks;cache;microservice</PackageTags>
Expand All @@ -34,7 +34,7 @@
</None>
</ItemGroup>
<ItemGroup>
<PackageReference Include="ServiceBricks.Core" Version="1.1.3" />
<PackageReference Include="ServiceBricks.Core" Version="1.2.0" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\ServiceBricks.Cache\ServiceBricks.Cache.csproj" PrivateAssets="All">
Expand Down
2 changes: 1 addition & 1 deletion src/V1/ServiceBricks.Cache.MongoDb/Domain/CacheData.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ public partial class CacheData : MongoDbDomainObject<CacheData>, IDpCreateDate,
/// Internal Primary Key.
/// </summary>
[BsonId]
[BsonRepresentation(BsonType.ObjectId)]
[BsonRepresentation(BsonType.String)]
public string Id { get; set; }

/// <summary>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@ public CacheDataMappingProfile()
// AI: Map the CacheDataDto to the CacheData
CreateMap<CacheDataDto, CacheData>()
.ForMember(x => x.CreateDate, y => y.Ignore())
.ForMember(x => x.Id, y => y.MapFrom(z => z.StorageKey));
.ForMember(x => x.Id, y => y.MapFrom(z => string.IsNullOrEmpty(z.CacheKey) ? z.StorageKey : z.CacheKey))
.ForMember(x => x.CacheKey, y => y.MapFrom(z => string.IsNullOrEmpty(z.CacheKey) ? z.StorageKey : z.CacheKey));

CreateMap<CacheData, CacheDataDto>()
.ForMember(x => x.StorageKey, y => y.MapFrom(z => z.Id));
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<Version>1.1.3</Version>
<Version>1.2.0</Version>
<Description>The open source microservices platform. Visit https://ServiceBricks.com to learn more.</Description>
<PackageId>ServiceBricks.Cache.MongoDb</PackageId>
<Title>ServiceBricks.Cache.MongoDb</Title>
<AssemblyTitle>ServiceBricks.Cache.MongoDb</AssemblyTitle>
<Authors>holomodular</Authors>
<Company>HoloModular LLC</Company>
<Product>ServiceBricks</Product>
<TargetFrameworks>net6.0;net7.0;net8.0</TargetFrameworks>
<TargetFrameworks>net6.0;net7.0;net8.0;net9.0</TargetFrameworks>
<Nullable>disable</Nullable>
<Copyright>Copyright © 2024 HoloModular LLC. All Rights Reserved. Visit https://HoloModular.com to learn more.</Copyright>
<PackageProjectUrl>https://ServiceBricks.com</PackageProjectUrl>
Expand All @@ -36,7 +36,7 @@
<ProjectReference Include="..\ServiceBricks.Cache\ServiceBricks.Cache.csproj" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="ServiceBricks.Core" Version="1.1.3" />
<PackageReference Include="ServiceBricks.Core" Version="1.2.0" />
</ItemGroup>

</Project>
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<Version>1.1.3</Version>
<Version>1.2.0</Version>
<Description>The open source microservices platform. Visit https://ServiceBricks.com to learn more.</Description>
<PackageId>ServiceBricks.Cache.Postgres</PackageId>
<Title>ServiceBricks.Cache.Postgres</Title>
<AssemblyTitle>ServiceBricks.Cache.Postgres</AssemblyTitle>
<Authors>holomodular</Authors>
<Company>HoloModular LLC</Company>
<Product>ServiceBricks</Product>
<TargetFrameworks>net6.0;net7.0;net8.0</TargetFrameworks>
<TargetFrameworks>net6.0;net7.0;net8.0;net9.0</TargetFrameworks>
<Nullable>disable</Nullable>
<Copyright>Copyright © 2024 HoloModular LLC. All Rights Reserved. Visit https://HoloModular.com to learn more.</Copyright>
<PackageProjectUrl>https://ServiceBricks.com</PackageProjectUrl>
Expand All @@ -36,7 +36,7 @@
<ProjectReference Include="..\ServiceBricks.Cache.EntityFrameworkCore\ServiceBricks.Cache.EntityFrameworkCore.csproj" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="ServiceBricks.Core" Version="1.1.3" />
<PackageReference Include="ServiceBricks.Core" Version="1.2.0" />
</ItemGroup>

</Project>
Loading

0 comments on commit 84573a9

Please sign in to comment.