I tried to get Litium 8 up and running on my PC and I have been able to get everything running up until the accelerator deployment where I get the “An error occurred during installation”. The only other details I get are to check the logs.
Checking the logs reveals the following error:
2021-08-18 15:42:44.3487 [App:01] [] [ERROR] [] Litium.Accelerator.Administration.Extensions.Controllers.DeploymentController - Error when deploying accelerator. End of Central Directory record could not be found. System.IO.InvalidDataException: End of Central Directory record could not be found.
at System.IO.Compression.ZipArchive.ReadEndOfCentralDirectory()
at System.IO.Compression.ZipArchive…ctor(Stream stream, ZipArchiveMode mode, Boolean leaveOpen, Encoding entryNameEncoding)
at System.IO.Compression.ZipArchive…ctor(Stream stream, ZipArchiveMode mode, Boolean leaveOpen)
at Litium.Web.Administration.Runtime.ZipFileProvider…ctor(Stream zipStream, String subPath)
at Litium.Accelerator.Administration.Extensions.Deployments.AcceleratorPackage.MapBlobs(Stream containerStream)
at Litium.Accelerator.Administration.Extensions.Deployments.AcceleratorPackage.GetStructureInfoAsync()
at Litium.Accelerator.Administration.Extensions.Controllers.DeploymentController.ImportPackage(ImportViewModel importForm)
Does your machine has internet connection when executing the deployment? Please check the firewall configuration to make sure it allows Accelerator to download files from the outside network.
Seems that the issue has something to do with downloading the Accelerator_B2C.storage.bin. I’ve removed the Litium_accelerator_deployments folder, tried re-deploying, and the storage file is larger this time (13040kb), but I still get an error:
Downloaded and had to do the same for Accelerator_B2C.blockData.storage.bin and Accelerator_B2C.pageData.storage.bin (even though these files are small in comparison)
Now the deployment fails with the following error in the logs:
2021-08-19 10:36:14.4262 [App:01] [] [ERROR] [] Litium.Accelerator.Administration.Extensions.Controllers.DeploymentController - Error when deploying accelerator. Validation error for Assortment(SystemId: d5a31287-06c3-4e41-828f-291fbaba9dcc, Id: 3A15B40C-D0BF-4CD4-9737-6B6C7D2546EFdemo), Id: 'Värdet är inte unikt.'. Litium.Validations.ValidationException: Validation error for Assortment(SystemId: d5a31287-06c3-4e41-828f-291fbaba9dcc, Id: 3A15B40C-D0BF-4CD4-9737-6B6C7D2546EFdemo), Id: 'Värdet är inte unikt.'.
at Litium.Validations.ValidationServiceExtensions.ThrowExceptionIfError[T](ValidationService service, T entity, ValidationMode validationMode)
at Litium.Application.Data.Batching.BatchDataImpl.Execute[T](T entity, ValidationMode validationMode)
at Litium.Application.Data.Batching.BatchDataImpl.WrapAndExecute[T](T entity, ValidationMode validationMode)
at Litium.Application.Data.Batching.BatchDataImpl.Create[T](T entity)
at Litium.Application.Products.AssortmentServiceImpl.Create(Assortment assortment)
at Litium.Accelerator.Administration.Extensions.Deployments.AcceleratorPackage.CreateAssortment(StructureInfo structureInfo, String name, String domainName)
at Litium.Accelerator.Administration.Extensions.Deployments.AcceleratorPackage.CreatePackageInfo(StructureInfo structureInfo, String name, String domainName)
at Litium.Accelerator.Administration.Extensions.Controllers.DeploymentController.ImportPackage(ImportViewModel importForm)
So then I restored the database thinking that “currupted” data might have resulted from previous failures. Then I tried again to create “demo” with domain “localhost:5001”, but that still failed.
Then I tried to create “demo2” with domain “localhost:5002” and I get a validation error saying that the domain already exists.
Then there is an error when I try checking out the domains.
All the while no errors are logged.
Also something unexpected is that it seems that the application is “starting” on every click. I see the following appear in the logs each time I click something in backoffice:
Are you using Redis in your current installation? Did you in that case also flush the cache to not contain the data from the previous database that you replaced?
No Redis, I figured I could set that up at a later stage.
The only thing I’ve done outside of the current L8 install instructions was putting the connection string in a appsettings.Development.json file along with a shared folder.
So, this morning I tried again, but this time I ran the application with debugging. The application this time does not reload on each click and the deployment appears to have worked!
Running without debugging and the application restarts on each click. I am assuming this is not the correct behavior?
This is not the case. There is not other application running that would modify the contents of the bin folder while running the application.
This actually only appears to be an issue when running and deploying the accelerator the first time. If I run the application with the debugger attached then the application does not restart and I can deploy the accelerator without error. After that, I can run the application without debugging and it runs fine.