-
Notifications
You must be signed in to change notification settings - Fork 115
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
shared-db #1717
base: main
Are you sure you want to change the base?
shared-db #1717
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Linting Errors
- guides/deployment/shared-db.md:86 Fenced code blocks should have a language specified
- guides/deployment/shared-db.md:186 Fenced code blocks should have a language specified
- guides/deployment/shared-db.md:255 Fenced code blocks should have a language specified
- guides/deployment/shared-db.md:415 Fenced code blocks should have a language specified
- guides/deployment/shared-db.md:423 Fenced code blocks should have a language specified
Spelling Mistakes
- guides/deployment/shared-db.md:13:28 Unknown word "microserivces"
- guides/deployment/shared-db.md:38:40 Unknown word "Clound"
- guides/deployment/shared-db.md:56:30 Unknown word "esample"
- guides/deployment/shared-db.md:247:3 Unknown word "Authentification"
- guides/deployment/shared-db.md:287:43 Unknown word "asynchronious"
- guides/deployment/shared-db.md:384:4 Unknown word "authentification"
- guides/deployment/shared-db.md:398:29 Unknown word "earch"
- guides/deployment/shared-db.md:439:23 Unknown word "authentification"
Generally, for each spelling mistake there are 2 ways to fix it:
- Fix the spelling mistake and commit it.
- The word is incorrectly reported as misspelled → put the word on the project-words.txt list, located in the root project directory.
guides/deployment/shared-db.md
Outdated
|
||
- add dependency @cap-js/hana: | ||
|
||
``` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
``` | |
```txt | |
npm i @cap-js/hana --workspace bookstore | |
npm i @cap-js/hana --workspace orders | |
npm i @cap-js/hana --workspace reviews | |
``` |
Please add a language tag. For plain text add txt
as language tag.
guides/deployment/shared-db.md
Outdated
## static content | ||
The approuter can serve also static content (html files). If you want to deploy your WebUIs located in workspaces as static content, you can use Linux sym-links to link the UI-directories in the app-router folder. | ||
|
||
``` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
``` | |
```txt | |
cd app-router | |
ln -s ../bookshop/app/vue bookshop | |
ln -s ../orders/app/orders orders | |
ln -s ../reviews/app/vue reviews | |
cd .. | |
``` |
Please add a language tag. For plain text add txt
as language tag.
guides/deployment/shared-db.md
Outdated
|
||
- CAP service package.json dependency: @sap/xssec | ||
|
||
``` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
``` | |
```txt | |
npm i @sap/xssec --workspace bookstore | |
npm i @sap/xssec --workspace orders | |
npm i @sap/xssec --workspace reviews | |
``` |
Please add a language tag. For plain text add txt
as language tag.
|
||
- (fix) change from *npm-ci* to *npm* builder | ||
|
||
``` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
``` | |
```txt | |
builder: npm | |
``` |
Please add a language tag. For plain text add txt
as language tag.
guides/deployment/shared-db.md
Outdated
|
||
- reviews/db/data/sap.capire.reviews-Reviews.csv | ||
|
||
``` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
``` | |
```txt | |
ID;subject;... | |
1689144d-3b10-4849-bcbe-2408a13e161d;201.... | |
... | |
``` |
Please add a language tag. For plain text add txt
as language tag.
guides/deployment/shared-db.md
Outdated
} | ||
``` | ||
|
||
# Authentification |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
# Authentification | |
# Authentication |
Or maybe one of these: Authentications?
guides/deployment/shared-db.md
Outdated
|
||
# Messaging | ||
|
||
The messaging service is used to organize asynchronious communication between the CAP services. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The messaging service is used to organize asynchronious communication between the CAP services. | |
The messaging service is used to organize asynchronous communication between the CAP services. |
Or maybe one of these: asynchronies, asynchronisms, synchronous, asynchronism?
guides/deployment/shared-db.md
Outdated
``` | ||
# Misc | ||
|
||
## authentification depends on messaging |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
## authentification depends on messaging | |
## authentication depends on messaging |
Or maybe one of these: authentications?
guides/deployment/shared-db.md
Outdated
|
||
File: mta.yaml | ||
|
||
- Duplicate samples-srv for earch CAP service |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- Duplicate samples-srv for earch CAP service | |
- Duplicate samples-srv for each CAP service |
Or maybe one of these: erch, earth, esrch, eparch?
guides/deployment/shared-db.md
Outdated
cds_requires_OrdersService_credentials: {"destination": "orders-dest","path": "/odata/v4/orders"} | ||
``` | ||
|
||
## approuter requires authentification |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
## approuter requires authentification | |
## approuter requires authentication |
Or maybe one of these: authentications?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Linting Errors
- guides/deployment/shared-db.md:90 Fenced code blocks should have a language specified
- guides/deployment/shared-db.md:190 Fenced code blocks should have a language specified
- guides/deployment/shared-db.md:259 Fenced code blocks should have a language specified
- guides/deployment/shared-db.md:419 Fenced code blocks should have a language specified
- guides/deployment/shared-db.md:427 Fenced code blocks should have a language specified
Spelling Mistakes
- guides/deployment/shared-db.md:42:40 Unknown word "Clound"
- guides/deployment/shared-db.md:60:30 Unknown word "esample"
- guides/deployment/shared-db.md:251:3 Unknown word "Authentification"
- guides/deployment/shared-db.md:291:43 Unknown word "asynchronious"
- guides/deployment/shared-db.md:388:4 Unknown word "authentification"
- guides/deployment/shared-db.md:402:29 Unknown word "earch"
- guides/deployment/shared-db.md:443:23 Unknown word "authentification"
Generally, for each spelling mistake there are 2 ways to fix it:
- Fix the spelling mistake and commit it.
- The word is incorrectly reported as misspelled → put the word on the project-words.txt list, located in the root project directory.
guides/deployment/shared-db.md
Outdated
|
||
- add dependency @cap-js/hana: | ||
|
||
``` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
``` | |
```txt | |
npm i @cap-js/hana --workspace bookstore | |
npm i @cap-js/hana --workspace orders | |
npm i @cap-js/hana --workspace reviews | |
``` |
Please add a language tag. For plain text add txt
as language tag.
guides/deployment/shared-db.md
Outdated
## static content | ||
The approuter can serve also static content (html files). If you want to deploy your WebUIs located in workspaces as static content, you can use Linux sym-links to link the UI-directories in the app-router folder. | ||
|
||
``` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
``` | |
```txt | |
cd app-router | |
ln -s ../bookshop/app/vue bookshop | |
ln -s ../orders/app/orders orders | |
ln -s ../reviews/app/vue reviews | |
cd .. | |
``` |
Please add a language tag. For plain text add txt
as language tag.
guides/deployment/shared-db.md
Outdated
|
||
- CAP service package.json dependency: @sap/xssec | ||
|
||
``` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
``` | |
```txt | |
npm i @sap/xssec --workspace bookstore | |
npm i @sap/xssec --workspace orders | |
npm i @sap/xssec --workspace reviews | |
``` |
Please add a language tag. For plain text add txt
as language tag.
|
||
- (fix) change from *npm-ci* to *npm* builder | ||
|
||
``` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
``` | |
```txt | |
builder: npm | |
``` |
Please add a language tag. For plain text add txt
as language tag.
guides/deployment/shared-db.md
Outdated
|
||
- reviews/db/data/sap.capire.reviews-Reviews.csv | ||
|
||
``` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
``` | |
```txt | |
ID;subject;... | |
1689144d-3b10-4849-bcbe-2408a13e161d;201.... | |
... | |
``` |
Please add a language tag. For plain text add txt
as language tag.
guides/deployment/shared-db.md
Outdated
} | ||
``` | ||
|
||
# Authentification |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
# Authentification | |
# Authentication |
Or maybe one of these: Authentications?
guides/deployment/shared-db.md
Outdated
|
||
# Messaging | ||
|
||
The messaging service is used to organize asynchronious communication between the CAP services. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The messaging service is used to organize asynchronious communication between the CAP services. | |
The messaging service is used to organize asynchronous communication between the CAP services. |
Or maybe one of these: asynchronies, asynchronisms, synchronous, asynchronism?
guides/deployment/shared-db.md
Outdated
``` | ||
# Misc | ||
|
||
## authentification depends on messaging |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
## authentification depends on messaging | |
## authentication depends on messaging |
Or maybe one of these: authentications?
guides/deployment/shared-db.md
Outdated
|
||
File: mta.yaml | ||
|
||
- Duplicate samples-srv for earch CAP service |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- Duplicate samples-srv for earch CAP service | |
- Duplicate samples-srv for each CAP service |
Or maybe one of these: erch, earth, esrch, eparch?
guides/deployment/shared-db.md
Outdated
cds_requires_OrdersService_credentials: {"destination": "orders-dest","path": "/odata/v4/orders"} | ||
``` | ||
|
||
## approuter requires authentification |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
## approuter requires authentification | |
## approuter requires authentication |
Or maybe one of these: authentications?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Linting Errors
- guides/deployment/shared-db.md:271 Fenced code blocks should have a language specified
Spelling Mistakes
Generally, for each spelling mistake there are 2 ways to fix it:
- Fix the spelling mistake and commit it.
- The word is incorrectly reported as misspelled → put the word on the project-words.txt list, located in the root project directory.
guides/deployment/shared-db.md
Outdated
|
||
- CAP service package.json dependency: @sap/xssec | ||
|
||
``` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
``` | |
```txt | |
npm i @sap/xssec --workspace bookstore | |
npm i @sap/xssec --workspace orders | |
npm i @sap/xssec --workspace reviews | |
``` |
Please add a language tag. For plain text add txt
as language tag.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Spelling Mistakes
- guides/deployment/shared-db.md:42:257 Unknown word "Addinital"
Generally, for each spelling mistake there are 2 ways to fix it:
- Fix the spelling mistake and commit it.
- The word is incorrectly reported as misspelled → put the word on the project-words.txt list, located in the root project directory.
guides/deployment/shared-db.md
Outdated
|
||
## MTA | ||
|
||
In order to deploy CAP services in the Cloud Foundry environment as a Multitarget application a mta.yaml file is required. It represents a deployment discriptor which defines all CAP services and resources required by the application to function properly. Addinital information can be found in the [Deploy to Cloud* guide](../deployment/). An initial *mta.yaml* file can be generated using the following command: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In order to deploy CAP services in the Cloud Foundry environment as a Multitarget application a mta.yaml file is required. It represents a deployment discriptor which defines all CAP services and resources required by the application to function properly. Addinital information can be found in the [Deploy to Cloud* guide](../deployment/). An initial *mta.yaml* file can be generated using the following command: | |
In order to deploy CAP services in the Cloud Foundry environment as a Multitarget application a mta.yaml file is required. It represents a deployment discriptor which defines all CAP services and resources required by the application to function properly. Digital information can be found in the [Deploy to Cloud* guide](../deployment/). An initial *mta.yaml* file can be generated using the following command: |
Or maybe one of these: Addingham, addington, Addington, Additional?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Spelling Mistakes
- guides/deployment/late-cut-microservices.md:55:5 Unknown word "Modulith"
Generally, for each spelling mistake there are 2 ways to fix it:
- Fix the spelling mistake and commit it.
- The word is incorrectly reported as misspelled → put the word on the project-words.txt list, located in the root project directory.
|
||
 | ||
