Skip to content

Commit 2e1e219

Browse files
authored
Merge branch 'master' into master
2 parents 684c6d8 + d41ccc8 commit 2e1e219

File tree

5 files changed

+89
-90
lines changed

5 files changed

+89
-90
lines changed

config/newsroom_videos.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,10 @@
11
[
2+
{
3+
"image_url": "https://i.ytimg.com/vi/awfB_mwUp1c/hqdefault.jpg",
4+
"title": "Event-Driven and OpenTelemetry with Eduardo",
5+
"description": "Implementing distributed tracing between producers and consumers.",
6+
"videoId": "awfB_mwUp1c"
7+
},
28
{
39
"image_url": "https://i.ytimg.com/vi/e_uo7_QMDd4/hqdefault.jpg",
410
"title": "AsyncAPI Community Working Group Meeting, March 11th 2025",
@@ -22,11 +28,5 @@
2228
"title": "AsyncAPI Marketing Working Group Meeting",
2329
"description": "https://github.com/asyncapi/community/issues/1705.",
2430
"videoId": "gfKAcJthEGk"
25-
},
26-
{
27-
"image_url": "https://i.ytimg.com/vi/awfB_mwUp1c/hqdefault.jpg",
28-
"title": "Event-Driven and OpenTelemetry with Eduardo",
29-
"description": "Implementing distributed tracing between producers and consumers.",
30-
"videoId": "awfB_mwUp1c"
3131
}
3232
]

dashboard.json

