jeflux的活动

  • ABP Framework version: 7.0.1
  • UI Type: Angular
  • Database System: EF Core (SQL Server)
  • Tiered (for MVC) or Auth Server Separated (for Angular): Microservice
  • Exception message and full stack trace:
  • Steps to reproduce the issue:

I'm trying to get one of our microservices running in a Docker container and I am not able to handle the licensing part. We have a AbpLicenseCode value, but when I put it in the appsettings file I get:

ABP-LIC-0013 - License exception: ABP-LIC-0023: An error occured while calling the license server! The input is not a valid Base-64 string as it contains a non-base 64 character, more than two padding characters, or an illegal character among the padding characters.

I'm not sure this code ever worked as we've always used the abp login during development.

Multiple people have reference copying the access-token.bin file to the Docker container. We're using linux container, and I've tried copying to the /root/.abp/cli/ folder as described here: https://gist.github.com/ebicoglu/f7cd77069fa053cbe9cf9e9ffcc2f2d2. I can inspect the container and confirm that the file is indeed in the right place, but I only receive: **Error: ABP-LIC-002 -License code not found! Ensure that your appsettings.json or appsettings.secrets.json has "AbpLicenseCode" key with your license code.**

We started out over 2 years ago on a Tiered solution. But we've made many changes including moving to microservice template. I've seen comments about regenerating the project to generate the license code, but I can't get this to work. I just get the same error as above when trying to use a license code from a newly-generated project (ABP-LIC-0013).

Currently, the Dockerfile is the most basic version. We've only added the access token copying so far (Note, this sample is from a demo project, but it's identical to our current file other than the project name/path). Note the fourth line about copying the access token. Again, the token is confirmed to be in that folder in the Docker container.

FROM mcr.microsoft.com/dotnet/aspnet:7.0 AS base
WORKDIR /app
EXPOSE 80
COPY ["access-token.bin", "/root/.abp/cli/"]

FROM mcr.microsoft.com/dotnet/sdk:7.0 AS build
WORKDIR /src
COPY ["CarvedRock.Api/CarvedRock.Api.csproj", "CarvedRock.Api/"]
RUN dotnet restore "CarvedRock.Api/CarvedRock.Api.csproj"
COPY . .
WORKDIR "/src/CarvedRock.Api"
RUN dotnet build "CarvedRock.Api.csproj" -c Release -o /app/build

FROM build AS publish
RUN dotnet publish "CarvedRock.Api.csproj" -c Release -o /app/publish

