Activities of "dan@dancaron.com"

  • ABP Framework version: v7.3.0-rc.1
  • UI type: MVC
  • DB provider: EF Core / Azure SQL Database
  • Tiered (MVC) or Identity Server Separated (Angular): yes
  • Exception message and stack trace:
  • 2023-07-08 21:40:47.915 +00:00 [INF] Request starting HTTP/1.1 GET http://auth-staging.mysite.com/.well-known/openid-configuration - - 2023-07-08 21:40:47.916 +00:00 [DBG] The event OpenIddict.Validation.OpenIddictValidationEvents+ProcessRequestContext was successfully processed by OpenIddict.Validation.AspNetCore.OpenIddictValidationAspNetCoreHandlers+ResolveRequestUri. 2023-07-08 21:40:47.916 +00:00 [DBG] The event OpenIddict.Server.OpenIddictServerEvents+ProcessRequestContext was successfully processed by OpenIddict.Server.AspNetCore.OpenIddictServerAspNetCoreHandlers+ResolveRequestUri. 2023-07-08 21:40:47.916 +00:00 [INF] The request URI matched a server endpoint: "Configuration". 2023-07-08 21:40:47.916 +00:00 [DBG] The event OpenIddict.Server.OpenIddictServerEvents+ProcessRequestContext was successfully processed by OpenIddict.Server.OpenIddictServerHandlers+InferEndpointType. 2023-07-08 21:40:47.916 +00:00 [DBG] The event OpenIddict.Server.OpenIddictServerEvents+ProcessRequestContext was successfully processed by Volo.Abp.Account.Web.Pages.Account.OpenIddictImpersonateInferEndpointType. 2023-07-08 21:40:47.916 +00:00 [DBG] The event OpenIddict.Server.OpenIddictServerEvents+ProcessRequestContext was successfully processed by OpenIddict.Server.AspNetCore.OpenIddictServerAspNetCoreHandlers+ValidateTransportSecurityRequirement. 2023-07-08 21:40:47.916 +00:00 [DBG] The event OpenIddict.Server.OpenIddictServerEvents+ProcessRequestContext was marked as rejected by OpenIddict.Server.AspNetCore.OpenIddictServerAspNetCoreHandlers+ValidateTransportSecurityRequirement. 2023-07-08 21:40:47.916 +00:00 [DBG] The event OpenIddict.Server.OpenIddictServerEvents+ProcessErrorContext was successfully processed by OpenIddict.Server.OpenIddictServerHandlers+AttachErrorParameters. 2023-07-08 21:40:47.916 +00:00 [DBG] The event OpenIddict.Server.OpenIddictServerEvents+ProcessErrorContext was successfully processed by OpenIddict.Server.OpenIddictServerHandlers+AttachCustomErrorParameters. 2023-07-08 21:40:47.916 +00:00 [DBG] The event OpenIddict.Server.OpenIddictServerEvents+ApplyConfigurationResponseContext was successfully processed by OpenIddict.Server.AspNetCore.OpenIddictServerAspNetCoreHandlers+AttachHttpResponseCode1[[OpenIddict.Server.OpenIddictServerEvents+ApplyConfigurationResponseContext, OpenIddict.Server, Version=4.4.0.0, Culture=neutral, PublicKeyToken=35a561290d20de2f]]. 2023-07-08 21:40:47.916 +00:00 [DBG] The event OpenIddict.Server.OpenIddictServerEvents+ApplyConfigurationResponseContext was successfully processed by OpenIddict.Server.AspNetCore.OpenIddictServerAspNetCoreHandlers+AttachWwwAuthenticateHeader1[[OpenIddict.Server.OpenIddictServerEvents+ApplyConfigurationResponseContext, OpenIddict.Server, Version=4.4.0.0, Culture=neutral, PublicKeyToken=35a561290d20de2f]]. 2023-07-08 21:40:47.916 +00:00 [INF] The response was successfully returned as a JSON document: { "error": "invalid_request", "error_description": "This server only accepts HTTPS requests.", "error_uri": "https://documentation.openiddict.com/errors/ID2083" }.
  • Steps to reproduce the issue:
  • Site is deployed in Azure with Application Gateway handling HTTPS on front end (SSL offloading) and HTTP on back end.
  • 3 Tiers - Auth, API, and Web - all running in Azure App Service Plan - as separate web apps
  • AuthServer:RequireHttpsMetadata is set to false
  • The SSL offloading is working on all 3 tiers, except it fails with above exception when I try to login