|
||
### Modulith |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
### Modulith | |
### Moduli |
Or maybe one of these: Modality, Modulate, Moduli's, Monolith?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Spelling Mistakes
- guides/deployment/shared-db.md:17:28 Unknown word "microserivces"
Generally, for each spelling mistake there are 2 ways to fix it:
- Fix the spelling mistake and commit it.
- The word is incorrectly reported as misspelled → put the word on the project-words.txt list, located in the root project directory.
Disadvantages: | ||
- Accessing data directly (without an API) means any changes in the data model affect all applications directly | ||
- every change in one of the services either requires | ||
- a redeployment of all microserivces involved |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- a redeployment of all microserivces involved | |
- a redeployment of all microservices involved |
Or maybe one of these: microservice, microdrives?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Spelling Mistakes
- guides/deployment/late-cut-microservices.md:7:29 Unknown word "moduliths"
- guides/deployment/late-cut-microservices.md:64:5 Unknown word "Modulith"
- guides/deployment/shared-db.md:27:28 Unknown word "microserivces"
Generally, for each spelling mistake there are 2 ways to fix it:
- Fix the spelling mistake and commit it.
- The word is incorrectly reported as misspelled → put the word on the project-words.txt list, located in the root project directory.
- Deployment | ||
- Late Cut Microservices | ||
synopsis: > | ||
An overview on monoliths, moduliths and microservices - breaking down their aspects, benefits and drawbacks. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
An overview on monoliths, moduliths and microservices - breaking down their aspects, benefits and drawbacks. | |
An overview on monoliths, moduli's and microservices - breaking down their aspects, benefits and drawbacks. |
Or maybe one of these: modulates, monoliths, moduli, moults?
|
||
 | ||
