Activities of "ageiter"

Great, it works :-D

Thank you so much for the quick help! I wish I'd asked much sooner ;-)

Hi, thanks for this detailed answer. This is exactly the kind of solution I was looking for. I’ll be happy to test it out, and I think this is what I need.

_installer.InstallAsync() is relatively complex (recursive traversal and inserts across multiple repositories), so I can’t share it here. But if your approach doesn’t work, I’ll send you the code via email.

By the way: after 1000 inserts, I call await _unitOfWorkManager.Current!.SaveChangesAsync(). I also clear the DbContext’s ChangeTracker. The data is also fully present in the database. That’s why I suspect the problem might be in postprocessing (event pipeline).

  • Template: app
  • Template Type: Classic
  • Created ABP Studio Version: 2.2.1
  • Current ABP Studio Version: 3.0.6
  • Tiered: No
  • Multi-Tenancy: Yes
  • UI Framework: angular
  • Theme: leptonx
  • Theme Style: system
  • Theme Menu Placement: side
  • Progressive Web App: No
  • Run Progressive Web App Support: No
  • Database Provider: ef
  • Database Management System: sqlserver
  • Separate Tenant Schema: Yes
  • Mobile Framework: none
  • Public Website: No
  • Social Login: Yes
  • Include Tests: Yes
  • Kubernetes Configuration: Yes
  • Distributed Event Bus: none
  • Use Local References: No
  • Optional Modules:
    • GDPR
    • FileManagement
    • TextTemplateManagement
    • LanguageManagement
    • AuditLogging
    • OpenIddictAdmin
  • Selected Languages: German (Switzerland), English, French, German (Germany), Italian
  • Default Language: German (Switzerland)
  • Create Command: abp new Bpo -t app --ui-framework angular --database-provider ef --database-management-system sqlserver --theme leptonx --separate-tenant-schema --skip-migration --skip-migrator --without-cms-kit --dont-run-install-libs --dont-run-bundling -file-management

In our application, we have a service that writes a very large amount of data to the database. This generates more than 1 million inserts into the database.

I’ve now optimized this service so that it completes in about 100 seconds. I disabled transactions for the UnitOfWork to avoid additional overhead (isTransactional: false). The data is now stored in the database after just under 2 minutes.

Problem: Completing the UoW (uow.CompleteAsync()) takes about 17 hours !!!

Since I don’t see any log messages, I have no idea what’s taking so long. My guess is that events are being generated (which are completely unnecessary in my case). The affected entities are not auditable. I also added a [DisableAuditing] attribute to the AppService methods.

I’ve now moved the service call to a background job so that it doesn’t block anything. But it’s still very unsatisfying this way.

What can be done to optimize this?

protected override async Task ExecuteWithContextAsync(InstallationJobArgs args)
    {
        await _jobStatusStore.SetRunningAsync(args.JobId);

        try
        {
            var data = await LoadDataAsync(args);

            using var uow = _unitOfWorkManager.Begin(requiresNew: true, isTransactional: false);
            
            await _installer.InstallAsync(data); // Takes 100 seconds
            
            await uow.CompleteAsync(); // Takes 17 hours

            await _jobStatusStore.SetSucceededAsync(args.JobId);
        }
        catch (Exception ex)
        {
            await _jobStatusStore.SetFailedAsync(args.JobId, ex.Message);
            throw;
        }
    }

We have a very large project with many entities. If we define a separate namespace for each entity, then working in Visual Studio becomes very cumbersome due to the large number of folders (since classes are stored in a folder for each namespace).

That’s why we’ve grouped related entities into the same namespace. However, this results in a large number of classes in the same folder for Domain and Contracts, which makes things chaotic again. We therefore manually move the classes into subfolders.

It would be great if the Suite allowed you to define the folder where the entity is generated.

That way, we could organize the classes hierarchically.

We have some entities without string properties. If you want to create a NavigationProperty for such an entity, unfortunately this isn’t straightforward, since you have to select a property as a “display property,” which must be a string.

Our workaround was to specify ConcurrencyStamp as the display property. But that can’t be a solution. If we could at least use the ID (GUID), that would be fine... but then we get compile errors.

Since we don’t generate the UI, we don’t need the part with the lookup methods (that’s where the compile errors occur) or UI Pick Type at all.

Could you please adjust this so that we can do without the display property or reference something other than a string?

Okay, I have now recreated the scenario and attempted to reproduce the issue. However, it has now worked as intended and no entries were deleted from the database. I suspect that during my initial test, I made the change directly in the database and the cache had not yet been synchronized before I made the next change in the application.

Thanks for your help.

Unfortunately, we are unable to update at this time. Therefore, I would appreciate a response regarding how the framework behaves (in version 8.3.4). You may also simply confirm whether my following statements are correct or not.

  • If the tenant has not assigned an edition and feature settings have been made on the tenant, these will persist when an edition is assigned (but the tenant will not receive the feature settings of the edition).
  • When changing an edition on the tenant, all feature settings previously made on the tenant will be deleted.

However, my last two questions have nothing to do with the cache.

What can you say about that?

I have also identified a second problem. When I change the features of the assigned edition, the individual value of the tenant is deleted from the database and the value of the edition is applied.
It is very dangerous that settings are lost... is this the desired behavior?

Ok, thank you.

I now have the following problem:

  1. Tenant does not yet have a subscription; I have set the maximum number of users there (as discussed above).
  2. Customer has purchased a subscription, and the corresponding edition has been set.
  3. Features of this edition were not activated.

Are no feature values of the edition applied as soon as a value is “overwritten” on the tenant? I assumed that only this value (Identity.MaxUserCount) differs from the values of the edition?

Showing 31 to 40 of 347 entries
Boost Your Development
ABP Live Training
Packages
See Trainings
Mastering ABP Framework Book
The Official Guide
Mastering
ABP Framework
Learn More
Mastering ABP Framework Book
Made with ❤️ on ABP v10.8.0-preview. Updated on November 16, 2026, 06:26
1
ABP Assistant
🔐 You need to be logged in to use the chatbot. Please log in first.