This is a preview release of Duende Spaces. It builds on Duende Storage 2.0.0-preview.6.
Breaking changes
- Data protection is partitioned by space by default. Every data protector is bound to the space in effect when it protects or unprotects, so a value protected in one space can't be read in another. Values protected before this change keep working in the Default space only; in other spaces, cookies and other protected values from earlier versions can no longer be read, so users have to sign in again. Set
SpacesOptions.PartitionDataProtectiontofalseto turn this off. - Space names longer than 500 characters are rejected when a space is created or updated.
What's changed
- Shared data across spaces. Use
GetUnpartitioned()on the data protection provider (orIUnpartitionedDataProtectionSource) for data that must be readable in every space, such as signing keys. - Own cache for Spaces. Spaces caches space resolution and routing in a
HybridCacheregistered underSpacesServiceProviderKeys.SpacesCache. Register your own under that key, for example to use a separate distributed cache; otherwise Spaces registers one with default settings. - Cache entries per space. Entries in the space-aware
HybridCacheare keyed by space, so two spaces using the same key no longer share a value.RemoveByTagAsyncstill removes matching entries in every space. - Space queries. Space queries honor paging, sorting and filters, and return the filtered total.
Fixes
- Response callbacks (
OnStarting,OnCompleted) now run in the space they were registered in. Before, a sliding cookie renewed on a response without a body failed with a 500, and a server-side session could be renewed in the Default space's storage.
Full Changelog: spaces-1.0.0-preview.3...spaces-1.0.0-preview.6