-
Notifications
You must be signed in to change notification settings - Fork 20
Closed
Labels
questionFurther information is requestedFurther information is requested
Description
Hi,
I'm having a few issues resizing images from the CDN within Umbraco v9.3.1.
I have followed the steps to upload and manage my site media in Azure Blob storage. The middleware calls have been registered as outlined.
services.AddImageSharp(options =>
{
options.MemoryStreamManager = new RecyclableMemoryStreamManager();
options.BrowserMaxAge = TimeSpan.FromDays(7);
options.CacheMaxAge = TimeSpan.FromDays(365);
options.OnParseCommandsAsync = _ => Task.CompletedTask;
options.OnBeforeSaveAsync = _ => Task.CompletedTask;
options.OnProcessedAsync = _ => Task.CompletedTask;
options.OnPrepareResponseAsync = _ => Task.CompletedTask;
})
.ClearProviders()
.AddProvider<AzureBlobStorageImageProvider>()
.AddProvider<PhysicalFileSystemProvider>()
.SetRequestParser<QueryCollectionRequestParser>()
.Configure<AzureBlobStorageCacheOptions>(options =>
{
options.ConnectionString = "Blah";
options.ContainerName = "Cache-Dev";
// Optionally create the cache container on startup if not already created.
AzureBlobStorageCache.CreateIfNotExists(options, PublicAccessType.Blob);
})
.SetCache<AzureBlobStorageCache>()
.ClearProcessors()
.AddProcessor<ResizeWebProcessor>()
.AddProcessor<FormatWebProcessor>()
.AddProcessor<BackgroundColorWebProcessor>();
services.AddUmbraco(_env, Configuration)
.AddBackOffice()
.AddWebsite()
.AddComposers()
// Add the Azure Blob Storage file system, ImageSharp image provider/cache and middleware for Media:
.AddAzureBlobMediaFileSystem()
// Optionally add the CDN media URL provider:
.AddCdnMediaUrlProvider()
.Build();
app.UseDefaultFiles();
app.UseImageSharp();
app.UseStaticFiles();
app.UseUmbraco()
.WithMiddleware(u =>
{
u.UseBackOffice();
u.UseWebsite();
//// Enables the Azure Blob Storage middleware for Media:
u.UseAzureBlobMediaFileSystem();
})
.WithEndpoints(u =>
{
u.UseInstallerEndpoints();
u.UseBackOfficeEndpoints();
u.UseWebsiteEndpoints();
});
The media is uploaded and available in Azure. The CDN is also storing and fetching the images.
Static images such as logos etc that are stored in wwwroot resize fine when called in the UI. Images being requested from the CDN are being return as the originally uploaded size with the data in the query parameters not being applied.
The CDN has 'Cache every unique url' set.
if anyone can provide any guidance that would be great.
Metadata
Metadata
Assignees
Labels
questionFurther information is requestedFurther information is requested