Lines changed: 44 additions & 64 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
"resourcePath": "/asyncapi/community/pull/1634",
1010
"repo": "asyncapi/community",
1111
"labels": [],
12-
"score": 28.717458874925875
12+
"score": 31.302030173669205
1313
},
1414
{
1515
"id": "I_kwDOBW5R_c5BIl5P",
@@ -85,7 +85,7 @@
8585
"resourcePath": "/asyncapi/website/pull/3726",
8686
"repo": "asyncapi/website",
8787
"labels": [],
88-
"score": 14.645904026212197
88+
"score": 15.220253203710714
8989
},
9090
{
9191
"id": "I_kwDODou01c5ZAFWh",
@@ -107,17 +107,6 @@
107107
],
108108
"score": 14.07155484871368
109109
},
110-
{
111-
"id": "I_kwDOFLhIt85xI2wH",
112-
"isPR": false,
113-
"isAssigned": false,
114-
"title": "Measure AsyncAPI Adoption",
115-
"author": "fmvilas",
116-
"resourcePath": "/asyncapi/community/issues/879",
117-
"repo": "asyncapi/community",
118-
"labels": [],
119-
"score": 12.922856493716644
120-
},
121110
{
122111
"id": "I_kwDOFLhIt86O7jFN",
123112
"isPR": false,
@@ -140,7 +129,42 @@
140129
"color": "0d67d3"
141130
}
142131
],
143-
"score": 12.635681904967385
132+
"score": 13.210031082465903
133+
},
134+
{
135+
"id": "I_kwDOFLhIt85xI2wH",
136+
"isPR": false,
137+
"isAssigned": false,
138+
"title": "Measure AsyncAPI Adoption",
139+
"author": "fmvilas",
140+
"resourcePath": "/asyncapi/community/issues/879",
141+
"repo": "asyncapi/community",
142+
"labels": [],
143+
"score": 12.922856493716644
144+
},
145+
{
146+
"id": "I_kwDOFLhIt86sh4Es",
147+
"isPR": false,
148+
"isAssigned": false,
149+
"title": "Donation of `Neuroglia.AsyncAPI`",
150+
"author": "derberg",
151+
"resourcePath": "/asyncapi/community/issues/1764",
152+
"repo": "asyncapi/community",
153+
"labels": [
154+
{
155+
"name": "vote",
156+
"color": "EF813F"
157+
},
158+
{
159+
"name": "gitvote",
160+
"color": "ededed"
161+
},
162+
{
163+
"name": "vote open",
164+
"color": "ededed"
165+
}
166+
],
167+
"score": 12.348507316218127
144168
},
145169
{
146170
"id": "I_kwDOBW5R_c6pn_G2",
@@ -173,47 +197,18 @@
173197
}
174198
],
175199
"score": 12.348507316218127
176-
},
177-
{
178-
"id": "I_kwDOFLhIt86sh4Es",
179-
"isPR": false,
180-
"isAssigned": false,
181-
"title": "Donation of `Neuroglia.AsyncAPI`",
182-
"author": "derberg",
183-
"resourcePath": "/asyncapi/community/issues/1764",
184-
"repo": "asyncapi/community",
185-
"labels": [
186-
{
187-
"name": "vote",
188-
"color": "EF813F"
189-
},
190-
{
191-
"name": "gitvote",
192-
"color": "ededed"
193-
},
194-
{
195-
"name": "vote open",
196-
"color": "ededed"
197-
}
198-
],
199-
"score": 10.625459783722574
200200
}
201201
],
202202
"goodFirstIssues": [
203203
{
204-
"id": "I_kwDOFDnrNc6tb2y1",
205-
"title": "[BUG] A YAML file is being generated instead of a JSON file when using the asyncapi new file command for generating JSON file",
204+
"id": "I_kwDODwv8N86tpo_O",
205+
"title": "Remove \"All rights reserved and the Copyright symbol\"",
206206
"isAssigned": false,
207-
"resourcePath": "/asyncapi/cli/issues/1710",
208-
"repo": "asyncapi/cli",
209-
"author": "Sumitwarrior7",
207+
"resourcePath": "/asyncapi/conference-website/issues/620",
208+
"repo": "asyncapi/conference-website",
209+
"author": "thulieblack",
210210
"area": "Unknown",
211-
"labels": [
212-
{
213-
"name": "bug",
214-
"color": "d73a4a"
215-
}
216-
]
211+
"labels": []
217212
},
218213
{
219214
"id": "I_kwDOFDnrNc6tHvh5",
@@ -389,21 +384,6 @@
389384
}
390385
]
391386
},
392-
{
393-
"id": "I_kwDOFLhIt86ihL5I",
394-
"title": "[BUG] voting summary has some errors in `isVotedInLast3Months`",
395-
"isAssigned": false,
396-
"resourcePath": "/asyncapi/community/issues/1614",
397-
"repo": "asyncapi/community",
398-
"author": "derberg",
399-
"area": "javascript",
400-
"labels": [
401-
{
402-
"name": "bug",
403-
"color": "d73a4a"
404-
}
405-
]
406-
},
407387
{
408388
"id": "I_kwDODwv8N86f37o-",
409389
"title": "Return to top arrow feature/button",

markdown/docs/tools/generator/generator-template.md

Lines changed: 34 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ Here's what is contained in the code snippet above:
122122
- **supportedProtocols** - A list that specifies which protocols are supported by your template.
123123
- **dependencies** - specifies which version of [`@asyncapi/generator-react-sdk`](https://github.com/asyncapi/generator-react-sdk) should be used.
124124

125-
Navigate to the ****python-mqtt-client-template** directory. Run the command `npm install` on your terminal to install the dependencies specified in **package.json**.
125+
Navigate to the **python-mqtt-client-template** directory. Run the command `npm install` on your terminal to install the dependencies specified in **package.json**.
126126

127127
### index.js file
128128

@@ -258,7 +258,7 @@ while True:
258258
259259
```
260260

261-
Run the code above in your terminal using the command `python test.py`. You should see output similar to the snippet below logged on your terminal:
261+
Navigate to the **python-mqtt-client-template/test/project** directory. Run the command `python test.py` on your terminal. You should see output similar to the snippet below logged on your terminal:
262262

263263
``` cmd
264264
New temperature detected 64250266 sent to temperature/changed
@@ -298,18 +298,35 @@ class TemperatureServiceClient:
298298

299299
### 4. Write script to run the test code
300300

301-
In **package.json** you can have the scripts property that you invoke by calling `npm run <your_script>`. Add these scripts to **package.json**:
301+
In **package.json** you can have the scripts property that you invoke by calling `npm run <your_script>`. After adding these scripts in **package.json**, it will look like the following code snippet:
302302

303303
``` json
304-
"scripts": {
304+
{
305+
"name": "python-mqtt-client-template",
306+
"version": "0.0.1",
307+
"description": "A template that generates a Python MQTT client using MQTT.",
308+
"scripts": {
305309
"test:clean": "rimraf test/project/client.py",
306310
"test:generate": "asyncapi generate fromTemplate test/fixtures/asyncapi.yml ./ --output test/project --force-write",
307311
"test:start": "python test/project/test.py",
308312
"test": "npm run test:clean && npm run test:generate && npm run test:start"
313+
},
314+
"generator": {
315+
"renderer": "react",
316+
"apiVersion": "v1",
317+
"generator": ">=1.10.0 <2.0.0",
318+
"supportedProtocols": ["mqtt"]
319+
},
320+
"dependencies": {
321+
"@asyncapi/generator-react-sdk": "^0.2.25"
322+
},
323+
"devDependencies": {
324+
"rimraf": "^5.0.0"
325+
}
309326
}
310327
```
311328

312-
The 4 scripts above do the following:
329+
The 4 scripts added in **package.json** do the following:
313330

314331
1. `test:clean`: This script uses the `rimraf` package to remove the old version of the file **test/project/client.py** every time you run your test.
315332
2. `test:generate`: This script uses the AsyncAPI CLI to generate a new version of **client.py**.
@@ -469,16 +486,16 @@ It's recommended to put reusable components outside the template directory in a
469486
* As input it requires a list of Channel models from the parsed AsyncAPI document
470487
*/
471488
export function TopicFunction({ channels }) {
472-
const topicsDetails = getTopics(channels)
473-
let functions = ''
489+
const topicsDetails = getTopics(channels);
490+
let functions = '';
474491

475492
topicsDetails.forEach((t) => {
476493
functions += `def send${t.name}(self, id):
477494
topic = "${t.topic}"
478495
self.client.publish(topic, id)\n`
479-
})
496+
});
480497

481-
return functions
498+
return functions;
482499
}
483500

