Browse Source

Merge branch 'dev' into OpenIddict-Auditing

pull/20671/head
maliming 2 years ago
parent
commit
4e7d98f39b
No known key found for this signature in database GPG Key ID: A646B9CB645ECEA4
  1. 94
      .github/ISSUE_TEMPLATE/03_studio.yml
  2. 0
      .github/ISSUE_TEMPLATE/04_article_request.yml
  3. 0
      .github/ISSUE_TEMPLATE/05_performance_issue.md
  4. 0
      .github/ISSUE_TEMPLATE/06_blank_issue.md
  5. 1
      abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/en.json
  6. 85
      docs/en/Community-Articles/2024-08-29-What-is-Angular-Schematics/Post.md
  7. BIN
      docs/en/Community-Articles/2024-08-29-What-is-Angular-Schematics/cover.png
  8. 123
      docs/en/Community-Articles/2024-09-01-Do-You-Need-MultiTenancy/Post.md
  9. BIN
      docs/en/Community-Articles/2024-09-01-Do-You-Need-MultiTenancy/coupled-tenants.png
  10. BIN
      docs/en/Community-Articles/2024-09-01-Do-You-Need-MultiTenancy/cover.png
  11. BIN
      docs/en/Community-Articles/2024-09-01-Do-You-Need-MultiTenancy/questions.png
  12. BIN
      docs/en/Community-Articles/2024-09-01-Do-You-Need-MultiTenancy/security-gdpr-db-retention.png
  13. BIN
      docs/en/Community-Articles/2024-09-01-Do-You-Need-MultiTenancy/shared-entity.png
  14. BIN
      docs/en/Community-Articles/2024-09-01-Do-You-Need-MultiTenancy/tenancy-schema.png
  15. BIN
      docs/en/Community-Articles/2024-09-01-Do-You-Need-MultiTenancy/user-multiple-membership.png
  16. 1
      docs/en/cli/index.md
  17. 4
      docs/en/docs-nav.json
  18. 69
      docs/en/framework/infrastructure/background-jobs/hangfire.md
  19. 2
      docs/en/get-started/microservice.md
  20. 1
      docs/en/modules/cms-kit-pro/index.md
  21. 129
      docs/en/release-info/road-map.md
  22. 6
      docs/en/solution-templates/microservice/adding-new-api-gateways.md
  23. 6
      docs/en/solution-templates/microservice/adding-new-applications.md
  24. 372
      docs/en/solution-templates/microservice/adding-new-microservices.md
  25. BIN
      docs/en/solution-templates/microservice/images/folder-structure.png
  26. 6
      docs/en/studio/overview.md
  27. 91
      docs/en/studio/release-notes.md
  28. 16
      docs/en/tutorials/todo/layered/index.md
  29. 2
      modules/blogging/src/Volo.Blogging.Application/Volo/Blogging/Posts/PostAppService.cs
  30. 7
      modules/openiddict/src/Volo.Abp.OpenIddict.AspNetCore/Microsoft/Extensions/DependencyInjection/OpenIddictServerBuilderExtensions.cs
  31. 16
      npm/ng-packs/packages/core/src/lib/utils/generator-utils.ts
  32. 8
      npm/ng-packs/packages/theme-basic/src/lib/components/nav-items/current-user.component.html

94
.github/ISSUE_TEMPLATE/03_studio.yml