Can you point me to a design pattern that would enable file upload as part of an entity created by the CRUD generator?

Dan

I am using the abp.io Select2 auto-complete-select. How do I refresh the "available options" data from the Select2 box without clearing out any selected options?

I have a use case where the list of available options changes **after ** the user has clicked the drop-down to retrieve the list of available options (i.e. they can create a new item while on the screen - so I need to refresh the data (available options) so the new item is there - but I need to retain any selected items).

<select id="TagsLookup" asp-for="Message.TagIds" class="auto-complete-select" multiple="multiple" style="width: 100%" data-autocomplete-api-url="/api/mymodule/messages/item-lookup" data-autocomplete-display-property="displayName" data-autocomplete-value-property="id" data-autocomplete-items-property="items" data-autocomplete-filter-param-name="filter"> </select>

Ok that got me close. I'm very close to solving this. The example you provided is more for a worker process than for an isolated azure function v4 in .net 7, but it's useful and I'm almost there. I am now able to initialize the ABP app. But I get an error when I call...

_abpApplication.ServiceProvider.GetRequiredService<myAppService>();

I'm getting the following error:

Autofac.Core.Registration.ComponentNotRegisteredException: 'The requested service 'Volo.Abp.Castle.DynamicProxy.AbpAsyncDeterminationInterceptor`1[[Volo.Abp.Uow.UnitOfWorkInterceptor, Volo.Abp.Uow, Version=7.1.0.0, Culture=neutral, PublicKeyToken=null]]' has not been registered. To avoid this exception, either register a component to provide the service, check for service registration using IsRegistered(), or use the ResolveOptional() method to resolve an optional dependency.'

The example in ConsoleTestApp creates an instance of ClientDemoService and then executes RunAsync() method. I could get that working OK within the Azure Function.

However, the problem is that in an Azure Function program.cs, you're not creating an instance of a class and executing a method in the way that it's done in the ConsoleTestApp. Instead, you're working with HostBuilder and calling Host.Run(). The methods that get called and the instantiation of the class is not done explicitly in program.cs, rather it's instantiated by the worker process (it's invoked automatically when an item is found in the Azure storage queue). So it's a very different pattern than ConsoleTestApp.

The problem, I think, has to do with dependency injection. If I don't inject the HttpApi Client App Service class, then it can't resolve it (so that is the error that I see). I can clear up that error by injecting that class in program.cs, but the moment I try to inject that class, then the worker process never instantiates my "queue processor" class - meaning it just silently fails - nothing logged. My best guess is possibly that I need to inject dependencies of the ABP HttpApi Client app service class. But I am hoping you can point me to a working example - or even to someone who's done this before.

Thanks,

Dan

From an Azure Function, I want to leverage the static client proxies that I've already generated. The function will pull data from an Azure Storage Queue and commit it to the Azure SQL database through ABP EF. I have tried to leverage the code examples in the ConsoleTestApp but the code in that example doesn't work in Azure Functions. I'm using Azure Functions 4 in .NET 7.

Can you point me to any examples that demonstrate a working method?

Dan

Ahhhh I imagine that is the problem. Ok, I am new to ABP and I had assumed that the ABP Suite modules screen would only present options that are valid for my solution. I had not thought through IdentityServer vs. OpenIddict as I have not used either of them before. Thank you.

I have installed templates several times and each time I choose to install the Identity Server UI module, it fails to install properly. The ABP Suite UI reports a successful installation, however the console reports an error and the resulting code in the solution does not compile.

  • ABP Framework version: v7.0.1
  • UI type: MVC
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Separated (Angular): yes
  • Exception message and stack trace: Build started... Build failed. Use dotnet build to see the errors. Build started... Build failed. Use dotnet build to see the errors. C:\Users\Dan\source\repos\MyApp\aspnet-core\src\MyApp.EntityFrameworkCore\EntityFrameworkCore\MyAppDb ContextBase.cs(15,16): error CS0234: The type or namespace name 'IdentityServer' does not exist in the namespace 'Volo. Abp' (are you missing an assembly reference?) [C:\Users\Dan\source\repos\MyApp\aspnet-core\src\MyApp.Entity FrameworkCore\MyApp.EntityFrameworkCore.csproj] The build failed. Fix the build errors and run again.
  • Steps to reproduce the issue:" Install base template defined above and then install Identity Server UI module, look at the console for ABP Suite.
Showing 1 to 8 of 8 entries
Made with ❤️ on ABP v8.2.0-preview Updated on March 25, 2024, 15:11