FROM base AS final
WORKDIR /app
COPY --from=publish /app/publish .
ENTRYPOINT ["dotnet", "CarvedRock.Api.dll"]
  • ABP Framework version: v7.0.1
  • UI type: Angular
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Separated (Angular): yes
  • Exception message and stack trace:
  at Volo.Abp.Http.Client.ClientProxying.ClientProxyBase`1.ThrowExceptionForResponseAsync(HttpResponseMessage response)
   at Volo.Abp.Http.Client.ClientProxying.ClientProxyBase`1.RequestAsync(ClientProxyRequestContext requestContext)
   at Volo.Abp.Http.Client.ClientProxying.ClientProxyBase`1.RequestAsync[T](ClientProxyRequestContext requestContext)
   at Volo.Abp.Http.Client.ClientProxying.ClientProxyBase`1.RequestAsync[T](String methodName, ClientProxyRequestTypeValue arguments)
   at Volo.Abp.Identity.ClientProxies.IdentityUserClientProxy.CreateAsync(IdentityUserCreateDto input)
   at Tryl.InvitationService.Invitations.InvitationsAppService.CreateWithUserAsync(InvitationCreateDto input) in /src/src/InvitationService.Application/Invitations/InvitationsAppServiceExt.cs:line 89
   at Castle.DynamicProxy.AsyncInterceptorBase.ProceedAsynchronous[TResult](IInvocation invocation, IInvocationProceedInfo proceedInfo)
   at Volo.Abp.Castle.DynamicProxy.CastleAbpMethodInvocationAdapterWithReturnValue`1.ProceedAsync()
   at Volo.Abp.GlobalFeatures.GlobalFeatureInterceptor.InterceptAsync(IAbpMethodInvocation invocation)
   at Volo.Abp.Castle.DynamicProxy.CastleAsyncAbpInterceptorAdapter`1.InterceptAsync[TResult](IInvocation invocation, IInvocationProceedInfo proceedInfo, Func`3 proceed)
   at Castle.DynamicProxy.AsyncInterceptorBase.ProceedAsynchronous[TResult](IInvocation invocation, IInvocationProceedInfo proceedInfo)
   at Volo.Abp.Castle.DynamicProxy.CastleAbpMethodInvocationAdapterWithReturnValue`1.ProceedAsync()
   at Volo.Abp.Authorization.AuthorizationInterceptor.InterceptAsync(IAbpMethodInvocation invocation)
   at Volo.Abp.Castle.DynamicProxy.CastleAsyncAbpInterceptorAdapter`1.InterceptAsync[TResult](IInvocation invocation, IInvocationProceedInfo proceedInfo, Func`3 proceed)
   at Castle.DynamicProxy.AsyncInterceptorBase.ProceedAsynchronous[TResult](IInvocation invocation, IInvocationProceedInfo proceedInfo)
   at Volo.Abp.Castle.DynamicProxy.CastleAbpMethodInvocationAdapterWithReturnValue`1.ProceedAsync()
   at Volo.Abp.Validation.ValidationInterceptor.InterceptAsync(IAbpMethodInvocation invocation)
   at Volo.Abp.Castle.DynamicProxy.CastleAsyncAbpInterceptorAdapter`1.InterceptAsync[TResult](IInvocation invocation, IInvocationProceedInfo proceedInfo, Func`3 proceed)
   at Castle.DynamicProxy.AsyncInterceptorBase.ProceedAsynchronous[TResult](IInvocation invocation, IInvocationProceedInfo proceedInfo)
   at Volo.Abp.Castle.DynamicProxy.CastleAbpMethodInvocationAdapterWithReturnValue`1.ProceedAsync()
   at Volo.Abp.Auditing.AuditingInterceptor.ProceedByLoggingAsync(IAbpMethodInvocation invocation, AbpAuditingOptions options, IAuditingHelper auditingHelper, IAuditLogScope auditLogScope)
   at Volo.Abp.Auditing.AuditingInterceptor.InterceptAsync(IAbpMethodInvocation invocation)
   at Volo.Abp.Castle.DynamicProxy.CastleAsyncAbpInterceptorAdapter`1.InterceptAsync[TResult](IInvocation invocation, IInvocationProceedInfo proceedInfo, Func`3 proceed)
   at Castle.DynamicProxy.AsyncInterceptorBase.ProceedAsynchronous[TResult](IInvocation invocation, IInvocationProceedInfo proceedInfo)
   at Volo.Abp.Castle.DynamicProxy.CastleAbpMethodInvocationAdapterWithReturnValue`1.ProceedAsync()
   at Volo.Abp.Uow.UnitOfWorkInterceptor.InterceptAsync(IAbpMethodInvocation invocation)
   at Volo.Abp.Castle.DynamicProxy.CastleAsyncAbpInterceptorAdapter`1.InterceptAsync[TResult](IInvocation invocation, IInvocationProceedInfo proceedInfo, Func`3 proceed)
   at lambda_method2604(Closure, Object)
   at Microsoft.AspNetCore.Mvc.Infrastructure.ActionMethodExecutor.AwaitableObjectResultExecutor.Execute(ActionContext actionContext, IActionResultTypeMapper mapper, ObjectMethodExecutor executor, Object controller, Object[] arguments)
   at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<InvokeActionMethodAsync>g__Awaited|12_0(ControllerActionInvoker invoker, ValueTask`1 actionResultValueTask)
   at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<InvokeNextActionFilterAsync>g__Awaited|10_0(ControllerActionInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)
   at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.Rethrow(ActionExecutedContextSealed context)
   at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.Next(State& next, Scope& scope, Object& state, Boolean& isCompleted)
   at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<InvokeInnerFilterAsync>g__Awaited|13_0(ControllerActionInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)
   at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeNextExceptionFilterAsync>g__Awaited|26_0(ResourceInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)

Steps to reproduce the issue: We cannot reliably re-produce the issue as it is intermittent. But what we are currently seeing:

There are three services currently involved: Service A, B, and C

During one process, Service A will call Service B to create a user (not the Identity Service). If required, Service B will then call Service C (which is the Identity Service) to create the user record.

We frequently get Service A return a 404 with this response:

---------- RemoteServiceErrorInfo ----------
{
  "code": "NotFound",
  "message": "Not Found",
  "details": null,
  "data": null,
  "validationErrors": null
}

