Skip to content

Commit

Permalink
More links for @path
Browse files Browse the repository at this point in the history
  • Loading branch information
chgeo committed Jan 15, 2024
1 parent 8913d57 commit b2da488
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 2 additions & 0 deletions cds/cdl.md
Original file line number Diff line number Diff line change
Expand Up @@ -1492,6 +1492,8 @@ The endpoint of the exposed service is constructed by its name, following some c
service SomeService { ... }
```

Learn more about [`@path` in Node.js](../node.js/cds-serve#cds-protocols) and in [Java](../java/application-services#configure-path-and-protocol).


### Exposed Entities

Expand Down
4 changes: 2 additions & 2 deletions node.js/cds-serve.md
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ This uses these defaults for all options:
| <i>&#8627;</i>.from | models to load definitions from | `'./srv'` folder
| <i>&#8627;</i>.in | express app to mount to | — none —
| <i>&#8627;</i>.to | client protocol to serve to | `'fiori'`
| <i>&#8627;</i>.at | endpoint path to serve at | `@path` or `.name`
| <i>&#8627;</i>.at | endpoint path to serve at | [`@path`](#path) or `.name`
| <i>&#8627;</i>.with | implementation function | `@impl` or `._source`.js

Alternatively you can construct services individually, also from other models, and also mount them yourself, as document in the subsequent sections on individual fluent API options.
Expand Down Expand Up @@ -144,7 +144,7 @@ cds.serve('CatalogService').at('/cat')
cds.serve('all').at('/cat') //> error
```

**If omitted**, the mount point is determined from annotation `@path`, if present, or from the service's lowercase name, excluding trailing _Service_.
**If omitted**, the mount point is determined from annotation [`@path`](#path), if present, or from the service's lowercase name, excluding trailing _Service_.

```cds
service MyService @(path:'/cat'){...} //> served at: /cat
Expand Down

0 comments on commit b2da488

Please sign in to comment.