@ -0,0 +1,94 @@
name: 🤠 ABP Studio
description: Create a report to help us improve the ABP Studio
labels: [studio]
body:
- type: markdown
attributes:
value: |
We welcome bug reports! This template will help us gather the information we need to start the triage process.
Please keep in mind that the GitHub issue tracker is not intended as a general support forum, but for reporting **non-security** bugs and feature requests.
If you believe you have an issue that affects the SECURITY of the platform, please do NOT create an issue and instead email your issue details to info@abp.io.
For other types of questions, consider using [StackOverflow](https://stackoverflow.com/questions/tagged/abp).
- type: checkboxes
id: searched
attributes:
label: Is there an existing issue for this?
description: Please search to see if an issue already exists for the bug you encountered or feature request ([abp/issues](https://github.com/abpframework/abp/issues?q=is%3Aopen+is%3Aissue+label%3Astudio)).
options:
- label: I have searched the existing issues
required: true
- type: textarea
id: background
attributes:
label: Description
description: Please share a clear and concise description of the problem.
placeholder: Description
validations:
required: true
- type: markdown
attributes:
value: |
## Setup
Please provide more information on your ABP Studio setup.
- type: input
id: version
attributes:
label: Version
description: Which version of ABP Studio are you using?
placeholder: Version
validations:
required: true
- type: dropdown
id: Operation-System
attributes:
label: Operation System
description: What is the operation system of the computer?
options:
- Windows (Default)
- Linux
- macOS
- Others
validations:
required: true
- type: textarea
id: solution-config
attributes:
label: Solution Configuration
description: |
If there is an open solution, what are the configurations of the solution?
🧐 Hint: You can see all the information about your solution from the configuration window, which opens when you right-click on the [solution](https://abp.io/docs/latest/studio/solution-explorer#solution) and click on the `Solution Configuration` button.
placeholder: |
- **Template**: app
- **Created ABP Studio Version**: 0.7.9
- **Tiered**: No
- **UI Framework**: mvc
- **Theme**: leptonx
- **Theme Style**: system
- **Database Provider**: ef
- **Database Management System**: sqlserver
- **Separate Tenant Schema**: No
- **Mobile Framework**: none
- **Public Website**: No
- **Optional Modules**:
* GDPR
* TextTemplateManagement
* LanguageManagement
* AuditLogging
* SaaS
* OpenIddictAdmin
validations:
required: false
- type: markdown
attributes:
value: |
---
- type: textarea
id: other-info
attributes:
label: Other information
description: |
If you have an idea where the problem might lie, let us know that here. Please include any pointers to code, relevant changes, or related issues you know of.
placeholder: Other information
validations:
required: false

0
.github/ISSUE_TEMPLATE/03_article_request.yml → .github/ISSUE_TEMPLATE/04_article_request.yml

0
.github/ISSUE_TEMPLATE/04_performance_issue.md → .github/ISSUE_TEMPLATE/05_performance_issue.md

0
.github/ISSUE_TEMPLATE/05_blank_issue.md → .github/ISSUE_TEMPLATE/06_blank_issue.md

1
abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/en.json

@ -1440,6 +1440,7 @@
"MAUI": "MAUI",
"HowItWorks_Page_Title": "How it Works?",
"HowItWorks_Page_Description": "Understand how ABP Framework works with detailed documentation, including guides and best practices.",
"HowItWorks_Description_Title": "What’s possible with ASP.NET Core, easier with ABP!",
"HowItWorks_Description1": "ABP extends the .NET platform. So, anything you can do with a plain .NET solution is already possible with ABP. That makes it easy to get started with a low learning curve.",
"HowItWorks_Description2": "Once you start learning and using ABP features, developing your software will be much more enjoyable than ever.",
"HowItWorks_Description3": "This page basically explains how you use the ABP Platform as a .NET developer.",

85
docs/en/Community-Articles/2024-08-29-What-is-Angular-Schematics/Post.md

@ -0,0 +1,85 @@
# What is Angular Schematics?
![Cover Image](cover.png)
**Angular Schematics** is a powerful tool which is part of the Angular CLI that allows developers to automate various development tasks by **generating and modifying code**. Schematics provides a way to create **templates and boilerplate code** for Angular applications or libraries, enabling consistency and reducing the amount of repetitive work.
### Key Concepts of Angular Schematics:
1. **Code Generation:**
- Schematics can generate boilerplate code for various Angular artifacts, such as components, services, modules, pipes... For example, when you run a command like `ng generate component my-component`, Angular uses a schematic to create the component files and update the necessary modules.
2. **Code Modification:**
- Schematics can also modify existing code in your project. This includes tasks like updating configuration files, adding new routes, or modifying Angular modules. They can be very useful when upgrading projects to a new version of Angular or adding new features that require changes to the existing codebase.
3. **Custom Schematics:**
- Developers can create their own custom schematics to automate repetitive tasks specific to their projects. For example, if your team frequently needs to set up a certain type of service or configure specific libraries, you can create a schematic that automates these steps. In [ABP Suite](https://abp.io/suite), we use the custom schematics templates to generate CRUD pages for Angular UI.
4. **Collection of Schematics:**
- Schematics are often grouped into collections. The Angular CLI itself is a collection of schematics. You can create your own collection or use third-party schematic collections created by the Angular community.
5. **Integration with Angular CLI:**
- Schematics is integrated with the Angular CLI. The `ng generate` and `ng add` commands are examples of how schematics are used in everyday Angular development. When you use these commands, the Angular CLI runs the corresponding schematic to perform the desired operation.
6. **Upgrade Tasks:**
- Schematics can be used to automate the process of upgrading Angular applications. For example, the Angular Update command (`ng update`) uses schematics to automatically apply necessary changes to your project when upgrading to a new version of Angular.
### Common Use Cases:
- **Generating Components, Services, Modules.:** Easily create Angular building blocks with commands like `ng generate component`, `ng generate service`, or `ng generate module`.
- **Adding Libraries:** Automatically set up and configure third-party libraries with `ng add`. For example, `ng add @angular/material` uses a schematic to install and configure Angular Material in your project.
- **Automating Project Upgrades:** Simplify the process of upgrading Angular versions by running `ng update`, which uses schematics to make necessary code changes.
- **Custom Project Scaffolding:** Create custom schematics to enforce your team's development standards and best practices by automating the creation of specific project structures.
### How to Create a Custom Schematic:
Creating a custom schematic involves several steps:
1. **Install the Schematics CLI:**
```bash
npm install -g @angular-devkit/schematics-cli
```
2. **Create a New Schematic Project:**
```bash
schematics blank --name=my-schematic
cd my-schematic
```
3. **Define Your Schematic:** Modify the files in the schematic project to define what your schematic will generate or modify.
4. **Test Your Schematic:** You can run your schematic locally using the `schematics` command.
5. **Publish Your Schematic (Optional):** Once your schematic is ready, you can publish it to npm or include it in your Angular projects.
#### Example:
If you want to create a custom component with specific settings or styles, you can create a schematic to automate this. Every time a developer on your team needs to create this type of component, they can run the schematic, ensuring consistency across the project.
### Helpful Links
Here are the direct links for the Angular Schematics resources:
- [Angular Official Documentation: Schematics Overview — angular.io](https://angular.io/guide/schematics)
- [Creating Custom Schematics — angular.io](https://angular.io/guide/schematics-for-libraries)
- [CLI Schematic Command — angular.io](https://angular.io/cli/schematic)
- [Devkit Schematics— github.com](https://github.com/angular/angular-cli/tree/main/packages/angular_devkit/schematics)
- [Schematics Examples — github.com](https://github.com/angular/angular-cli/tree/main/packages/schematics/angular)
- [Debugging Angular Schematics — dev.to](https://dev.to/nikolasleblanc/debugging-angular-schematics-1ne0)
- [Using Schematics with Nx — nx.dev](https://nx.dev/guides/using-angular-schematics)
- [Schematics API — angular.io](https://angular.io/api/schematics)
### Conclusion:
Angular Schematics is a powerful tool for automating repetitive tasks, generating consistent code, and managing project upgrades. By leveraging schematics, Angular developers can save time, reduce errors, and enforce best practices across their projects.

BIN
docs/en/Community-Articles/2024-08-29-What-is-Angular-Schematics/cover.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 35 KiB

123
docs/en/Community-Articles/2024-09-01-Do-You-Need-MultiTenancy/Post.md

@ -0,0 +1,123 @@
# Do You Really Need Multi-tenancy?
This article discusses whether you need a multi-tenancy architecture for your next project. Answer my critical questions to decide if multi-tenancy suits your application or not!
![Cover image](cover.png)
## What’s Multi-tenancy?
It’s an architectural approach to building SaaS solutions. In this model, the hardware and software resources are shared between tenants, and application data is virtually or physically isolated between tenants. Here, **the main goal is minimizing costs and maximizing customer count**.
**An ideal multi-tenant application should be;**
- A multi-tenancy system should be designed to **work seamlessly** and make your application code **multi-tenancy aware** as much as possible.
- When a customer wants to separate their database, it **should also be deployable to on-premise**.
![Tenancy Schema](tenancy-schema.png)
---
## Multi-tenant Development is Hard - Reconsider!
**Developing a multi-tenant application is harder** compared to non-multi-tenant applications. You add `TenandId` to all your shared entities. And each time you make a query, you need to filter by `TenantId`. There is an increased risk of security breaches if one tenant's data is compromised. Multi-tenancy can limit the extent of customization available to each tenant since they all operate on the same core infrastructure. Also, in a microservice environment, things get two times more complicated. So you should carefully consider if you need multi-tenancy or not. Sometimes, I got questions like;
![Questions](questions.png)
**No! These are not multi-tenant applications.** It just needs a simple filtering by your different branches/faculties/departments/holding sub-companies/ groups or whatever hierarchy is…
**You are confusing "grouping" with "resource sharing".**
---
## Do I Really Need Multi-tenancy?
Ask yourself the following questions if you cannot decide whether your app needs multi-tenancy or not;
1. Can a user be shared among other tenants?
2. Any tenant needs to see other tenant's data?
3. Does your application break when you physically move one of the tenants?
4. Do your customers need higher security and better GDPR enforcement?
5. Do you need cumulative queries over your tenants?
Let's answer these questions;
##### **1. Can a user be shared among other tenants?**
If you need to *share a user among other tenants, or in other words, users can be members of different tenants,* then **your application is definitely not multi-tenant**! Multi-tenancy means a tenant’s data is always isolated, even if it’s logically separated. **You cannot share a user among your tenants.** The reason is simple: In the future, if you move a tenant to on-premise, then your application will break!
![user-multiple-membership](user-multiple-membership.png)
##### **2. Does any tenant need to see other tenants' data?**
If your answer is **YES**, **then** **your application is not multi-tenant**. In multi-tenant apps, the tenant's data cannot be shared in any circumstances among the other tenants. Business decision-makers sometimes want to share some entities with other tenants. If there's this requirement, you shouldn't start a multi-tenant architecture. You can simply group these tenants manually. Again, reply to this question; **In the future, if I move a tenant physically to another environment, will my app still work properly?** In this case, it will not!
![Shared entity](shared-entity.png)
Let's say your app is *Amazon.com* and you have a product entity *iPhone* that you want to share with other sellers. This requirement violates the multi-tenant rule. While your *Amazon.com* is still SaaS, it shouldn't be multi-tenant.
On the other hand, if you serve several online shopping websites dedicated to different brands. Let's say Nike and Adidas want to have their own e-commerce websites. And your ***Amazon.com* provides these companies with their own subdomains: *nike.amazon.com* and *adidas.amazon.com***. In this architecture, these companies will have their own user, roles, settings. Also these companies will have their own branding like custom login screen, custom logo, different theme layouts, menu items, language options, payment gateways etc... Hence, **this is %100 multi-tenant.**
##### **3. Does your application break when you physically move one of the tenants?**
If your answer is **YES**, you should **stop making it multi-tenant**. It is **not a multi-tenant app**! This means your tenants are tightly coupled with the application's infrastructure or database, and this requirement prevents you from making it multi-tenant because it disrupts the entire system when you take out a tenant.
![Coupled Tenants](coupled-tenants.png)
##### **4. Do your customers need higher security and better GDPR enforcement?**
If your answer is **YES**, you **should not make it multi-tenancy.** When a **hacker** gets into your server, he can **steal all your client data**. Also, if you have a security hole, **a tenant can gain access** to other tenants' data. Especially your tenants' data is being shared in the same database... On the other hand, some customers, for example, government agencies or banks, may be required to locate the database in their own geo-location and make it unreachable from the main application. In this case, you should go with a single-tenant architecture. Another difficulty is that some tenants may have **different data retention policies**, so you must implement different strategies for each tenant. In this case, you should also consider making it a single-tenant.
![Security GDPR Data Retention](security-gdpr-db-retention.png)
##### **5. Do you need cumulative queries over your tenants?**
This question is not a clear decision parameter for multi-tenancy. But it can be a supportive parameter for your decision. Actually, this is a common feature in multi-tenant systems where aggregated reporting or analytics across tenants is required. In a virtually isolated multi-tenant environment, you can easily do this by just disabling the multi-tenancy filter. However, when some of your tenants have separate databases or application instances, it becomes harder to get aggregate reports.
Do you need cumulative queries over your tenants? If your answer is YES, then you should keep all your tenants' data in a shared database to easily query them. But if you still need to physically move some of the tenants, then you have the following strategies:
* First, all your databases need to be on the same network so that you can gather data from different databases.
* Second, in some cases, according to the GDPR requirements or government agency regulations, you must locate the database in their geo-location. And you cannot connect to these databases. In this case, you can create a Web API in your application that gives you a report for this specific tenant. Later, you'll gather the reports from all your tenants like this and merge them.
* Third; When the tenant databases are in different geo-location (inaccessible), then each tenant can send their report to your central server. So you can generate cumulative reports.
## Conclusion
- It's important to decide on the first day whether your application needs to be multi-tenant. To decide this, consider these topics;
- **Do my tenants really have a relationship with each other?** No, they have nothing to do in common; **OK, go with multi-tenancy**.
- **My tenants don't have a relationship** with each other, and the only thing they have in common is sharing my application. **OK, go with multi-tenancy**.
- **When a tenant leaves the system (by removing their data), the other tenants also stop working** This means that the tenants are coupled. **Do not do multi-tenancy!**
---
![Logo](https://abp.io/assets/platform/img/logos/logo-abp-dark.svg)
We’ve been working for a long time on multi-tenancy, microservices, modular development topics, and developing tools and frameworks for repetitive development tasks. Check out the amazing open-source [ABP Framework](https://github.com/abpframework/abp), which provides all the alternative solutions to implement a multi-tenant architecture. The multi-tenancy logic is seamlessly done at the core level, and you can simply focus on your business code. Keep it simple, nice and neat with ABP.
```bash
ABP.IO: The Modern Way of Developing Web Apps for .NET Developers!
```
Alper Ebicoglu / [x.com/alperebicoglu](https://x.com/alperebicoglu)
— ABP Team

BIN
docs/en/Community-Articles/2024-09-01-Do-You-Need-MultiTenancy/coupled-tenants.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

BIN
docs/en/Community-Articles/2024-09-01-Do-You-Need-MultiTenancy/cover.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 989 KiB

BIN
docs/en/Community-Articles/2024-09-01-Do-You-Need-MultiTenancy/questions.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 18 KiB

BIN
docs/en/Community-Articles/2024-09-01-Do-You-Need-MultiTenancy/security-gdpr-db-retention.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

BIN
docs/en/Community-Articles/2024-09-01-Do-You-Need-MultiTenancy/shared-entity.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 14 KiB

BIN
docs/en/Community-Articles/2024-09-01-Do-You-Need-MultiTenancy/tenancy-schema.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

BIN
docs/en/Community-Articles/2024-09-01-Do-You-Need-MultiTenancy/user-multiple-membership.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 31 KiB

1
docs/en/cli/index.md

@ -924,6 +924,7 @@ abp bundle [options]
* ```--project-type``` or ```-t```: Specifies the project type. Default type is `webassembly`. Available types:
* `webassembly`
* `maui-blazor`
* `--version` or `-v`: Specifies the ABP Framework version that the project is using. This is helpful for those who use central package management.
`bundle` command reads the `appsettings.json` file inside the Blazor and MAUI Blazor project for bundling options. For more details about managing style and script references in Blazor or MAUI Blazor apps, see [Managing Global Scripts & Styles](../framework/ui/blazor/global-scripts-styles.md)

4
docs/en/docs-nav.json

@ -188,6 +188,10 @@
{
"text": "Version Compatibility",
"path": "studio/version-compatibility.md"
},
{
"text": "Release Notes",
"path": "studio/release-notes.md"
}
]
},

69
docs/en/framework/infrastructure/background-jobs/hangfire.md

@ -154,3 +154,72 @@ app.UseAbpHangfireDashboard("/hangfire", options =>
**Important**: `UseAbpHangfireDashboard` should be called after the authentication and authorization middlewares in your `Startup` class (probably at the last line). Otherwise,
authorization will always fail!
#### Dashboard Authorization In API Projects
If you use the hangfire dashboard in an API project that uses non-cookie authentication (like JWT Bearers), The `/hangfire` page can't authenticate the user.
In this case, you can add a cookies authorization scheme to authenticate the user. The best way to do this is to use the `Cookie` and `OpenIdConnect` authentication schemes. This requires creating a new OAuth2 client and adding the `ClientId`, and `ClientSecret` properties to the `AuthServer` section in the `appsettings.json` file.
The final code should look like below:
```csharp
private void ConfigureAuthentication(ServiceConfigurationContext context, IConfiguration configuration)
{
context.Services.AddAuthentication(JwtBearerDefaults.AuthenticationScheme)
.AddAbpJwtBearer(options =>
{
options.Authority = configuration["AuthServer:Authority"];
options.RequireHttpsMetadata = configuration.GetValue<bool>("AuthServer:RequireHttpsMetadata");
options.Audience = "MyProjectName";
});
context.Services.AddAuthentication()
.AddCookie("Cookies")
.AddOpenIdConnect("oidc", options =>
{
options.Authority = configuration["AuthServer:Authority"];
options.RequireHttpsMetadata = configuration.GetValue<bool>("AuthServer:RequireHttpsMetadata");
options.ResponseType = OpenIdConnectResponseType.CodeIdToken;
options.ClientId = configuration["AuthServer:ClientId"];
options.ClientSecret = configuration["AuthServer:ClientSecret"];
options.UsePkce = true;
options.SaveTokens = true;
options.GetClaimsFromUserInfoEndpoint = true;
options.Scope.Add("roles");
options.Scope.Add("email");
options.Scope.Add("phone");
options.Scope.Add("MyProjectName");
});
}
```
```csharp
app.Use(async (httpContext, next) =>
{
if (httpContext.Request.Path.StartsWithSegments("/hangfire"))
{
var result = await httpContext.AuthenticateAsync("Cookies");
if (result.Succeeded)
{
httpContext.User = result.Principal;
await next(httpContext);
return;
}
await httpContext.ChallengeAsync("oidc");
}
else
{
await next(httpContext);
}
});
app.UseAbpHangfireDashboard("/hangfire", options =>
{
options.AsyncAuthorization = new[] {new AbpHangfireAuthorizationFilter()};
});
```

2
docs/en/get-started/microservice.md

@ -125,6 +125,8 @@ In the *Solution Runner* section (on the left side) you can see all the runnable
> All the leaf items in the *Solution Runner* is called as an *Application* as they are executable applications.
> For a faster start process, first start the *Docker-Dependencies*, then you can start all applications.
As shown in the figure above, the executable applications are grouped into folders like `apps`, `gateways`, `infrastructure`, and `services`. You can start/stop them all, a group (folder) of them, or one by one.
Before running the applications, it is good to be sure that all applications are built. To do that, right-click the root item in the *Solution Runner* and select *Build* -> *Build All* action.

1
docs/en/modules/cms-kit-pro/index.md

@ -17,6 +17,7 @@ The following features are provided by the open-source CMS Kit module:
- [**Menu**](../cms-kit/menus.md) system to manage public menus dynamically.
- [**Global resources**](../cms-kit/global-resources.md) system to add global styles and scripts dynamically.
- [**Dynamic widget**](../cms-kit/dynamic-widget.md) system to create dynamic widgets for page and blog posts.
- [**Marked Item**](../cms-kit/marked-items.md) system to flag favorites or important items with icons or emojis.
The following features are provided by the CMS Kit Pro version:

129
docs/en/release-info/road-map.md

@ -8,52 +8,115 @@ This document provides a road map, release schedule, and planned features for th
The next version will be 9.0 and planned to release the stable 9.0 version in November 2024. We will be mostly working on the following topics:
* Upgrading to .NET 9
* Introducing `Extension Property Policy` feature
* Handling localization resources in a microservice scenario
* ABP Suite: Show default template for customized templates for better sync.
* Microservice development tutorials
* Improvements on the existing features and provide more guides.
See the [9.0 milestone](https://github.com/abpframework/abp/milestone/104) for all the issues we've planned to work on.
* Framework
* Upgrading to .NET 9.0
* Google Cloud Storage BLOB Provider
* Better handling localization resources in a microservice scenario
* SSR support for the Angular UI
* Upgrading 3rd-party dependencies
* ABP Suite
* Multiple navigation properties to the same target entity
* Define navigation properties without target string property dependency
* Improvements one-to-many scenarios
* Access to default code generation templates for customized templates
* ABP Studio
* Blazor WebApp UI option for the new startup templates
* Execution order (dependency management) for Solution Runner
* Automate more details on new service creation for a microservice solution
* Support multiple concurrent Kubernetes deployment/integration scenarios
* Show the README file when you create a new solution or open an existing solution
* Improve ABP Suite code-generation possibilities for microservice solutions
* Improve the module installation experience
* Auto-install 3rd-party dependencies
* Better handle long log files
* Allow to directly create new solutions with ABP's RC (Release Candidate) versions
* Support Intel processors for Mac computers, support ARM chipset for Windows and support Linux OS
* Improve client proxy generation experience
* Application modules
* Account module: Support mixed social/local login scenarios
* UI/UX improvements on existing application modules
* New tutorials
* Modular monolith development
* Microservice development
## Backlog Items
The *Next Versions* section above shows the main focus of the planned versions. However, in each release, we add new features to the core framework and the [application modules](../modules).
Here is a list of major items in the backlog we are considering working on in the next versions.
The *Next Versions* section above shows the main focus of the planned versions. However, in each release, we add new features to the ABP platform.
### Framework
* [#86](https://github.com/abpframework/abp/issues/86) / GrapQL Integration
The ABP framework is [open source](https://github.com/abpframework/abp) and free for everyone. You can see its [public backlog](https://github.com/abpframework/abp/milestone/2). Here, are some of the important features you can expect from next versions:
* [#236](https://github.com/abpframework/abp/issues/236) / Resource based authorization system
* [#2882](https://github.com/abpframework/abp/issues/2882) / Providing a gRPC integration infrastructure (while it is [already possible](https://github.com/abpframework/abp-samples/tree/master/GrpcDemo) to create or consume gRPC endpoints for your application, we plan to create endpoints for the [standard application modules](../modules))
* [#2882](https://github.com/abpframework/abp/issues/2882) / Providing a gRPC integration infrastructure (while it is [already possible](https://github.com/abpframework/abp-samples/tree/master/GrpcDemo) to create or consume gRPC endpoints for your application, we plan to create endpoints for the [standard application modules](../modules/index.md))
* [#57](https://github.com/abpframework/abp/issues/57) / Built-in CQRS infrastructure
* [#58](https://github.com/abpframework/abp/issues/58) / Content localization system (multilingual entities)
* [#4223](https://github.com/abpframework/abp/issues/4223) / WebHook system
* [#162](https://github.com/abpframework/abp/issues/162) / Azure ElasticDB Integration for multitenancy
* [#2296](https://github.com/abpframework/abp/issues/2296) / Feature toggling infrastructure
* [#16342](https://github.com/abpframework/abp/issues/16342) / CMS Kit: Meta information for SEO
* [#16260](https://github.com/abpframework/abp/issues/16260) / GCP Blob Storage Provider
* [#15932](https://github.com/abpframework/abp/issues/15932) / Introduce ABP Diagnostics Module
* [#16756](https://github.com/abpframework/abp/issues/16756) / Blob Storing - Provider configuration UI
* [#16744](https://github.com/abpframework/abp/issues/16744) / State Management API
### Modules / Themes
* New styles, components and features for the LeptonX theme.
* Payment module: Invoice system.
* Dynamic dashboard system.
* User guiding module.
* gRPC integration and implementation for all the pre-built modules.
### Tooling
* ABP Suite: Extra Properties on CRUD Page generation
* ABP Suite: Allow to create PAGE instead of MODAL for CRUD page generation
* ABP Suite: Export child/detail entity records
* CMS Kit features, including spam protection, social media feeds, multi-language support, and so on.
You can always check the milestone planning and the prioritized backlog issues on [the GitHub repository](https://github.com/abpframework/abp/milestones) for a detailed road map. The backlog items are subject to change. We are adding new items and changing priorities based on the community feedbacks and goals of the project.
* [#17815](https://github.com/abpframework/abp/issues/17815) / Operation Rate Limiting
### Application Modules / UI Themes
ABP Platform provides many (free and commercial) [pre-built application modules](../modules/index.md) and modern [UI themes](../ui-themes/index.md). In every release, many enhancements and bugfixes are already done on the existing modules. In addition, here some of the planned features for next versions:
* LeptonX theme: New layouts, styles and components
* CMS Kit module: Meta information for SEO, media gallery, RSS feed, content versioning, social media streams
* Identity module: Idle session warning
* Payment module: Invoice system
* New module: User notification
* New module: Dynamic dashboard
* New module: User guiding
* New module: Keycloak integration
### ABP Studio
[ABP Studio](../studio/index.md) is a cross-platform desktop application for ABP and .NET developers to simplify and automate daily tasks of developers. It has a community (free) edition as well as commercial editions. It is released and versioned independently from the ABP platform and frequently released.
Here, are some of the important planned features for next ABP Studio versions:
* Theme builder for the LeptonX theme
* Analyze user solutions to explore entities, domain services, application services, pages and other fundamental objects.
* Add status bar to the built-in browser to easily see errors
* Swagger authentication support for the built-in browser
* Show related requests/events (traces) together in the solution runner panel
* Integrate common tool dashboards into ABP Studio (such a Garana, Redis, RabbitMQ, Kibana, etc)
* Built-in command terminal
* Automate all steps of new service creation for microservice solutions
* Container application type support for Solution Runner (to individually control docker dependencies)
* More options while creating new solutions
* Downloading samples in ABP studio
* Built-in ABP documentation experience
* Auto-execute terminal commands in markdown files
* Compare changed on the startup templates when a new ABP version is published
* Remove unused projects while downloading source code of an existing module
* Testing/hosting applications for module templates
* Easily explore all module and package dependencies of a large solution
* Built-in deployment options
* Rapid application development features
* ABP support integration
### ABP Suite
[ABP Suite](../suite/index.md) is a GUI application that is mainly used to generate CRUD style pages in your application. You define your entity and it can generate all the code from the database layer to the UI layer. The generated code is clean and a perfect starting point to implement your custom requirements on top of it.
Here, are some of the important planned features for next ABP Suite versions:
* Handle image properties for entities
* Allow to define extra properties for DTOs those are not a part of the entity
* Allow to create pages instead of modals for CRUD page generation
* View-only (detail view) modal/page for an entity
* Export child/detail entity records as a part of export operation for a main (master) entity
* Allow to accept attachments (files) for an entity
* Allow to add custom entity actions for an entity
* Allow to inherit from an existing entity class
* Custom form layouts on CRUD page generation
## Feature Requests

6
docs/en/solution-templates/microservice/adding-new-api-gateways.md

@ -155,12 +155,6 @@ We should configure the AuthServer for **CORS** and **RedirectAllowedUrls**.
}
```
### Add the New Gateway to the Solution Runner
We should add the new gateway to the solution runner [profile](../../studio/running-applications.md#profile) for running applications in the ABP Studio. You can follow the steps explained in the [Solution Runner](../../studio/running-applications.md#c-application) document to add the new gateway to the solution runner profile. Afterwards, you can start the new gateway by selecting it in the solution runner.
![public-gateway-solution-runner](images/public-gateway-solution-runner.png)
## Creating Helm Chart for the New Gateway
If you want to deploy the new gateway to Kubernetes, you should create a Helm chart for the new application.

6
docs/en/solution-templates/microservice/adding-new-applications.md

@ -120,12 +120,6 @@ Add the new application URL to the `appsettings.json` file in the `Identity` ser
}
```
### Add the New Application to the Solution Runner
We should add the new application to the solution runner [profile](../../studio/running-applications.md#profile) for running applications in the ABP Studio. You can follow the steps explained in the [Solution Runner](../../studio/running-applications.md#c-application) document to add the new application to the solution runner profile. Afterwards, you can start the new application by selecting it in the solution runner.
![web-public-solution-runner](images/web-public-solution-runner.png)
## Docker Configuration for Prometheus
If you want to monitor the new application with Prometheus when you debug the solution, you should add the new application to the `prometheus.yml` file in the `etc/docker/prometheus` folder. You can copy the configurations from the existing applications and modify them according to the new application. Below is an example of the `prometheus.yml` file for the `WebPublic` application.

372
docs/en/solution-templates/microservice/adding-new-microservices.md

@ -16,6 +16,8 @@ This document explains how to add new microservices to the microservice solution
Additionally, there is a folder named `_templates` in the root directory. This folder contains templates you can use to create new microservices, API gateways, and applications. These templates can be customized according to your needs.
![folder-structure](images/folder-structure.png)
## Adding a New Microservice
To add a new microservice to the solution, you can use the `service_nolayers` template. This template creates a new ASP.NET Core application with the necessary configurations and dependencies. Follow the steps below to add a new microservice:
@ -40,29 +42,34 @@ The new microservice is created and added to the solution. You can see the new m
The new microservice is created with the necessary configurations and dependencies. We should configure several sections by modifying the `appsettings.json` file:
* Set the `Administration` & `AbpBlobStoring` connection strings.
* Set the correct `StringEncryption` key.
* Set the `CorsOrigins` to allow the web gateway to access the microservice.
* Set the `AuthServer` configurations to enable the microservice to authenticate and authorize users.
* Set the correct `StringEncryption` key.
You can copy the configurations from the existing microservices and modify them according to the new microservice. Below is an example of the `appsettings.json` file for the `ProductService` microservice.
```json
```diff
{
"ConnectionStrings": {
"Administration": "Server=localhost,1434; User Id=sa; Password=myPassw@rd; Database=Bookstore_Administration; TrustServerCertificate=true",
"AbpBlobStoring": "Server=localhost,1434; User Id=sa; Password=myPassw@rd; Database=Bookstore_BlobStoring; TrustServerCertificate=true",
- "Administration": "Administration_Database",
- "AbpBlobStoring": "BlobStoring_Database",
+ "Administration": "Server=localhost,1434; User Id=sa; Password=myPassw@rd; Database=Bookstore_Administration; TrustServerCertificate=true",
+ "AbpBlobStoring": "Server=localhost,1434; User Id=sa; Password=myPassw@rd; Database=Bookstore_BlobStoring; TrustServerCertificate=true",
"ProductService": "Server=localhost,1434; User Id=sa; Password=myPassw@rd; Database=Bookstore_ProductService; TrustServerCertificate=true"
},
"App": {
"CorsOrigins": "http://localhost:44333",
- "CorsOrigins": "http://localhost:webgateway_port",
+ "CorsOrigins": "http://localhost:44333",
"EnablePII": false
},
"Swagger": {
"IsEnabled": true
},
"AuthServer": {
"Authority": "http://localhost:44387",
"MetaAddress": "http://localhost:44387",
- "Authority": "http://localhost:authserver_port",
- "MetaAddress": "http://localhost:authserver_port",
+ "Authority": "http://localhost:44387",
+ "MetaAddress": "http://localhost:44387",
"RequireHttpsMetadata": "false",
"SwaggerClientId": "SwaggerTestUI",
"Audience": "ProductService"
@ -93,24 +100,25 @@ You can copy the configurations from the existing microservices and modify them
"Url": "http://localhost:9200"
},
"StringEncryption": {
"DefaultPassPhrase": "PDAWjbshpwlOwNB6"
- "DefaultPassPhrase": "string_encrryption_key"
+ "DefaultPassPhrase": "PDAWjbshpwlOwNB6"
}
}
```
### Configuring the OpenId Options
We should configure the OpenId options by modifying the `OpenIddictDataSeeder` in the `Identity` service. Below is an example of the `OpenIddictDataSeeder` options for the `ProductService` microservice.
We should configure the OpenId options by modifying the `OpenIddictDataSeeder` in the `Identity` service. Below is an example of the `OpenIddictDataSeeder` options for the `Product` microservice.
Create API scopes and add the required API scope for Swagger clients in the `CreateApiScopesAsync` and `CreateSwaggerClientsAsync` methods in the `OpenIddictDataSeeder` class.
```csharp
```diff
private async Task CreateApiScopesAsync()
{
await CreateScopesAsync("AuthServer");
await CreateScopesAsync("IdentityService");
await CreateScopesAsync("AdministrationService");
await CreateScopesAsync("ProductService"); // new service
+ await CreateScopesAsync("ProductService");
}
private async Task CreateSwaggerClientsAsync()
@ -120,21 +128,21 @@ private async Task CreateSwaggerClientsAsync()
"AuthServer",
"IdentityService",
"AdministrationService",
"ProductService" // new service
+ "ProductService"
});
}
```
Add the redirect URL for the new service in the `CreateSwaggerClientAsync` method.
```csharp
```diff
private async Task CreateSwaggerClientAsync(string clientId, string[] scopes)
{
...
...
...
var administrationServiceRootUrl = _configuration["OpenIddict:Resources:AdministrationService:RootUrl"]!.TrimEnd('/');
var productServiceServiceRootUrl = _configuration["OpenIddict:Resources:ProductService:RootUrl"]!.TrimEnd('/'); // new service
+ var productServiceRootUrl = _configuration["OpenIddict:Resources:ProductService:RootUrl"]!.TrimEnd('/');
await CreateOrUpdateApplicationAsync(
name: clientId,
@ -152,15 +160,15 @@ private async Task CreateSwaggerClientAsync(string clientId, string[] scopes)
$"{authServerRootUrl}/swagger/oauth2-redirect.html",
$"{identityServiceRootUrl}/swagger/oauth2-redirect.html",
$"{administrationServiceRootUrl}/swagger/oauth2-redirect.html",
$"{productServiceServiceRootUrl}/swagger/oauth2-redirect.html", // new service
+ $"{productServiceRootUrl}/swagger/oauth2-redirect.html"
}
);
}
```
Add the allowed scope for the web (front-end) application(s) in the `CreateClientsAsync` method. You might have different clients for different UI applications such as web, Angular, React, etc. Ensure you add the new service to the allowed scopes of these clients.
Add the allowed scope for the web (front-end) application(s) in the `CreateClientsAsync` method. You might have different clients for different UI applications such as web, Angular, React, etc. Ensure you add the new microservice to the allowed scopes of these clients.
```csharp
```diff
private async Task CreateClientsAsync()
{
var commonScopes = new List<string>
@ -192,7 +200,7 @@ private async Task CreateClientsAsync()
"SaasService",
"AuditLoggingService",
"AdministrationService",
"ProductService" // new service
+ "ProductService"
}).ToList(),
redirectUris: new List<string> { $"{webClientRootUrl}signin-oidc" },
postLogoutRedirectUris: new List<string>() { $"{webClientRootUrl}signout-callback-oidc" },
@ -202,110 +210,130 @@ private async Task CreateClientsAsync()
}
```
Add the new service URL to the `appsettings.json` file in the `Identity` service.
Add the new service URL to the `appsettings.json` file in the `Identity` microservice. In this example we're gonna edit the *Acme.Bookstore.IdentityService* project `appsettings.json` file.
```json
```diff
"OpenIddict": {
"Applications": {
...
},
"Resources": {
...
"ProductService": {
"RootUrl": "http://localhost:44350"
}
+ "ProductService": {
+ "RootUrl": "http://localhost:44350"
+ }
}
}
```
### Configuring the AuthServer
We should configure the AuthServer for **CORS** and **RedirectAllowedUrls**.
We should configure the *AuthServer* application `appsettings.json` file for the **CorsOrigins** and **RedirectAllowedUrls** sections.
```json
```diff
...
"App": {
"SelfUrl": "http://localhost:***",
"CorsOrigins": "...... ,http://localhost:44350",
- "CorsOrigins": "http://localhost:44358,..",
+ "CorsOrigins": "http://localhost:44358,..,http://localhost:44350",
"EnablePII": false,
"RedirectAllowedUrls": "...... ,http://localhost:44350"
}
- "RedirectAllowedUrls": "http://localhost:44358,..",
+ "RedirectAllowedUrls": "http://localhost:44358,..,http://localhost:44350"
},
...
```
### Configuring the API Gateway
We should configure the API Gateway to allow the web gateway to access the new microservice. First, we should add the **ProductService** sections to the `appsettings.json` file in the `WebGateway` project.
We should configure the API Gateway to access the new microservice. First, add the **Product** sections to the `appsettings.json` file in the `WebGateway` project. In this example we're gonna edit the *Acme.Bookstore.WebGateway* project `appsettings.json` file.
```json
```diff
"ReverseProxy": {
"Routes": {
...
"ProductService": {
"ClusterId": "ProductService",
"Match": {
"Path": "/api/productservice/{**catch-all}"
}
},
"ProductServiceSwagger": {
"ClusterId": "ProductService",
"Match": {
"Path": "/swagger-json/ProductService/swagger/v1/swagger.json"
},
"Transforms": [
{ "PathRemovePrefix": "/swagger-json/ProductService" }
]
}
+ "Product": {
+ "ClusterId": "Product",
+ "Match": {
+ "Path": "/api/product/{**catch-all}"
+ }
+ },
+ "ProductSwagger": {
+ "ClusterId": "Product",
+ "Match": {
+ "Path": "/swagger-json/Product/swagger/v1/swagger.json"
+ },
+ "Transforms": [
+ { "PathRemovePrefix": "/swagger-json/Product" }
+ ]
+ }
},
"Clusters": {
...
"ProductService": {
"Destinations": {
"ProductService": {
"Address": "http://localhost:44350/"
}
}
}
+ "Product": {
+ "Destinations": {
+ "Product": {
+ "Address": "http://localhost:44350/"
+ }
+ }
+ }
}
}
```
Afterwards, open the `ProjectNameWebGatewayModule` class in the `WebGateway` and add the `ProductService` to the `ConfigureSwaggerUI` method.
Afterwards, open the `ProjectNameWebGatewayModule` class in the `WebGateway` project and add the `ProductService` to the `ConfigureSwaggerUI` method. In this example we're gonna edit the `BookstoreWebGatewayModule` file.
```diff
private static void ConfigureSwaggerUI(
IProxyConfig proxyConfig,
SwaggerUIOptions options,
IConfiguration configuration)
{
foreach (var cluster in proxyConfig.Clusters)
{
options.SwaggerEndpoint($"/swagger-json/{cluster.ClusterId}/swagger/v1/swagger.json", $"{cluster.ClusterId} API");
}
```csharp
options.OAuthScopes(
"AdministrationService",
"AuthServer",
"IdentityService",
"ProductService" // new service
);
options.OAuthClientId(configuration["AuthServer:SwaggerClientId"]);
options.OAuthScopes(
"AdministrationService",
"AuthServer",
...,
+ "ProductService"
);
}
```
### Configuring the UI Services
We should configure the UI application(s) to allow the new microservice to access through the web gateway. To do this, we should add the new service scope to the `ConfigureAuthentication` method in the `ProjectName...Module` class in the `Web` or `Blazor` application.
We should configure the UI application(s) to allow the new microservice to access through the web gateway. To do this, we should add the new microservice scope to the `ConfigureAuthentication` method in the `ProjectName...Module` class in the `Web` or `Blazor` application. In this example we're gonna edit the `BookstoreWebModule` file.
```csharp
context.Services.AddAuthentication(options =>
{
options.DefaultScheme = "Cookies";
options.DefaultChallengeScheme = "oidc";
})
.AddCookie("Cookies", options =>
{
options.ExpireTimeSpan = TimeSpan.FromDays(365);
})
.AddAbpOpenIdConnect("oidc", options =>
```diff
private void ConfigureAuthentication(ServiceConfigurationContext context, IConfiguration configuration)
{
...
options.Scope.Add("AuthServer");
options.Scope.Add("IdentityService");
options.Scope.Add("AdministrationService");
options.Scope.Add("ProductService"); // new servie
});
context.Services.AddAuthentication(options =>
{
options.DefaultScheme = "Cookies";
options.DefaultChallengeScheme = "oidc";
})
.AddCookie("Cookies", options =>
{
options.ExpireTimeSpan = TimeSpan.FromDays(365);
})
.AddAbpOpenIdConnect("oidc", options =>
{
...
options.Scope.Add("AuthServer");
options.Scope.Add("IdentityService");
options.Scope.Add("AdministrationService");
+ options.Scope.Add("ProductService");
});
...
}
```
Similarly, if you have an Angular application, you should add the new service scope to the `oAuthConfig` in `environment.ts`:
```typescript
```diff
const baseUrl = 'http://localhost:4200';
const oAuthConfig = {
@ -313,69 +341,83 @@ const oAuthConfig = {
redirectUri: baseUrl,
clientId: 'Angular',
responseType: 'code',
scope: 'openid profile email roles AuthServer IdentityService AdministrationService ProductService', // new service
- scope: 'openid profile email roles AuthServer IdentityService AdministrationService',
+ scope: 'openid profile email roles AuthServer IdentityService AdministrationService ProductService',
requireHttps: false
};
```
### Add the New Microservice to the Solution Runner
We should add the new microservice to the solution runner [profile](../../studio/running-applications.md#profile) for running applications in the ABP Studio. You can follow the steps explained in the [Solution Runner](../../studio/running-applications.md#c-application) document to add the new microservice to the solution runner profile. Afterwards, you can start the new microservice by selecting it in the solution runner.
![product-service-solution-runner](images/product-service-solution-runner.png)
## Docker Configuration for Prometheus
If you want to monitor the new microservice with Prometheus when you debug the solution, you should add the new microservice to the `prometheus.yml` file in the `etc/docker/prometheus` folder. You can copy the configurations from the existing microservices and modify them according to the new microservice. Below is an example of the `prometheus.yml` file for the `ProductService` microservice.
If you want to monitor the new microservice with Prometheus when you debug the solution, you should add the new microservice to the `prometheus.yml` file in the `etc/docker/prometheus` folder. You can copy the configurations from the existing microservices and modify them according to the new microservice. Below is an example of the `prometheus.yml` file for the `Product` microservice.
```yml
- job_name: 'product'
```diff
- job_name: 'authserver'
scheme: http
metrics_path: 'metrics'
static_configs:
- targets: ['host.docker.internal:44350']
- targets: ['host.docker.internal:44398']
...
+ - job_name: 'product'
+ scheme: http
+ metrics_path: 'metrics'
+ static_configs:
+ - targets: ['host.docker.internal:44350']
```
## Creating Helm Chart for the New Microservice
If you want to deploy the new microservice to Kubernetes, you should create a Helm chart for the new microservice.
First, we need to add the new microservice to the `build-all-images.ps1` script in the `etc/helm` folder. You can copy the configurations from the existing microservices and modify them according to the new microservice. Below is an example of the `build-all-images.ps1` script for the `ProductService` microservice.
First, we need to add the new microservice to the `build-all-images.ps1` script in the `etc/helm` folder. You can copy the configurations from the existing microservices and modify them according to the new microservice. Below is an example of the `build-all-images.ps1` script for the `Product` microservice.
```powershell
./build-image.ps1 -ProjectPath "../../services/product/Acme.Bookstore.ProductService/Acme.Bookstore.ProductService.csproj" -ImageName bookstore/productservice
```diff
...
./build-image.ps1 -ProjectPath "../../apps/auth-server/Acme.Bookstore.AuthServer/Acme.Bookstore.AuthServer.csproj" -ImageName bookstore/authserver
+ ./build-image.ps1 -ProjectPath "../../services/product/Acme.Bookstore.ProductService/Acme.Bookstore.ProductService.csproj" -ImageName bookstore/product
```
Then, we need to add the connection string to the `values.projectname-local.yaml` file in the `etc/helm/projectname` folder. Below is an example of the `values.bookstore-local.yaml` file for the `ProductService` microservice.
Then, we need to add the connection string to the `values.projectname-local.yaml` file in the `etc/helm/projectname` folder. Below is an example of the `values.bookstore-local.yaml` file for the `Product` microservice.
```yaml
```diff
global:
...
connectionStrings:
...
productService: "Server=[RELEASE_NAME]-sqlserver,1433; Database=Bookstore_ProductService; User Id=sa; Password=myPassw@rd; TrustServerCertificate=True"
+ product: "Server=[RELEASE_NAME]-sqlserver,1433; Database=Bookstore_ProductService; User Id=sa; Password=myPassw@rd; TrustServerCertificate=True"
```
Afterwards, we need to create a new Helm chart for the new microservice. You can copy the configurations from the existing microservices and modify them according to the new microservice. Below is an example of the `productservice` Helm chart for the `ProductService` microservice.
Afterwards, we need to create a new Helm chart for the new microservice. You can copy the configurations from the existing microservices and modify them according to the new microservice. Below is an example of the `product` Helm chart for the `Product` microservice.
Product microservice `values.yaml` file.
{%{
```yaml
# values.yaml
image:
repository: "bookstore/productservice"
repository: "bookstore/product"
tag: "latest"
pullPolicy: IfNotPresent
swagger:
isEnabled: "true"
```
}%}
# Chart.yaml
Product microservice `Chart.yaml` file.
{%{
```yaml
apiVersion: v2
name: productservice
name: product
version: 1.0.0
appVersion: "1.0"
description: Bookstore Product Service
```
}%}
Product microservice `product.yaml` file.
# product.yaml
{%{
```yaml
apiVersion: apps/v1
kind: Deployment
metadata:
@ -404,10 +446,15 @@ spec:
- name: "ConnectionStrings__AbpBlobStoring"
value: "{{ .Values.global.connectionStrings.blobStoring | replace "[RELEASE_NAME]" .Release.Name }}"
- name: "ConnectionStrings__ProductService"
value: "{{ .Values.global.connectionStrings.productService | replace "[RELEASE_NAME]" .Release.Name }}"
value: "{{ .Values.global.connectionStrings.product | replace "[RELEASE_NAME]" .Release.Name }}"
...
```
}%}
# product-service.yaml
Product microservice `product-service.yaml` file.
{%{
```yaml
apiVersion: v1
kind: Service
metadata:
@ -427,32 +474,113 @@ After creating the Helm chart, you can *Refresh Sub Charts* in the ABP Studio.
![kubernetes-refresh-sub-charts](images/kubernetes-refresh-sub-charts.png)
Then, update *Metadata* information right-click the *microservicename* [sub-chart](../../studio/kubernetes.md#subchart), select *Properties* it open *Chart Properties* window. You can edit in the *Metadata* tab.
Then, update *Metadata* information right-click the *microservicename* [sub-chart](../../studio/kubernetes.md#subchart), select *Properties* it open *Chart Properties* window. You should add the following keys in the *Metadata* tab.
![microservice-chart-properties](images/microservice-chart-properties-metadata.png)
- `projectPath`: The path to the microservice host application project. In the bookstore example, this value is `../../services/product/Acme.Bookstore.ProductService/Acme.Bookstore.ProductService.csproj`.
- `imageName`: When we build the Docker image, it uses this value as the Docker image name. We're going to use it in the Helm chart values.
- `projectType`: You can add a Helm chart for Angular and .NET projects, which is why we should explicitly specify the project type.
Add the *Kubernetes Services* in the *Chart Properties* -> *Kubernetes Services* tab.
![microservice-chart-properties-kubernetes-services](images/microservice-chart-properties-kubernetes-services.png)
> This value should be the same as the [solution runner application](./../../studio/running-applications.md#properties) *Kubernetes service* value. It's necessary for browsing because when we connect to the Kubernetes cluster, we should browse the Kubernetes services instead of using the Launch URL.
Last but not least, we need to configure the helm chart environments for identity, auth-server, and gateway applications.
Below is an example of the *Identity* microservice `identity.yaml` file.
{%{
```yaml
# identity.yaml
# Add this line to the "env:" section
- name: "OpenIddict__Resources__ProductService__RootUrl"
value: "http://{{ .Release.Name }}-productservice"
# authserver.yaml
# Concat the following lines for "App__CorsOrigins" section
- name: "App__CorsOrigins"
value: "...,http://{{ .Release.Name }}-administration,http://{{ .Release.Name }}-productservice"
# webapigateway.yaml
# Add this line to the "env:" section
- name: "ReverseProxy__Clusters__ProductService__Destinations__ProductService__Address"
value: "http://{{ .Release.Name }}-productservice"
```diff
apiVersion: apps/v1
kind: Deployment
metadata:
name: "{{ .Release.Name }}-{{ .Chart.Name }}"
spec:
selector:
matchLabels:
app: "{{ .Release.Name }}-{{ .Chart.Name }}"
template:
metadata:
labels:
app: "{{ .Release.Name }}-{{ .Chart.Name }}"
spec:
containers:
- image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
imagePullPolicy: "{{ .Values.image.pullPolicy }}"
name: "{{ .Release.Name }}-{{ .Chart.Name }}"
ports:
- name: "http"
containerPort: 80
env:
...
+ - name: "OpenIddict__Resources__ProductService__RootUrl"
+ value: "http://{{ .Release.Name }}-product"
```
}%}
Below is an example of the *AuthServer* application `authserver.yaml` file.
{%{
```diff
apiVersion: apps/v1
kind: Deployment
metadata:
name: "{{ .Release.Name }}-{{ .Chart.Name }}"
spec:
selector:
matchLabels:
app: "{{ .Release.Name }}-{{ .Chart.Name }}"
template:
metadata:
labels:
app: "{{ .Release.Name }}-{{ .Chart.Name }}"
spec:
containers:
- image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
imagePullPolicy: "{{ .Values.image.pullPolicy }}"
name: "{{ .Release.Name }}-{{ .Chart.Name }}"
ports:
- name: "http"
containerPort: 80
env:
...
- name: "App__CorsOrigins"
- value: "...,http://{{ .Release.Name }}-administration"
+ value: "...,http://{{ .Release.Name }}-administration,http://{{ .Release.Name }}-product"
```
}%}
Below is an example of the *WebApiGateway* application `webapigateway.yaml` file.
{%{
```diff
apiVersion: apps/v1
kind: Deployment
metadata:
name: "{{ .Release.Name }}-{{ .Chart.Name }}"
spec:
selector:
matchLabels:
app: "{{ .Release.Name }}-{{ .Chart.Name }}"
template:
metadata:
labels:
app: "{{ .Release.Name }}-{{ .Chart.Name }}"
spec:
containers:
- image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
imagePullPolicy: "{{ .Values.image.pullPolicy }}"
name: "{{ .Release.Name }}-{{ .Chart.Name }}"
ports:
- name: "http"
containerPort: 80
env:
...
+ - name: "ReverseProxy__Clusters__Product__Destinations__Product__Address"
+ value: "http://{{ .Release.Name }}-product"
```
}%}
@ -465,11 +593,11 @@ You can customize the microservice template if needed. Add new configurations, d
After adding the new microservice to the solution, you can develop the UI for the new microservice. For .NET applications, you can add the microservice *Contracts* package to the UI application(s) to access the services provided by the new microservice. Afterwards, you can use the [generate-proxy](../../cli/index.md#generate-proxy) command to generate the proxy classes for the new microservice.
```bash
abp generate-proxy -t csharp -url http://localhost:44333/ -m productService --without-contracts
abp generate-proxy -t csharp -url http://localhost:44333/ -m product --without-contracts
```
Next, start creating *Pages* and *Components* for the new microservice in the UI application(s). Similarly, if you have an Angular application, you can use the [generate-proxy](../../cli/index.md#generate-proxy) command to generate the proxy classes for the new microservice and start developing the UI.
```bash
abp generate-proxy -t ng -url http://localhost:44333/ -m productService
abp generate-proxy -t ng -url http://localhost:44333/ -m product
```

BIN
docs/en/solution-templates/microservice/images/folder-structure.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 54 KiB

6
docs/en/studio/overview.md

@ -40,8 +40,9 @@ The top menu is the main menu bar in ABP Studio. It offers access to various fun
### Tools Menu
- **Options**
- **Theme:** Allows to change UI theme.
- **Extensions:** Opens the extension management window.
- **Theme:** Allows to change UI theme.
- **Global secrets**: Allows to add global secrets.
- **Global metadata**: Allows to add global metadata.
### Help Menu
@ -50,6 +51,7 @@ The top menu is the main menu bar in ABP Studio. It offers access to various fun
- **Community:** Opens the official [ABP Community](https://abp.io/community) website in your browser.
- **Support:** Opens the official [Support](https://abp.io/support/questions) website in your browser.
- **My Support Questions:** Opens the page on the official Support website in your browser showing the tickets you have opened.
- **Check for updates:** Checks for new version of ABP Studio.
- **About:** Opens the about window of ABP Studio where you can get more information about it.
## Welcome Screen

91
docs/en/studio/release-notes.md

@ -0,0 +1,91 @@
# ABP Studio Release Notes
This document contains **brief release notes** for each ABP Studio release. Release notes only include **major features** and **visible enhancements**. Therefore, they don't include all the development done in the related version.
## 0.7.9 (2024-08-29)
* Opened Readme.md file after module creation or opening a solution
* Refactor & made enhancements to microservice template
* Fixed some bugs that occur while creating a new module
* Synchronized new templates with the old templates
* Angular: Fixed logo problem in templates
## 0.7.8 (2024-08-23)
* Revised the new solution creation wizard and improved for UX
* Fixed bugs on the Blazor WebApp template
* Reduced logs count per application
## 0.7.7 (2024-08-14)
* Updated LeptonX logos in new templates
* ABP Suite: Opened modules with .sln path instead of directory (fixes some problems in Suite integration)
* Enhancements on Solution Runner
## 0.7.6 (2024-08-12)
* Removed redundant helm repo installation
* Made enhancements to the Welcome Page area
* Microservice Template: Enabled `DynamicPermissionStore` in AuthServer
* Added Blazor WebApp option for Application template
* Added **Solution Creation Info** action for identifying the solution
## 0.7.5 (2024-08-06)
* Fixed ABP Suite integration for macOS
* Fixed build errors after upgrading to ABP 8.2.1
* ABP Suite: Detected version inconsistencies and notified users to fix them automatically
## 0.7.4 (2024-07-31)
* Allowed creating open-source templates for active license owners
* Fixed basic theme problems in angular templates
* Handled docker related errors in solution runner
* Fixed versions of Chat Module packages
## 0.7.3 (2024-07-27)
* Added administrator mode indicator on the application title
* Made enhancements for aligning application title on macOS
## 0.7.2 (2024-07-26)
* Added `Blazor.Client` packages for alignment with new hosting logic
* Updated Microsoft packages to v8.0.4
* Revised application upgrade process
* Fixed profile photo problem in tiered projects
* Removed **LinkedAccounts** and **AuthorityDelegation** menu from templates
## 0.7.1 (2024-07-24)
* Fixed restart problem after installing extensions on macOS
* Provided a model for sharing the same Kubernetes cluster between developers
* Fixed the **Text Template Management** Module build problem in the app template
* Fixed login problem for the community edition
* Fixed all reported bugs & made enhancements
## 0.7.0 (2024-07-17)
* Added an option for building & starting C# applications directly
* Disabled redis on migrator when the solution is tiered
* Allowed Generating Static Proxies on ABP Studio UI
## 0.6.9 (2024-06-27)
* Allowed to open ABP Studio by clicking on a `*.abpsln` file
* Fixed solution runner multiple instance problem
* Allowed to install an NPM package to a package
## 0.6.8 (2024-06-13)
* Added free to pro upgrade option
* Fixed microservice template helm chart bugs
* Made enhancements to the new CLI
## 0.6.7 (2024-05-31)
* Added free option to app templates
* Made social login optional for the app template
* Added open-source (free) templates
* Started showing angular projects on the browser tab
* Introduced the Community Edition

16
docs/en/tutorials/todo/layered/index.md

@ -3,7 +3,7 @@
````json
//[doc-params]
{
"UI": ["MVC", "Blazor", "BlazorServer", "NG"],
"UI": ["MVC", "Blazor", "BlazorServer", "BlazorWebApp" ,"NG"],
"DB": ["EF", "Mongo"]
}
````
@ -148,6 +148,10 @@ Ensure the `TodoApp.HttpApi.Host` project is the startup project, then run the a
You can explore and test your HTTP API with this UI. Now, we can set the `TodoApp.Blazor` as the startup project and run it to open the actual Blazor application UI:
{{else if UI=="BlazorWebApp" }}
It is good to run the application before starting the development. Ensure the `TodoApp.Blazor` project is the startup project, then run the application (Ctrl+F5 in Visual Studio) to see the initial UI:
{{else if UI=="NG"}}
It is good to run the application before starting the development. The solution has two main applications:
@ -252,7 +256,7 @@ You can apply changes to the database using the following command, in the same c
dotnet ef database update
```
> If you are using Visual Studio, you may want to use the `Add-Migration Added_TodoItem` and `Update-Database` commands in the *Package Manager Console (PMC)*. In this case, ensure that {{if UI=="MVC"}}`TodoApp.Web`{{else if UI=="BlazorServer"}}`TodoApp.Blazor`{{else if UI=="Blazor" || UI=="NG"}}`TodoApp.HttpApi.Host`{{end}} is the startup project and `TodoApp.EntityFrameworkCore` is the *Default Project* in PMC.
> If you are using Visual Studio, you may want to use the `Add-Migration Added_TodoItem` and `Update-Database` commands in the *Package Manager Console (PMC)*. In this case, ensure that {{if UI=="MVC"}}`TodoApp.Web`{{else if UI=="BlazorServer" || UI=="Blazor" || UI=="BlazorWebApp"}}`TodoApp.Blazor`{{else if UI=="Blazor" || UI=="NG"}}`TodoApp.HttpApi.Host`{{end}} is the startup project and `TodoApp.EntityFrameworkCore` is the *Default Project* in PMC.
{{else if DB=="Mongo"}}
@ -581,11 +585,11 @@ If you open the [Swagger UI](https://swagger.io/tools/swagger-ui/) by entering t
![todo-api](../images/todo-api.png)
{{else if UI=="Blazor" || UI=="BlazorServer"}}
{{else if UI=="Blazor" || UI=="BlazorServer" || UI=="BlazorWebApp"}}
### Index.razor.cs
Open the `Index.razor.cs` file in the `Pages` folder of the *TodoApp.Blazor* project and replace the content with the following code block:
Open the `Index.razor.cs` file in the `Pages` folder of the {{if UI=="BlazorWebApp"}} *TodoApp.Blazor.Client* {{else}}*TodoApp.Blazor*{{end}} project and replace the content with the following code block:
```csharp
using Microsoft.AspNetCore.Components;
@ -634,7 +638,7 @@ See the *Dynamic C# Proxies & Auto API Controllers* section below to learn how w
### Index.razor
Open the `Index.razor` file in the `Pages` folder of the *TodoApp.Blazor* project and replace the content with the following code block:
Open the `Index.razor` file in the `Pages` folder of the {{if UI=="BlazorWebApp"}} *TodoApp.Blazor.Client* {{else}} *TodoApp.Blazor* {{end}} project and replace the content with the following code block:
```xml
@page "/"
@ -676,7 +680,7 @@ Open the `Index.razor` file in the `Pages` folder of the *TodoApp.Blazor* projec
### Index.razor.css
As the final touch, open the `Index.razor.css` file in the `Pages` folder of the *TodoApp.Blazor* project and replace it with the following content:
As the final touch, open the `Index.razor.css` file in the `Pages` folder of the {{if UI=="BlazorWebApp"}}*TodoApp.Blazor.Client*{{else}}*TodoApp.Blazor*{{end}} project and replace it with the following content:
```css
#TodoList{

2
modules/blogging/src/Volo.Blogging.Application/Volo/Blogging/Posts/PostAppService.cs

@ -308,7 +308,7 @@ namespace Volo.Blogging.Posts
foreach (var newTag in newTags)
{
var tag = tags.FirstOrDefault(t => t.Name == newTag);
var tag = tags.FirstOrDefault(t => t.Name.Equals(newTag, StringComparison.OrdinalIgnoreCase));
if (tag == null)
{

7
modules/openiddict/src/Volo.Abp.OpenIddict.AspNetCore/Microsoft/Extensions/DependencyInjection/OpenIddictServerBuilderExtensions.cs

@ -5,14 +5,17 @@ namespace Microsoft.Extensions.DependencyInjection;
public static class OpenIddictServerBuilderExtensions
{
public static OpenIddictServerBuilder AddProductionEncryptionAndSigningCertificate(this OpenIddictServerBuilder builder, string fileName, string passPhrase)
public static OpenIddictServerBuilder AddProductionEncryptionAndSigningCertificate(this OpenIddictServerBuilder builder, string fileName, string passPhrase, X509KeyStorageFlags? flag = null)
{
if (!File.Exists(fileName))
{
throw new FileNotFoundException($"Signing Certificate couldn't found: {fileName}");
}
var certificate = new X509Certificate2(fileName, passPhrase);
var certificate = flag != null
? new X509Certificate2(fileName, passPhrase, flag.Value)
: new X509Certificate2(fileName, passPhrase);
builder.AddSigningCertificate(certificate);
builder.AddEncryptionCertificate(certificate);
return builder;

16
npm/ng-packs/packages/core/src/lib/utils/generator-utils.ts

@ -1,3 +1,7 @@
import { Injector } from '@angular/core';
import { ABP } from '../models';
import { ConfigStateService } from '../services';
export function uuid(a?: any): string {
return a
? (a ^ ((Math.random() * 16) >> (a / 4))).toString(16)
@ -16,7 +20,11 @@ export function generateHash(value: string): number {
return hashed;
}
export function generatePassword(length = 8) {
export function generatePassword(injector?: Injector, length = 8) {
if (injector) {
length = getRequiredPasswordLength(injector);
}
length = Math.min(Math.max(4, length), 128);
const lowers = 'abcdefghjkmnpqrstuvwxyz';
@ -39,3 +47,9 @@ export function generatePassword(length = 8) {
return password.sort(() => 0.5 - Math.random()).join('');
}
function getRequiredPasswordLength(injector: Injector) {
const configState = injector.get(ConfigStateService);
const passwordRules: ABP.Dictionary<string> = configState.getSettings('Identity.Password');
return Number(passwordRules['Abp.Identity.Password.RequiredLength']) || 8;
}

8
npm/ng-packs/packages/theme-basic/src/lib/components/nav-items/current-user.component.html

@ -56,9 +56,7 @@
</div>
</div>
} @else {
<ng-template #loginBtn>
<a role="button" class="nav-link pointer" (click)="navigateToLogin()">{{
'AbpAccount::Login' | abpLocalization
}}</a>
</ng-template>
<a role="button" class="nav-link pointer" (click)="navigateToLogin()">
{{ 'AbpAccount::Login' | abpLocalization }}
</a>
}

Loading…
Cancel
Save