pdm config
This commit is contained in:
18
gdpr/___pdm-config.json
Normal file
18
gdpr/___pdm-config.json
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
{
|
||||||
|
"fullyQualifiedApplicationName": "gdpr-bookshop",
|
||||||
|
"fullyQualifiedModuleName" : "gdpr-srv",
|
||||||
|
"applicationTitle" : "PDM Bookshop",
|
||||||
|
"applicationTitleKey" : "PDM Bookshop",
|
||||||
|
"applicationURL" : "https://gdpr-srv.cfapps.sap.hana.ondemand.com/",
|
||||||
|
"endPoints": [
|
||||||
|
{
|
||||||
|
"type": "odatav4",
|
||||||
|
"serviceName": "pdm-service",
|
||||||
|
"serviceTitle": "GDPR",
|
||||||
|
"serviceTitleKey": "GDPR",
|
||||||
|
"serviceURI": "gdpr",
|
||||||
|
"hasGdprV4Annotations": true,
|
||||||
|
"cacheControl": "no-cache"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
26
gdpr/db/data-privacy.cds
Normal file
26
gdpr/db/data-privacy.cds
Normal file
@@ -0,0 +1,26 @@
|
|||||||
|
// Proxy for importing schema from bookshop sample
|
||||||
|
using { sap.capire.bookshop } from './schema';
|
||||||
|
|
||||||
|
// annotations for Data Privacy
|
||||||
|
annotate bookshop.Customers with @PersonalData.EntitySemantics: 'DataSubject'
|
||||||
|
{
|
||||||
|
ID @PersonalData.FieldSemantics: 'DataSubjectID';
|
||||||
|
emailAddress @PersonalData.IsPotentiallyPersonal;
|
||||||
|
firstName @PersonalData.IsPotentiallyPersonal;
|
||||||
|
lastName @PersonalData.IsPotentiallyPersonal;
|
||||||
|
creditCardNo @PersonalData.IsPotentiallySensitive;
|
||||||
|
}
|
||||||
|
|
||||||
|
annotate bookshop.CustomerPostalAddress with @PersonalData.EntitySemantics: 'DataSubjectDetails'
|
||||||
|
{
|
||||||
|
Customer @PersonalData.FieldSemantics: 'DataSubjectID';
|
||||||
|
street @PersonalData.IsPotentiallyPersonal;
|
||||||
|
town @PersonalData.IsPotentiallyPersonal;
|
||||||
|
country @PersonalData.IsPotentiallyPersonal;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// annotations for Audit Log
|
||||||
|
annotate bookshop.Customers with @AuditLog.Operation: {Read: true, Insert: true, Update: true, Delete: true};
|
||||||
|
|
||||||
|
annotate bookshop.CustomerPostalAddress with @AuditLog.Operation: {Read: true, Insert: true, Update: true, Delete: true};
|
||||||
@@ -1,3 +1,3 @@
|
|||||||
ID;modifiedAt;createdAt;createdBy;modifiedBy;OrderNo;currency_code;Customer_ID
|
ID;modifiedAt;createdAt;createdBy;modifiedBy;OrderNo;currency_code;Customer_ID
|
||||||
5e2f2640-6866-4dcf-8f4d-3027aa831cad;2019-04-04;2019-01-31;john.doe@test.com;john.doe@test.com;1;USD;8e2f2640-6866-4dcf-8f4d-3027aa831cad;
|
5e2f2640-6866-4dcf-8f4d-3027aa831cad;2019-04-04;2019-01-31;john.doe@test.com;john.doe@test.com;1;USD;8e2f2640-6866-4dcf-8f4d-3027aa831cad
|
||||||
44e718c9-ff99-47f1-8ca3-950c850777d4;2019-04-04;2019-01-30;jane.doe@test.com;jane.doe@test.com;2;USD;74e718c9-ff99-47f1-8ca3-950c850777d4;
|
44e718c9-ff99-47f1-8ca3-950c850777d4;2019-04-04;2019-01-30;jane.doe@test.com;jane.doe@test.com;2;USD;74e718c9-ff99-47f1-8ca3-950c850777d4
|
||||||
|
@@ -25,27 +25,3 @@ entity CustomerPostalAddress : cuid, managed {
|
|||||||
country : Country;
|
country : Country;
|
||||||
someOtherField : String(128);
|
someOtherField : String(128);
|
||||||
};
|
};
|
||||||
|
|
||||||
// annotations for Data Privacy
|
|
||||||
annotate Customers with @PersonalData.EntitySemantics: 'DataSubject'
|
|
||||||
{
|
|
||||||
ID @PersonalData.FieldSemantics: 'DataSubjectID';
|
|
||||||
emailAddress @PersonalData.IsPotentiallyPersonal;
|
|
||||||
firstName @PersonalData.IsPotentiallyPersonal;
|
|
||||||
lastName @PersonalData.IsPotentiallyPersonal;
|
|
||||||
creditCardNo @PersonalData.IsPotentiallySensitive;
|
|
||||||
}
|
|
||||||
|
|
||||||
annotate CustomerPostalAddress with @PersonalData.EntitySemantics: 'DataSubjectDetails'
|
|
||||||
{
|
|
||||||
Customer @PersonalData.FieldSemantics: 'DataSubjectID';
|
|
||||||
street @PersonalData.IsPotentiallyPersonal;
|
|
||||||
town @PersonalData.IsPotentiallyPersonal;
|
|
||||||
country @PersonalData.IsPotentiallyPersonal;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// annotations for Audit Log
|
|
||||||
annotate Customers with @AuditLog.Operation: {Read: true, Insert: true, Update: true, Delete: true};
|
|
||||||
|
|
||||||
annotate CustomerPostalAddress with @AuditLog.Operation: {Read: true, Insert: true, Update: true, Delete: true};
|
|
||||||
|
|||||||
136
gdpr/db/src/.hdiconfig
Normal file
136
gdpr/db/src/.hdiconfig
Normal file
@@ -0,0 +1,136 @@
|
|||||||
|
{
|
||||||
|
"file_suffixes": {
|
||||||
|
"csv": {
|
||||||
|
"plugin_name": "com.sap.hana.di.tabledata.source"
|
||||||
|
},
|
||||||
|
"hdbafllangprocedure": {
|
||||||
|
"plugin_name": "com.sap.hana.di.afllangprocedure"
|
||||||
|
},
|
||||||
|
"hdbanalyticprivilege": {
|
||||||
|
"plugin_name": "com.sap.hana.di.analyticprivilege"
|
||||||
|
},
|
||||||
|
"hdbcalculationview": {
|
||||||
|
"plugin_name": "com.sap.hana.di.calculationview"
|
||||||
|
},
|
||||||
|
"hdbcollection": {
|
||||||
|
"plugin_name": "com.sap.hana.di.collection"
|
||||||
|
},
|
||||||
|
"hdbconstraint": {
|
||||||
|
"plugin_name": "com.sap.hana.di.constraint"
|
||||||
|
},
|
||||||
|
"hdbdropcreatetable": {
|
||||||
|
"plugin_name": "com.sap.hana.di.dropcreatetable"
|
||||||
|
},
|
||||||
|
"hdbflowgraph": {
|
||||||
|
"plugin_name": "com.sap.hana.di.flowgraph"
|
||||||
|
},
|
||||||
|
"hdbfunction": {
|
||||||
|
"plugin_name": "com.sap.hana.di.function"
|
||||||
|
},
|
||||||
|
"hdbgraphworkspace": {
|
||||||
|
"plugin_name": "com.sap.hana.di.graphworkspace"
|
||||||
|
},
|
||||||
|
"hdbhadoopmrjob": {
|
||||||
|
"plugin_name": "com.sap.hana.di.virtualfunctionpackage.hadoop"
|
||||||
|
},
|
||||||
|
"hdbindex": {
|
||||||
|
"plugin_name": "com.sap.hana.di.index"
|
||||||
|
},
|
||||||
|
"hdblibrary": {
|
||||||
|
"plugin_name": "com.sap.hana.di.library"
|
||||||
|
},
|
||||||
|
"hdbmigrationtable": {
|
||||||
|
"plugin_name": "com.sap.hana.di.table.migration"
|
||||||
|
},
|
||||||
|
"hdbprocedure": {
|
||||||
|
"plugin_name": "com.sap.hana.di.procedure"
|
||||||
|
},
|
||||||
|
"hdbprojectionview": {
|
||||||
|
"plugin_name": "com.sap.hana.di.projectionview"
|
||||||
|
},
|
||||||
|
"hdbprojectionviewconfig": {
|
||||||
|
"plugin_name": "com.sap.hana.di.projectionview.config"
|
||||||
|
},
|
||||||
|
"hdbreptask": {
|
||||||
|
"plugin_name": "com.sap.hana.di.reptask"
|
||||||
|
},
|
||||||
|
"hdbresultcache": {
|
||||||
|
"plugin_name": "com.sap.hana.di.resultcache"
|
||||||
|
},
|
||||||
|
"hdbrole": {
|
||||||
|
"plugin_name": "com.sap.hana.di.role"
|
||||||
|
},
|
||||||
|
"hdbroleconfig": {
|
||||||
|
"plugin_name": "com.sap.hana.di.role.config"
|
||||||
|
},
|
||||||
|
"hdbsearchruleset": {
|
||||||
|
"plugin_name": "com.sap.hana.di.searchruleset"
|
||||||
|
},
|
||||||
|
"hdbsequence": {
|
||||||
|
"plugin_name": "com.sap.hana.di.sequence"
|
||||||
|
},
|
||||||
|
"hdbstatistics": {
|
||||||
|
"plugin_name": "com.sap.hana.di.statistics"
|
||||||
|
},
|
||||||
|
"hdbstructuredprivilege": {
|
||||||
|
"plugin_name": "com.sap.hana.di.structuredprivilege"
|
||||||
|
},
|
||||||
|
"hdbsynonym": {
|
||||||
|
"plugin_name": "com.sap.hana.di.synonym"
|
||||||
|
},
|
||||||
|
"hdbsynonymconfig": {
|
||||||
|
"plugin_name": "com.sap.hana.di.synonym.config"
|
||||||
|
},
|
||||||
|
"hdbsystemversioning": {
|
||||||
|
"plugin_name": "com.sap.hana.di.systemversioning"
|
||||||
|
},
|
||||||
|
"hdbtable": {
|
||||||
|
"plugin_name": "com.sap.hana.di.table"
|
||||||
|
},
|
||||||
|
"hdbtabledata": {
|
||||||
|
"plugin_name": "com.sap.hana.di.tabledata"
|
||||||
|
},
|
||||||
|
"hdbtabletype": {
|
||||||
|
"plugin_name": "com.sap.hana.di.tabletype"
|
||||||
|
},
|
||||||
|
"hdbtrigger": {
|
||||||
|
"plugin_name": "com.sap.hana.di.trigger"
|
||||||
|
},
|
||||||
|
"hdbview": {
|
||||||
|
"plugin_name": "com.sap.hana.di.view"
|
||||||
|
},
|
||||||
|
"hdbvirtualfunction": {
|
||||||
|
"plugin_name": "com.sap.hana.di.virtualfunction"
|
||||||
|
},
|
||||||
|
"hdbvirtualfunctionconfig": {
|
||||||
|
"plugin_name": "com.sap.hana.di.virtualfunction.config"
|
||||||
|
},
|
||||||
|
"hdbvirtualpackagehadoop": {
|
||||||
|
"plugin_name": "com.sap.hana.di.virtualpackage.hadoop"
|
||||||
|
},
|
||||||
|
"hdbvirtualpackagesparksql": {
|
||||||
|
"plugin_name": "com.sap.hana.di.virtualpackage.sparksql"
|
||||||
|
},
|
||||||
|
"hdbvirtualprocedure": {
|
||||||
|
"plugin_name": "com.sap.hana.di.virtualprocedure"
|
||||||
|
},
|
||||||
|
"hdbvirtualprocedureconfig": {
|
||||||
|
"plugin_name": "com.sap.hana.di.virtualprocedure.config"
|
||||||
|
},
|
||||||
|
"hdbvirtualtable": {
|
||||||
|
"plugin_name": "com.sap.hana.di.virtualtable"
|
||||||
|
},
|
||||||
|
"hdbvirtualtableconfig": {
|
||||||
|
"plugin_name": "com.sap.hana.di.virtualtable.config"
|
||||||
|
},
|
||||||
|
"properties": {
|
||||||
|
"plugin_name": "com.sap.hana.di.tabledata.properties"
|
||||||
|
},
|
||||||
|
"tags": {
|
||||||
|
"plugin_name": "com.sap.hana.di.tabledata.properties"
|
||||||
|
},
|
||||||
|
"txt": {
|
||||||
|
"plugin_name": "com.sap.hana.di.copyonly"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
30
gdpr/manifest.yml
Normal file
30
gdpr/manifest.yml
Normal file
@@ -0,0 +1,30 @@
|
|||||||
|
# Generated manifest.yml based on template version 0.1.0
|
||||||
|
# appName = gdpr
|
||||||
|
# language=nodejs
|
||||||
|
# multiTenant=false
|
||||||
|
---
|
||||||
|
applications:
|
||||||
|
# -----------------------------------------------------------------------------------
|
||||||
|
# Backend Service
|
||||||
|
# -----------------------------------------------------------------------------------
|
||||||
|
- name: gdpr-srv
|
||||||
|
path: gen/srv
|
||||||
|
memory: 256M
|
||||||
|
buildpack: nodejs_buildpack
|
||||||
|
services:
|
||||||
|
- gdpr-db
|
||||||
|
- name: pdm
|
||||||
|
parameters: ./pdm-config.json
|
||||||
|
|
||||||
|
# -----------------------------------------------------------------------------------
|
||||||
|
# HANA Database Content Deployer App
|
||||||
|
# -----------------------------------------------------------------------------------
|
||||||
|
- name: gdpr-db-deployer
|
||||||
|
path: gen/db
|
||||||
|
no-route: true
|
||||||
|
health-check-type: process
|
||||||
|
memory: 256M
|
||||||
|
instances: 1
|
||||||
|
buildpack: nodejs_buildpack
|
||||||
|
services:
|
||||||
|
- gdpr-db
|
||||||
@@ -1,22 +1,23 @@
|
|||||||
{
|
{
|
||||||
"name": "@capire/fiori",
|
"name": "@capire/gdpr",
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@capire/bookshop": "../bookshop",
|
"@capire/bookshop": "../bookshop",
|
||||||
"@capire/orders": "../orders",
|
"@capire/orders": "../orders",
|
||||||
"@capire/common": "../common",
|
"@capire/common": "../common",
|
||||||
"@sap/cds": "^4",
|
"@sap/cds": "^4",
|
||||||
"express": "^4.17.1"
|
"express": "^4.17.1",
|
||||||
},
|
"@sap/hana-client": "^2.4.177"
|
||||||
"scripts": {
|
},
|
||||||
"start": "cds run --in-memory?",
|
"scripts": {
|
||||||
"watch": "cds watch"
|
"start": "cds run --in-memory?",
|
||||||
},
|
"watch": "cds watch"
|
||||||
"cds": {
|
},
|
||||||
"requires": {
|
"cds": {
|
||||||
"db": {
|
"requires": {
|
||||||
"kind": "sql"
|
"db": {
|
||||||
}
|
"kind": "sql"
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|||||||
18
gdpr/pdm-config.json
Normal file
18
gdpr/pdm-config.json
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
{
|
||||||
|
"fullyQualifiedApplicationName": "gdpr-bookshop",
|
||||||
|
"fullyQualifiedModuleName": "gdpr-srv",
|
||||||
|
"applicationTitle": "PDM Bookshop",
|
||||||
|
"applicationTitleKey": "PDM Bookshop",
|
||||||
|
"applicationURL": "https://gdpr-srv.cfapps.sap.hana.ondemand.com/",
|
||||||
|
"endPoints": [
|
||||||
|
{
|
||||||
|
"type": "odatav4",
|
||||||
|
"serviceName": "pdm-service",
|
||||||
|
"serviceTitle": "GDPR",
|
||||||
|
"serviceTitleKey": "GDPR",
|
||||||
|
"serviceURI": "gdpr",
|
||||||
|
"hasGdprV4Annotations": true,
|
||||||
|
"cacheControl": "no-cache"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
8
gdpr/pdm-instance-config.json
Normal file
8
gdpr/pdm-instance-config.json
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
{
|
||||||
|
"xs-security": {
|
||||||
|
"xsappname": "gdpr-bookshop",
|
||||||
|
"authorities": ["$ACCEPT_GRANTED_AUTHORITIES"]
|
||||||
|
},
|
||||||
|
"fullyQualifiedApplicationName": "gdpr-bookshop",
|
||||||
|
"appConsentServiceEnabled": true
|
||||||
|
}
|
||||||
12
gdpr/services-manifest.yml
Normal file
12
gdpr/services-manifest.yml
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
# Generated services-manifest.yml based on template version 0.1.0
|
||||||
|
# appName = gdpr
|
||||||
|
---
|
||||||
|
create-services:
|
||||||
|
# ------------------------------------------------------------
|
||||||
|
- name: gdpr-db
|
||||||
|
broker: hana # 'hanatrial' on trial landscapes
|
||||||
|
plan: "hdi-shared"
|
||||||
|
- name: pdm
|
||||||
|
broker: personal-data-manager-service
|
||||||
|
plan: standard
|
||||||
|
parameters: pdm-config-hugo.json
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
//using from '@capire/orders';
|
//using from '@capire/orders';
|
||||||
using { sap.capire.bookshop as db } from '../db/schema';
|
using { sap.capire.bookshop as db } from '../db/data-privacy';
|
||||||
using { sap.capire.bookshop.Books } from '@capire/bookshop';
|
using { sap.capire.bookshop.Books } from '@capire/bookshop';
|
||||||
using { sap.capire.bookshop.Orders } from '@capire/orders';
|
using { sap.capire.bookshop.Orders } from '@capire/orders';
|
||||||
using { sap.capire.bookshop.OrderItems } from '@capire/orders';
|
using { sap.capire.bookshop.OrderItems } from '@capire/orders';
|
||||||
|
|||||||
Reference in New Issue
Block a user