Skip to content
This repository was archived by the owner on Feb 6, 2025. It is now read-only.

Commit fd1284e

Browse files
authored
Merge branch 'main' into docs/authentication-entity-net-updates
2 parents 80e938c + 5a55629 commit fd1284e

16 files changed

+61
-39
lines changed

docs/concepts/event-driven-architecture.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ For a step-by-step guide on building an event-driven application with Amplicatio
4545

4646
## Step 1: Create a Message Broker
4747

48-
In your Amplication project, navigate to "Add Resource" and select "[Message Broker](/how-to/create-message-broker)". This will lead you to the Message Broker Creation Wizard.
48+
In your Amplication project, navigate to "Add Resource" and select "[Message Broker](/guides/message-broker)". This will lead you to the Message Broker Creation Wizard.
4949

5050
After creating the message broker, you'll be able to configure the settings by installing and configuring the appropriate [message broker plugin](#supported-message-brokers).
5151

docs/getting-started/plugins.md

+2-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,8 @@ pagination_prev: getting-started/community-plugins
1010

1111
Amplication uses _Plugins_ to extend the functionality of your generated service. These software additions allow developers to customize the default behavior of [Amplication's code generation process](/plugins/plugin-architecture/), providing hooks into various stages of service creation.
1212

13-
Amplication offers a wide range of community-created plugins that are open-source and available on GitHub. You also have the flexibility to develop your own [custom plugins](/plugins/overview/) so you can tailor your generated service to meet your exact requirements.
13+
Amplication offers a wide range of community plugins that are open-source and available on GitHub.
14+
You can also [develop your own private plugins](/private-plugins/) and [community plugins](/plugins/overview/) to extend Amplication's functionality and have it meet your exact requirements.
1415

1516
You can enable certain plugins when you first create your service.
1617
For example, if you choose MySQL as your database, the _MySQL DB_ plugin will be enabled.

docs/how-to/authentication-plugin-examples.mdx

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: Authentication Plugin Guide
33
sidebar_label: Authentication Plugin Guide
4-
slug: /plugins/guides/authentication
4+
slug: /guides/authentication
55
pagination_next: getting-started/authentication
66
---
77

docs/how-to/choose-configure-update-database.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ id: choose-configure-update-database
33
title: How To Choose, Configure, and Update Your Database
44
description: Learn how to choose, configure, and update your Amplication database using plugins.
55
sidebar_label: Database Plugin Guide
6-
slug: /plugins/guides/database
6+
slug: /guides/database
77
---
88

99
# How To Choose, Configure, and Update Your Database

docs/how-to/create-message-broker.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
id: create-message-broker
33
title: How to create a message broker
44
sidebar_label: Create a Message Broker
5-
slug: /how-to/create-message-broker
5+
slug: /guides/message-broker
66
---
77

88
# Create a message broker

docs/how-to/index.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,6 @@ Whether you are a beginner just starting with Amplication or an experienced deve
1818
- [Entity Relations](/relations/)
1919
- [Base Directories](/how-to/base-directories)
2020
- [Configure selective code generation](/how-to/api-admin-ui-settings/)
21-
- [Create a message broker](/how-to/create-message-broker)
21+
- [Create a message broker](/guides/message-broker)
2222

2323
Browse through the available tutorials and start building your web app with Amplication.

docs/plugins/define-plugin-settings.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
id: define-plugin-settings
33
title: How To Define Plugin Settings
4-
sidebar_label: How To Define Plugin Settings
4+
sidebar_label: Define Plugin Settings
55
slug: /plugins/define-plugin-settings
66
---
77

docs/plugins/developing-a-plugin.md

+4-5
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,13 @@
11
---
22
id: how-to-create-plugin
3-
title: How to Create a Custom Plugin
4-
sidebar_label: How to Create a Custom Plugin
3+
title: How to Develop a Plugin
4+
sidebar_label: Develop a Plugin
55
slug: /plugins/how-to-create-plugin
66
---
77

8-
Amplication includes several plugins - some allow you to choose an authentication strategy, some allow you to choose which database you want to integrate with and one allows you to connect your service to a message broker.
8+
### Pre-requisites
99

10-
### Planning and POC:
11-
Before any development of a plugin, we take the following steps:
10+
Before the development of a plugin, take the following steps:
1211

1312
1. Generate a service with Amplication
1413
2. Apply the changes that we need:

docs/plugins/event-hierarchy.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
---
22
id: event-hierarchy
3-
title: Event Hierarchy
4-
sidebar_label: Event Hierarchy
3+
title: Plugin Event Hierarchy
4+
sidebar_label: Plugin Event Hierarchy
55
slug: /plugins/event-hierarchy
66
---
77

8-
# Event Hierarchy
8+
# Plugin Event Hierarchy
99

1010
We have two main event hierarchies in our Data Service Generator (DSG) service: one for Node.js services and one for .NET services. Each of these hierarchies includes events to create the server's files and, in the case of Node.js, the admin-ui files.
1111

docs/plugins/plugin-architecture.md

+12-3
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
id: plugin-architecture
3-
title: Plugin Architecture Overview
4-
sidebar_label: Custom Plugin Architecture
3+
title: Plugin Architecture
4+
sidebar_label: Plugin Architecture
55
slug: /plugins/plugin-architecture
66
---
77

@@ -15,7 +15,16 @@ The `pluginWrapper` function is invoked with the following arguments:
1515
- **event** - the name of event we want to capture, and change something in the triggered process.
1616
- **args** - the original parameters of the DSG function. These are likely to be used as the parameters of the event, for the plugin developer to have access to these params and manipulate the returned value of the function.
1717

18-
For the purpose of this architecture overview, remember that every event has before and after property (which is a function), representing the event's lifecycle in which you can intervene (before the emission of the event and after the emission of the event). For more information about `before` and `after` event see [Before and After Lifecycle Functions](docs\plugins\before-after.md)
18+
## Event Lifecycle
19+
20+
Each plugin event supports two execution points:
21+
22+
- `before`: Executes before the main event processing
23+
- `after`: Executes after the main event processing
24+
25+
These lifecycle hooks allow precise control over the code generation process.
26+
27+
For more information about `before` and `after` event see [Before and After Lifecycle Functions](docs\plugins\before-after.md)
1928

2029
When the `pluginWrapper` function is invoked, it checks whether the event argument that was passed has a `before` or `after` property. If so, it invokes other functions that are responsible for calculating the final behavior when this event is emitted, or in other words, the outcome of the function that this event is responsible to execute.
2130

docs/plugins/plugindev-overview.md

+2-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,8 @@ pagination_prev: plugins/event-hierarchy
99

1010
# Plugin Development Overview
1111

12-
A plugin is a custom code that extends Amplication developer platform with new features. The features incorporated can be generic, useful to a wide variety of users, or can be very specific to deal with specialized requirements.
12+
A plugin is code that extends the Amplication developer platform by adding new features or modifying existing functionality.
13+
The features incorporated can be generic, useful to a wide variety of users, or can be very specific to deal with specialized requirements.
1314

1415
If you or your organization have a specific workflow, install an existing plugin or write one to customize the platform to perform your required tasks.
1516

docs/plugins/private-plugins.md

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
11
---
22
id: private-plugins
3+
sidebar_label: Private Plugins
34
slug: /private-plugins
45
toc_max_heading_level: 2
56
---
67

7-
# Creating and Using Private Plugins
8+
# Private Plugins
89

910
Private Plugins enable you to create plugins exclusively for your organization's use.
1011
These plugins let you build secure, proprietary integrations and define your organization's standards. You can use them to protect sensitive business logic and enforce development best practices across your services.

docs/plugins/publish-your-plugin.md

+6-2
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,15 @@
11
---
22
id: publish-plugin
3-
title: How To Publish a Custom Plugin
4-
sidebar_label: How To Publish a Custom Plugin
3+
title: How To Publish a Plugin
4+
sidebar_label: Publish a Plugin
55
description: Learn how to publish your Amplication plugin.
66
slug: /plugins/publish-plugin
77
---
88

9+
:::info
10+
These steps are for publishing a publicly available [community plugin](/getting-started/plugins/). For information on releasing private plugins, see the [Private Plugins](/private-plugins/) page.
11+
:::
12+
913
Step 1. Create the Plugin
1014

1115
Step 2. Publish the Plugin in NPM. For details, see [NPM documentation](https://docs.npmjs.com/cli/v6/commands/npm-publish)

docs/plugins/testing-a-plugin.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
id: how-to-test-plugin
3-
title: How to Test a Custom Plugin
4-
sidebar_label: How to Test a Custom Plugin
3+
title: How to Test a Plugin
4+
sidebar_label: Test a Plugin
55
slug: /plugins/how-to-test-plugin
66
---
77

docusaurus.config.js

+9-1
Original file line numberDiff line numberDiff line change
@@ -199,7 +199,15 @@ module.exports = {
199199
{
200200
redirects: [
201201
{
202-
to: "/plugins/guides/authentication",
202+
to: "/guides/database",
203+
from: ["/plugins/guides/database/"]
204+
},
205+
{
206+
to: "/guides/message-broker",
207+
from: ["/how-to/create-message-broker"]
208+
},
209+
{
210+
to: "/guides/authentication",
203211
from: ["/authentication-plugin-examples"]
204212
},
205213
{

sidebars.js

+13-14
Original file line numberDiff line numberDiff line change
@@ -184,33 +184,23 @@ const sidebars = {
184184
"getting-started/plugins",
185185
"getting-started/community-plugins",
186186
"plugins/dotnet-plugins",
187-
{
188-
type: "category",
189-
label: "Plugin Guides",
190-
items: [
191-
"how-to/choose-configure-update-database",
192-
"how-to/authentication-plugin-examples",
193-
"how-to/create-message-broker",
194-
]
195-
},
196187
{
197188
type: "category",
198-
label: "Custom Plugins",
189+
label: "Plugin Development",
199190
link: {
200191
type:"doc",
201192
id: "plugins/overview"
202193
},
203194
items: [
204195
"plugins/overview",
205196
"plugins/plugin-architecture",
197+
"plugins/event-hierarchy",
198+
"plugins/plugin-events-before-after",
199+
"plugins/context-skip-default",
206200
"plugins/how-to-create-plugin",
207201
"plugins/define-plugin-settings",
208202
"plugins/how-to-test-plugin",
209203
"plugins/publish-plugin",
210-
"plugins/private-plugins",
211-
"plugins/plugin-events-before-after",
212-
"plugins/context-skip-default",
213-
"plugins/event-hierarchy",
214204
{
215205
type: "category",
216206
label: ".NET Plugin Events - Reference",
@@ -281,6 +271,15 @@ const sidebars = {
281271
items: [
282272
"tutorials/index",
283273
"tutorials/community-tutorials",
274+
{
275+
type: "category",
276+
label: "Guides",
277+
items: [
278+
"how-to/choose-configure-update-database",
279+
"how-to/authentication-plugin-examples",
280+
"how-to/create-message-broker",
281+
]
282+
},
284283
{
285284
type: "link",
286285
label: "Developer Tutorials",

0 commit comments

Comments
 (0)