484501
/*
@@ -489,19 +506,19 @@ export function TopicFunction({ channels }) {
489506
* As input it requires a list of Channel models from the parsed AsyncAPI document
490507
*/
491508
function getTopics(channels) {
492-
const channelsCanSendTo = channels
493-
let topicsDetails = []
509+
const channelsCanSendTo = channels;
510+
let topicsDetails = [];
494511

495512
channelsCanSendTo.forEach((ch) => {
496-
const topic = {}
497-
const operationId = ch.operations().filterByReceive()[0].id()
498-
topic.name = operationId.charAt(0).toUpperCase() + operationId.slice(1)
499-
topic.topic = ch.address()
513+
const topic = {};
514+
const operationId = ch.operations().filterByReceive()[0].id();
515+
topic.name = operationId.charAt(0).toUpperCase() + operationId.slice(1);
516+
topic.topic = ch.address();
500517

501-
topicsDetails.push(topic)
518+
topicsDetails.push(topic);
502519
})
503520

504-
return topicsDetails
521+
return topicsDetails;
505522
}
506523
```
507524

markdown/docs/tools/generator/installation-guide.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ You can use the generator library to generate whatever you want in your event-dr
88
- [Generator library in Node.js apps](#generator-library-in-nodejs-apps)
99

1010
## Prerequisites
11-
Before you install and use the AsyncAPI CLI and the generator library, ensure you meet the prerequisites below, then [install the CLI](#installation).
11+
Before you install and use the AsyncAPI CLI and the generator library, ensure you meet the prerequisites below, then [install the CLI](https://www.asyncapi.com/docs/tools/cli/installation).
1212
1. Node.js v18.12.0 or higher
1313
2. Npm v8.19.0 or higher
1414

@@ -27,7 +27,7 @@ If you have the correct versions installed, proceed to the CLI installation guid
2727
## AsyncAPI CLI
2828
The AsyncAPI CLI tool allows you to do many different things with the [AsyncAPI document](asyncapi-document). You can generate message-based API boilerplate code, documentation, or anything else you need as long as you specify it in your [template](template) or the existing template already supports it. To use the generator via the AsyncAPI CLI, you need to install the AsyncAPI CLI tool. For the latest installation instructions, visit the official AsyncAPI CLI [installation guide](https://www.asyncapi.com/docs/tools/cli/installation).
2929

30-
> :memo: **Note:** To use the generator in your CI/CD pipeline to automate whatever you generate for your event-driven architecture apps, install the AsyncAPI CLI in your pipeline. If you are using GitHub Actions, use [Github Actions for Generator](https://github.com/marketplace/actions/generator-for-asyncapi-documents).
30+
> :memo: **Note:** To use the generator in your CI/CD pipeline to automate whatever you generate for your event-driven architecture apps, install the AsyncAPI CLI in your pipeline. If you are using GitHub Actions, use [Github Actions for Generator](https://github.com/marketplace/actions/asyncapi-cli-action).
3131
3232
## Generator library in Node.js apps
3333
Use the generator library in your Node.js projects by installing it via the following command: `npm install @asyncapi/generator`.

markdown/docs/tools/generator/usage.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,12 +94,14 @@ Install [Docker](https://docs.docker.com/get-docker/) first, then use docker to
9494

9595
```bash
9696
docker run --rm -it \
97+
--user=root \
9798
-v [ASYNCAPI SPEC FILE LOCATION]:/app/asyncapi.yml \
9899
-v [GENERATED FILES LOCATION]:/app/output \
99-
asyncapi/cli [COMMAND HERE]
100+
asyncapi/cli # docker image [COMMAND HERE]
100101

101102
# Example that you can run inside the cli directory after cloning this repository. First, you specify the mount in the location of your AsyncAPI specification file and then you mount it in the directory where the generation result should be saved.
102103
docker run --rm -it \
104+
--user=root \
103105
-v ${PWD}/test/fixtures/asyncapi_v1.yml:/app/asyncapi.yml \
104106
-v ${PWD}/output:/app/output \
105107
asyncapi/cli generate fromTemplate -o /app/output /app/asyncapi.yml @asyncapi/[email protected] --use-new-generator --force-write

0 commit comments

Comments
 (0)