Starts in:
2 DAYS
14 HRS
56 MIN
49 SEC
Starts in:
2 D
14 H
56 M
49 S

Activities of "MichelZ"

Answer

We get the same issue. Additionally we see a few of these errors:

#37 145.3 /usr/share/dotnet/sdk/6.0.101/Microsoft.Common.CurrentVersion.targets(2304,5): warning MSB3106: Assembly strong name "/root/.nuget/packages/volo.abp.commercial.core/5.1.2/lib/netstandard2.0/Volo.Abp.Commercial.Core.dll" is either a path which could not be found or it is a full assembly name which is badly formed. If it is a full assembly name it may contain characters that need to be escaped with backslash(\). Those characters are Equals(=), Comma(,), Quote("), Apostrophe('), Backslash(\). [/src/src/company.product.Domain.Shared/company.product.Domain.Shared.csproj]

We also might start tweeting them...

https://twitter.com/abpcommercial https://twitter.com/volosoftcompany https://twitter.com/hibrahimkalkan

It's urgent.

Same here

Question

Hi

Using abp 4.4 with EF/SQL Server.

We don't like using "Id" as the column name for our entities, so we are using this workaround: https://github.com/aspnetboilerplate/aspnetboilerplate/issues/586#issuecomment-135599562

It does work fine for entities that don't have a Guid Key. Once the Key is Guid, things start to break down. EF throws errors that the "Id column was not found".

We have found the cause of it, it's AbpDbContext.TrySetGuidId and AbpDbContext.ConfigureValueGenerated

We have also found a suitable workaround by overriding these functions like this:

protected override void TrySetGuidId(EntityEntry entry, IEntity<Guid> entity)
        {
            if (entry.Metadata.FindProperty("Id") == null)
            {
                // Ignore this, it's because we have removed the Id property.
                return;
            }

            base.TrySetGuidId(entry, entity);
        }

        protected override void ConfigureValueGenerated<TEntity>(ModelBuilder modelBuilder, IMutableEntityType mutableEntityType)
            where TEntity : class
        {
            if (!typeof(IEntity<Guid>).IsAssignableFrom(typeof(TEntity)))
            {
                return;
            }

            // Ignore if Id has NotMapped attribute
            var type = mutableEntityType.ClrType;
            var propertyInfo = type.GetProperty("Id", BindingFlags.DeclaredOnly |
                                                      BindingFlags.Public |
                                                      BindingFlags.Instance);

            if (propertyInfo != null)
            {
                var attribute = propertyInfo.GetCustomAttribute(typeof(NotMappedAttribute));
                if (attribute != null)
                {
                    return;
                }
            }

            base.ConfigureValueGenerated<TEntity>(modelBuilder, mutableEntityType);
        }

The configureValueGenerated function does create the property when it does not exist. So even when it was excluded with [NotMapped], this line from AbpDbContext adds it: var idPropertyBuilder = modelBuilder.Entity().Property(x => ((IEntity)x).Id);

(Note the documentation saying that "Returns an object that ban be used to configure a property of the entity type. If the specified property is not already part of the model, it will be added.")

So the Id property is added to the model if the type is Guid.

Then the TrySetGuidId also expects the Id property to be there: var idProperty = entry.Property("Id").Metadata.PropertyInfo;

Which of course fails, too.

Now to the question:

  • Is this the right way to handle this situation, or do you see a better way?
  • Are there some improvements for ABP that you can do to better support this scenario?

Thanks Michel

Hi @ismcagdas

I have mostly switched away from a docker-based local workflow that needs frequent downloading of packages, so I can't really say for sure. Might try again in the future, but good to know that improvements were made, thank you!

Thanks

And I have this issue again with 409. I haven't heard back from my e-mail about IP Addresses....

#28 2.185 Determining projects to restore... #28 15.20 Failed to download package 'Volo.Abp.TextTemplateManagement.Domain.Shared.4.4.2' from 'https://nuget.abp.io/<key>/v3/package/volo.abp.texttemplatemanagement.domain.shared/4.4.2/volo.abp.texttemplatemanagement.domain.shared.4.4.2.nupkg'. #28 15.20 Response status code does not indicate success: 409 (Conflict). #28 33.23 Failed to download package 'Volo.Abp.Account.Pro.Shared.Application.4.4.2' from 'https://nuget.abp.io/<key>/v3/package/volo.abp.account.pro.shared.application/4.4.2/volo.abp.account.pro.shared.application.4.4.2.nupkg'. #28 33.23 Response status code does not indicate success: 409 (Conflict).

Hi @MichelZ

I'm not %100 sure but your requests might be blocked by our firewall. Is it possible to share your IP with us so we can check this ? You can share it with info@abp.io.

Also, using a nuget cache for your docker builds might help to solve this problem and speed up your development, see https://stackoverflow.com/questions/60799918/using-nuget-cache-inside-a-docker-build-with-net-core-when-offline.

Thanks, I have sent an e-mail. The BuildKit thing is a good idea and I will look into this, thank you!

Hi

No, it is not. This is for pushing packages - where a 409-Conflict makes absolutely sense. Here, we are not pushing any packages, it's just a package restore.

  • ABP Framework version: v4.4.2
  • UI type: Angular
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Separated (Angular): yes

We are using docker to develop a solution using abp. This means docker will often need to download ABP packages. We often get the following error with multiple packages, sometimes for hours, and then the error suddenly disappears. We don't know what to do currently and would like to ask for help.

#132 43.50 /usr/share/dotnet/sdk/5.0.400/NuGet.targets(131,5): error : Failed to download package 'Volo.Abp.Account.Pro.Shared.Application.4.4.2' from 'https://nuget.abp.io/redacted/v3/package/volo.abp.account.pro.shared.application/4.4.2/volo.abp.account.pro.shared.application.4.4.2.nupkg'. [/src/src/company.product.AgentHttpApi.Host/company.product.AgentHttpApi.Host.csproj] #132 43.50 /usr/share/dotnet/sdk/5.0.400/NuGet.targets(131,5): error : Response status code does not indicate success: 409 (Conflict). [/src/src/company.product.AgentHttpApi.Host/company.product.AgentHttpApi.Host.csproj]

The step that provokes this is: RUN dotnet restore "src/company.product.AgentHttpApi.Host/company.product.AgentHttpApi.Host.csproj" --configfile "nuget.config"

Any idea what could cause this?

Thanks Michel

Any chance that this could be improved? We use a one-db-per-tenant approach as well, and having TenantID columns is just distracting :)

Showing 31 to 40 of 55 entries
Made with ❤️ on ABP v9.1.0-preview. Updated on November 20, 2024, 13:06