However, in some instances, Service A successfully reaches Service B, but Service B has the same type of 404 error reaching Service C.

It is never predictable. Sometimes I'll get 20 successful Service A requests in a row, then several fail. Sometimes they seem to almost alternate between pass/fail. It took us a while to realize that sometimes it was the call between B & C failing and not A & B.

Our assumption is that we have an incorrect configuration either in our ABP application or maybe in our hosting environment. What we're looking for are recommendations on how we could identify what the heck is happening. (In the above stacktrace, this is logging from Service B failing to reach Service C).

The "Not found" response, does that indicate it found the correct API and just not the correct resource? Or could it not reach the target service at all? Any suggestions are appreciated

  • ABP Framework version: v5.3.4
  • UI type: Angular

I have a Reactive form with required fields that looks like this:

The form is defined in the component as:

this.participantForm = this.fb.group({
      participantBirthDate: [null, [Validators.required]],
      participantFirstName: [ null, [Validators.required]],
      participantLastName: [null, [Validators.required]],
      participantEmail: [ null, [Validators.email, Validators.required]],
      });

And I'm trying to use a standard Bootstrap input box with a button as shown here: Boostrap Input Group Doc

Each of the form items looks like this:

<div class="input-with-icon">
  <label for="participantFirstName">First name</label>
  <div class="required-chip-badge">Required</div>
  <div class="input-group">
    <input
      type="text"
      class="form-control"
      placeholder="Enter first name"
      formControlName="participantFirstName"
      #pfn
    />
    <button
      class="btn btn-outline-secondary icon icon-pencil"
      (click)="pfn.focus()"
      type="button"
    ></button>
  </div>
</div>

When a validation error is present, this happens:

The<abp-validation-error> is being inserted immediately after the <input>, but I had to wrap the input and button in the div with the "input-group" class to create the button as part of the input element, so the validation error is inserted between:

If I use an input box without the input-group, the validation works as desired with the message being below the input element:

  • QUESTION Our design standards will use buttons on all input boxes, so I need to find a way to have have the validation error display below the input with button element. This is effectively inserting the validation error element after the input-group <div>.

Is this possible without a bunch of manual work?

