Skip to content

Commit 5c31459

Browse files
authored
Merge branch 'main' into d040506_dev_dashboard
2 parents a6cfd4d + a024a0e commit 5c31459

File tree

7 files changed

+30
-11
lines changed

7 files changed

+30
-11
lines changed

about/features.md

+1-3
Original file line numberDiff line numberDiff line change
@@ -181,13 +181,11 @@ Following is an index of the features currently covered by CAP, with status and
181181
| [Declared Events in CDS](../cds/cdl#events) | <X/> | <X/> | <X/> |
182182
| Mock Broker (to speed up local dev) [[Node.js](../node.js/messaging#file-based)\|[Java](../java/messaging#local-testing)] | <Na/> | <X/> | <X/> |
183183
| SAP Event Mesh (For single-tenant apps) [[Node.js](../node.js/messaging#event-mesh-shared)\|[Java](../java/messaging#configuring-sap-event-mesh-support)] | <Na/> | <X/> | <X/> |
184-
| SAP Event Broker (For single-tenant apps) [[Node.js](../node.js/messaging#event-broker)] | <Na/> | <X/><br>beta<sup>1</sup> | <D/> |
184+
| SAP Event Broker (For single-tenant apps) [[Node.js](../node.js/messaging#event-broker)] | <Na/> | <X/><br>beta | <D/> |
185185
| Composite Messaging (routing by configuration) [[Node.js](../node.js/messaging#composite-messaging)\|[Java](../java/messaging#composite-messaging-service)] | <Na/> | <X/> | <X/> |
186186
| Import AsyncAPI | <O/> | | |
187187
| Export AsyncAPI | <X/> | | |
188188

189-
> <sup>1</sup> May be outsourced into a plugin, hence the status _beta_. <br>
190-
191189
<span id="events-messaging-more" />
192190

193191
### Database Support

about/index.md

+2-1
Original file line numberDiff line numberDiff line change
@@ -461,7 +461,8 @@ Following is an excerpt of generic features provided:
461461
- [Open Telementry → SAP Cloud Logging, Dynatrace, ...](../plugins/#telemetry)
462462
- [Attachments → SAP Object Store](../plugins/#attachments)
463463
- [Attachments → SAP Document Management Service](../plugins/#@cap-js/sdm)
464-
- [Messaging → SAP Event Broker](../plugins/#event-broker)
464+
- [Messaging → SAP Event Broker](../plugins/#event-broker-plugin)
465+
- [Messaging → SAP Event Broker (Multitenancy)](../plugins/#event-broker-multitenancy)
465466
- [Messaging → Kafka](../plugins/#apache-kafka)
466467
- [Change Tracking](../plugins/#change-tracking)
467468
- [Notifications](../plugins/#notifications)

guides/messaging/event-broker.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ Configure your application to use the `event-broker` messaging service.
7171
[Learn more about `cds.env` profiles](../../node.js/cds-env#profiles){.learn-more}
7272

7373
::: tip Local Testing
74-
Since SAP Event Broker sends events via HTTP, local
74+
Since SAP Event Broker sends events via HTTP, you won't be able to receive events on your local machine unless you use a tunneling service. Therefore we recommend to use a messaging service of kind [`local-messaging`](../../node.js/messaging#local-messaging) for local testing.
7575
:::
7676

7777

guides/messaging/index.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@ The message payload is in the `data` property of the inbound `msg` object.
192192

193193

194194
::: tip
195-
To have more control over imported service definitions, you can set the `model` configuration of your external service to a cds file where you define the external service and only use the imported definitions your app needs. This way, plugins like [Open Resource Discovery (ORD)](/plugins/#ord-open-resource-discovery) know which parts of the external service you actually use in your application.
195+
To have more control over imported service definitions, you can set the `model` configuration of your external service to a cds file where you define the external service and only use the imported definitions your app needs. This way, plugins like [Open Resource Discovery (ORD)](../../plugins/#ord-open-resource-discovery) know which parts of the external service you actually use in your application.
196196
:::
197197

198198

menu.md

+1
Original file line numberDiff line numberDiff line change
@@ -226,3 +226,4 @@
226226
- [Telemetry](plugins/#telemetry)
227227
- [Open Resource Discovery](plugins/#ord-open-resource-discovery)
228228
- [CAP Operator for K8s](plugins/#cap-operator-plugin)
229+
- [SAP Event Broker](plugins/#event-broker-plugin)

node.js/messaging.md

+8-5
Original file line numberDiff line numberDiff line change
@@ -405,13 +405,14 @@ If you enable the [cors middleware](https://www.npmjs.com/package/cors), [handsh
405405

406406
Use this if you want to communicate using [SAP Event Broker](https://help.sap.com/docs/event-broker).
407407

408-
You need to install the package [`@cap-js/event-broker`](https://github.com/cap-js/event-broker).
408+
The integration with SAP Event Broker is provided using the plugin [`@cap-js/event-broker`](https://github.com/cap-js/event-broker).
409+
Hence, you first need to install the plugin:
409410

410411
```bash
411-
npm install @cap-js/event-broker
412+
npm add @cap-js/event-broker
412413
```
413414

414-
Set the `kind` of your messaging service to `event-broker`:
415+
Then, set the `kind` of your messaging service to `event-broker`:
415416

416417
```jsonc
417418
"cds": {
@@ -444,9 +445,10 @@ If you are not using [IAS-based Authentication](./authentication#ias), you will
444445

445446
Your SAP Event Broker configuration must include your system namespace as well as the webhook URL. The binding parameters must set `"authentication-type": "X509_GENERATED"` to allow IAS-based authentication.
446447
Your IAS instance must be configured to include your SAP Event Broker instance under `consumed-services` in order for your application to accept requests from SAP Event Broker.
447-
Here's an example configuration based of the mta.yaml file of the [@capire/incidents](https://github.com/cap-js/incidents-app/tree/event-broker) application, bringing it all together:
448+
Here's an example configuration based on the _mta.yaml_ file of the [@capire/incidents](https://github.com/cap-js/incidents-app/tree/event-broker) application, bringing it all together:
448449

449-
```yaml
450+
::: code-group
451+
```yaml [mta.yaml]
450452
ID: cap.incidents
451453

452454
modules:
@@ -496,6 +498,7 @@ resources:
496498
display-name: cap.incidents #> any value, e.g., reuse MTA ID
497499
home-url: ~{incidents-srv-api/url}
498500
```
501+
:::
499502
500503
501504
<div id="aftereventbroker" />

plugins/index.md

+16
Original file line numberDiff line numberDiff line change
@@ -346,6 +346,22 @@ Available for:
346346
![Java logo](../assets/logos/java.svg){style="height:3em; display:inline; margin:0 0.2em;"}
347347

348348

349+
## SAP Event Broker {#event-broker-plugin}
350+
351+
The plugin provides out-of-the-box support for consuming events from [SAP Event Broker](https://discovery-center.cloud.sap/serviceCatalog/sap-event-broker) -- for example emitted by SAP S/4HANA Cloud -- in stand-alone CAP applications.
352+
353+
```js
354+
const S4Bupa = await cds.connect.to ('API_BUSINESS_PARTNER')
355+
S4bupa.on ('BusinessPartner.Changed', msg => {...})
356+
```
357+
358+
For more details, please see [Events and Messaging &rarr; Using SAP Event Broker](../guides/messaging/#sap-event-broker).
359+
360+
Available for:
361+
362+
[![Node.js](../assets/logos/nodejs.svg 'Link to the plugins repository.'){style="height:2.5em; display:inline; margin:0 0.2em;"}](https://github.com/cap-js/event-broker#readme)
363+
364+
349365
<div id="internal-plugins" />
350366

351367
<div id="upcoming-plugins" />

0 commit comments

Comments
 (0)