|
||
### Modulith |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
### Modulith | |
### Moduli |
Or maybe one of these: Modality, Modulate, Moduli's, Monolith?
Disadvantages: | ||
- Accessing data directly (without an API) means any changes in the data model affect all applications directly | ||
- every change in one of the services either requires | ||
- a redeployment of all microserivces involved |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- a redeployment of all microserivces involved | |
- a redeployment of all microservices involved |
Or maybe one of these: microservice, microdrives?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Spelling Mistakes
- guides/deployment/shared-db.md:165:29 Unknown word "shoud"
- guides/deployment/shared-db.md:671:36 Unknown word "funtionality"
Generally, for each spelling mistake there are 2 ways to fix it:
- Fix the spelling mistake and commit it.
- The word is incorrectly reported as misspelled → put the word on the project-words.txt list, located in the root project directory.
|
||
#### prepare shared-db CDS model | ||
|
||
Add list of CDS models that shoud be considered for deployment: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add list of CDS models that shoud be considered for deployment: | |
Add list of CDS models that shod be considered for deployment: |
Or maybe one of these: shoed, shout, should, shroud?
|
||
There should be a possibility to directly create entity instances (Orders) via API. | ||
|
||
Add projection bypassing the draft funtionality enabled only for the system-user: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add projection bypassing the draft funtionality enabled only for the system-user: | |
Add projection bypassing the draft functionality enabled only for the system-user: |
Or maybe one of these: functionally, functionalism, functionalist, functionalists?
1. install dependencies, for example: `npm ci` | ||
2. assemble CDS model containing all artifacts for all CAP services, for example: `npx cds build (directory with db artifacts) --for hana --production`. | ||
3. prepare CAP services, for example: `npx cds build (SAP service directory) --for nodejs --production --ws-pack` where the *--ws-pack* option is important for node modules referencing other repository-local node modules |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
unclear if instructions or just explanations
#### add a npm start script for each CAP service | ||
|
||
::: code-group | ||
```json [(service)/package.json] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
clarify (service) and add short explanation
Add initial database configuration using the command: | ||
|
||
```shell | ||
cds add hana --production ??? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
???
?
|
||
#### add dependency @cap-js/hana | ||
|
||
```shell |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add line above that this should be executed
Prepare the *shared-db* folder - a node module referencing all relevant CDS models from all relevant workspaces required to generate the HDI artifacts for all CAP services: | ||
|
||
```shell | ||
mkdir -p shared-db/db && cd shared-db && npm init -y && cd .. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
npm init -y
creates a bunch of fields which should not be there, particularly the license field. The license is defined in the root folder of the monorepo
```javascript [bookstore/srv/mashup.js] | ||
CatalogService.on ('OrderedBook', async (msg) => { | ||
...... | ||
return OrdersService.create ('OrdersNoDraft').entries({ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
unclear -> add what to remove, what to add
- npx cds build ./orders --for nodejs --production --ws-pack # [!code ++] | ||
- npx cds build ./reviews --for nodejs --production # [!code ++] | ||
- npx cds build ./bookstore --for nodejs --production --ws-pack # [!code ++] | ||
``` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- npx cds build --production
is still leftover after these changes.....
requires: # [!code ++] | ||
- name: samples-auth # [!code ++] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
already exists...
``` | ||
::: | ||
|
||
#### static content route |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
after all app-router changes, there is still something missing, seems to be the ^/appconfig/
- npx cds build ./orders --for nodejs --production --ws-pack # [!code ++] | ||
- npx cds build ./reviews --for nodejs --production # [!code ++] | ||
- npx cds build ./bookstore --for nodejs --production --ws-pack # [!code ++] | ||
``` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
-> steps on how to deploy and view the deployed app...
npm run build
npm run deploy
cf apps -> go to url
No description provided.