I know I can build out more manual validation layouts in the template (as described here: Angular Reactive Forms Doc, but this would be a lot more work and we would have to do it wherever we have forms.

I've read through the ABP Form Validation Doc, but it does not cover this particular scenario.

When setting the route layout type to eLayoutType.Empty we can completely hide the toolbars so that view appears as more of a standalone application. However, I cannot get ride of the top margin unless I set the component ViewEncapsulation to None and apply a padding setting such as:

.abp-application-layout {
    padding-top: 0 !important;
}

Of course this is wrong, but I can't seem to get rid of the 68px top padding of the body element. As a result, when my component loads in the empty layout, I have a big white space at the top of the page.

  • ABP Framework version: v5.3.4
  • UI type: Angular
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Separated (Angular): yes
  • Exception message and stack trace: N/A
  • Steps to reproduce the issue:" -1. Add Health Controller -2. Hit Health Controller

We're running a microservices template. We have multiple health checks to ensure each service is reachable. Our Kubernetes environment, by default, was hitting the home path which would load the Swagger docs page. This resulted in loads of ELK logging. Our solution was to implemented a super lightweight Health controller that just returns a simple 200 response. While we have successfully reduced ELK logging, we noticed that ABP Audit logs are being created for each health check (many services getting health checks 2x per minute).

We've reviewed the Audit Logging documentation, but we cannot get the [DisableAuditing] attribute to work. Here is our lightweight Health Controller:

using Microsoft.AspNetCore.Mvc;
using Volo.Abp;
using Volo.Abp.AspNetCore.Mvc;
using Volo.Abp.Auditing;

namespace Acme.InvitationService.Controllers
{
    [RemoteService(Name = "DemoService")]
    [Area("demoService")]
    [ControllerName("Health")]
    [Route("api/demo-service/health")]
    [DisableAuditing]
    public class HealthController : AbpController
    {
        [DisableAuditing]
        [HttpGet]
        [ApiExplorerSettings(IgnoreApi = true)]
        public ActionResult Index()
        {
            return Ok("DemoService is reachable!");
        }
    }
}

You can see that we've put the attribute at the Controller and Action level (and have tried both separately). We have configured IsEnabledForGetRequests to true in the AbpAuditingOptions and would prefer to not turn this off as we're in a highly-regulated industry.

Any help identifying what we're doing wrong will be appreciated. Or, some guidance on how to debug what's going wrong. Thank you!

  • ABP Framework version: v5.3.4
  • UI type: Angular
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Separated (Angular): yes
  • Exception message and stack trace:
  • Steps to reproduce the issue:"
  • Start with a working 5.3.4 Module Template Solution
  • Generate Angular CRUD code, as needed
  • ABP Releases v6.0.0
  • Code Generation no longer works

We have multiple Modules for our microservices solution. Early this week, we were generating backend as UI code as we develop. Yesterday, we were unable to generate backend code. We found a slight workaround, which is in ticket here: https://support.abp.io/QA/Questions/3813/Version-Issues-Missing-Templates-with-ABP-Suite-after-upgrading-after-release-of-600

Today, I'm now trying to add CRUD UI elements in Angular. ABP Suite says "Completed" but no code is generated. See stacktrace in above image. My coworker was working on an entirely separate module and had the identical error today.

I tried a few things, including deleting the .suite, node_modules, and yarn.lock files/folders from the Angular app. I ran yarn commands. When I ran the Suite code gen task again, the .suite folder was re-added, but error was same.

I then noticed that package.json file in .suite/schematics folder had what appeared to be "old" values. They were:

{ "name": "@volo/abp.ng.suite", "version": "4.4.0-rc.2", "private": true, "description": "Schematics that works with ABP Suite", "keywords": [ "schematics" ], "schematics": "./collection.json", "dependencies": { "@abp/ng.schematics": "~4.4.0-rc.2", "@angular-devkit/core": "~11.0.2", "@angular-devkit/schematics": "~11.0.2", "jsonc-parser": "^2.3.0", "typescript": "~3.9.2" }, "devDependencies": { "@angular/cli": "~11.0.2", "@schematics/angular": "~11.0.2", "@types/node": "^12.11.1" }, "peerDependencies": { "@types/jest": "^26.0.0", "jest": "^26.0.0", "jest-preset-angular": "^8.2.0" } }

So I replaced them with the "correct" values which I copied from another 5.3.4 project we have that hasn't been touched since the v6.0.0 release. They are:

{ "name": "@volo/abp.ng.suite", "version": "5.3.4", "private": true, "description": "Schematics that works with ABP Suite", "keywords": [ "schematics" ], "schematics": "./collection.json", "dependencies": { "@abp/ng.schematics": "~5.3.4", "@angular-devkit/core": "~11.0.2", "@angular-devkit/schematics": "~11.0.2", "execa": "^6.1.0", "jsonc-parser": "^2.3.0", "path": "^0.12.7", "prettier": "^2.3.2", "typescript": "~3.9.2" }, "devDependencies": { "@angular/cli": "~11.0.2", "@schematics/angular": "~11.0.2", "@types/node": "^12.11.1" }, "peerDependencies": { "@types/jest": "^26.0.0", "jest": "^26.0.0", "jest-preset-angular": "^8.2.0" } }

I then delete the package-lock.json file and node_modules folder from the .suite/schematics folder and then ran an npm install.

Next I tried the code gen from Suite again. It failed, but with the error message:

An unhandled exception occurred: NOT SUPPORTED: keyword "id", use "$id" for schema ID

I've seen that before! So I manually added the $ symbol in .suite/schematics/commands/entity/schema.json.

I then ran the code gen again from Suite and it worked!

At this point it looks like I've managed to unblock myself, but something is definitely not right. I'll also need to walk my colleagues through this process so they can be unblocked on their work.

If you're creating a bug/problem report, please include followings:

  • ABP Framework version: v5.3.4
  • UI type: Angular
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Separated (Angular): yes
  • Exception message and stack trace:
  • Steps to reproduce the issue:"

There are several reported issues of "Cannot read the template..." errors. I've read them, especially this solution: https://support.abp.io/QA/Questions/671

Missing Templates after Upgrade Issue We upgraded our microservice solution from 5.1 to 5.3.4 weeks ago. My colleague then created a new project fusing the Microservice Template and integrated it into our solution.

The following week, I attempted to create a new entity within an existing microservice project (which had recently been upgraded) and received various "Cannot read the template..." errors. I followed every proposed solution I could find such as deleting/reinstalling CLI/Suite, cleaning solutions. I even checked every possible file to confirm it was the correct version.

Within ABP Suite if you click on Templates at the top, you can see them. I was missing templates that my coworker had. We both had same CLI/Suite versions working off same git repos. He pulled the project I was working on and could add an entity without any Template errors.

What finally worked was this: I created a new Microservice Template project, built it, and then added an entity to that project. (This was a throw-away project.) This process appeared to introduce the new/changed 5.3.4 templates into ABP Suite. After that, I could generate code using ABP Suite for my microservice project that had been upgraded from 5.1. to 5.3.4. I did not see this process documented in my research, and I assume this was a workaround for a defect.

My other colleague needed to do work on the existing project and she had the exact same issue. I walked her through process of creating a dummy project as a means to get the right templates loaded. It worked, and she has successfully been working on the project that had been upgraded to 5.3.4 just this week.

Missing Templates after 6.0.0 Release Today, I attempted to work on the microservice project that my colleague created with 5.3.4 (referenced in above example). When I tried to add a new entity, I received a "Cannot read the template..." error. This seemed odd to me because it should've been using the same Templates as the project I successfully worked on last week as all our projects are 5.3.4.

I then attempted to create a new dummy project (as described above) in the hopes it would introduce the correct templates. However, ABP Suite created a 6.0.0 project even though I have 5.3.4 CLI/Suite installed. I appear to be unable to generate a new 5.3.4 project now.

So then I go to my other project that I had been working on last week and it is now also throwing template errors when I attempt to add an entity. I've re-tried the various solutions of reinstalling tools, removing build artifacts, etc. I cannot get the correct Templates to load again. As a result, all code generation tasks on existing projects will not complete successfully.

Additional information:

I asked my colleagues to check ABP Suite generation on their dev machines and both reported same issue (both on CLI/Suite v5.3.4).

One colleague found a workaround similar to what I described. Rough steps:

  1. Generate new microservice module solution - It generates 6.0.0 solution and entity creation will fail due to version mismatch.
  2. Modify appsettings.json file to change it to 5.3.4.
  3. Not sure exactly here, but here's what I did: code generation still didn't work. I stopped ABP Suite and restarted, though it reloaded project as 6.0.0, so I changed appsettings.json again to 5.3.4
  4. Generate new entity on new solution.
  5. Code generation immediately started working on existing 5.3.4 solutions

If we need to add another microservice module, I'm not sure what issues we'll run into by it generating 6.0.0 and us manually changing to 5.3.4 to be compatible with our existing platform until we upgrade everything to latest version (which we only do when we want to access new features).

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

We're attempting to migrate from MVC to Angular. I'm definitely making some headway, but the microservice development pattern is not clear for Angular.

For instance, when creating a new microservices template, an Angular app is created. This runs out of the box and connects to identity server. Next, I create a new microservice module. When I do this, the solution also creates an Angular app. As I build out this microservice module, I can generate UI code that goes into the Angular app of the microservice.

For reference, I looked at: https://github.com/abpframework/eShopOnAbp I noted that there is an Angular app under the apps folder for the entire solution. The individual services do not have their own Angular apps. In the one Angular app, two services are listed under "projects".

What is the process for getting all microservices into a single Angular app?

  • Should I be generating UI code against the microservice module Angular app? This makes sense since this would allow us to develop an individual service in isolation. But then how do I to get this module's UI into the "main" Angular app?
  • Or, should I be generating UI code against the "main" Angular app (Modify the ABP suite settings to point the Angular app path to main app)?
  • ABP Framework version: v5.1.3
  • UI type: MVC
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Separated (Angular): yes

We have been building a large solution for a while now, and we've used the ABP Suite generated CRUD UI using MVC. This is a microservices architecture solution.

Currently, when building out new functionality in one of the microservices, we use ABP Suite to generate new entities and the related CRUD UI elements. We then cut/paste those UI elements to a central UI application. This has been working great.

After review, we determined that Angular is a more suitable UI Framework for what we plan to do. I created a new ABP Solution, then took the generated Angular app and wired up to our existing Identity Server. What I can't determine is if it's possible to generate CRUD UI from ABP Suite for this Angular front-end. We certainly don't want to manually build all the CRUD functions!

  • Is there an option to change UI Framework for a solution within ABP Suite (from MVC to Angular)?
  • In a microservices architecture, is there a way to make all UI CRUD generation go to a single Angular app?
显示 9 个条目中的 1 到 9 个.
Made with ❤️ on ABP v8.2.0-preview Updated on 三月 25, 2024, 15:11