Socket
Socket
Sign inDemoInstall

@sap/generator-add-hdb-module

Package Overview
Dependencies
12
Maintainers
1
Versions
18
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 1.4.0 to 1.5.0

6

CHANGELOG.md

@@ -0,1 +1,7 @@

## 1.5.0
### Fixes
- The HDI namespace validation has been relaxed
- Parsing of .env files has been improved
## 1.4.0

@@ -2,0 +8,0 @@

228

features.json

@@ -22,2 +22,8 @@ {

{
"name": "artifact_creation_open_file",
"jira": "HANATOOLING-22766",
"status": "released",
"capabilities": []
},
{
"name": "artifact_creation_use_vt_wizard",

@@ -67,3 +73,3 @@ "jira": "HANATOOLING-2935",

"jira": "HANATOOLING-12121",
"status": "candidate",
"status": "released",
"capabilities": []

@@ -120,2 +126,14 @@ },

{
"name": "cv_greedy_pruning",
"jira": "HANATOOLING-31983",
"status": "dev",
"capabilities": []
},
{
"name": "cv_greedy_pruning_execution_hints",
"jira": "HANATOOLING-50873",
"status": "candidate",
"capabilities": []
},
{
"name": "cv_improve_debug",

@@ -151,2 +169,8 @@ "jira": "HANATOOLING-18678",

{
"name": "cv_median_aggregation_support",
"jira": "HANATOOLING-31982",
"status": "released",
"capabilities": []
},
{
"name": "cv_new_find_dlg_refactoring",

@@ -166,3 +190,3 @@ "jira": "HANATOOLING-22583",

"jira": "HANATOOLING-18671",
"status": "candidate",
"status": "released",
"capabilities": []

@@ -195,2 +219,20 @@ },

{
"name": "cv_scube_support",
"jira": "HANATOOLING-51072",
"status": "candidate",
"capabilities": []
},
{
"name": "cv_session_variable_mapped_into_data_sources",
"jira": "HANATOOLING-31986",
"status": "released",
"capabilities": []
},
{
"name": "cv_snapshot",
"jira": "HANATOOLING-30609",
"status": "released",
"capabilities": []
},
{
"name": "cv_src_svc_for_new_find_dlg",

@@ -208,8 +250,2 @@ "jira": "HANATOOLING-12323",

{
"name": "cv_system_version_table",
"jira": "HANATOOLING-12122",
"status": "dev",
"capabilities": []
},
{
"name": "dt_artifact_types",

@@ -223,3 +259,3 @@ "jira": "HANATOOLING-3449",

"jira": "HANATOOLING-5841",
"status": "candidate",
"status": "released",
"capabilities": []

@@ -300,2 +336,8 @@ },

{
"name": "network_transfer_information",
"jira": "HANATOOLING-15026",
"status": "released",
"capabilities": []
},
{
"name": "online_dashboard",

@@ -307,2 +349,38 @@ "jira": "HANATOOLING-18400",

{
"name": "reset_artifact_to_deployed",
"jira": "HANATOOLING-8535",
"status": "dev",
"capabilities": []
},
{
"name": "reverse_engineer_dt",
"jira": "HANATOOLING-5778",
"status": "released",
"capabilities": []
},
{
"name": "sql_db_switch",
"jira": "HANATOOLING-29716",
"status": "released",
"capabilities": []
},
{
"name": "sql_runtime_stats",
"jira": "HANATOOLING-28292",
"status": "released",
"capabilities": []
},
{
"name": "sqlc_auto_commit_setting",
"jira": "HANATOOLING-41432",
"status": "released",
"capabilities": []
},
{
"name": "sqlc_parameterized_statements",
"jira": "HANATOOLING-30409",
"status": "released",
"capabilities": []
},
{
"name": "supportability_liveConnectionRefinement",

@@ -326,5 +404,11 @@ "jira": "HANATOOLING-12290",

{
"name": "vsc-hana-explorer.bind_ups_to_targetcontainer",
"jira": "HANATOOLING-41917",
"status": "released",
"capabilities": []
},
{
"name": "vsc-hana-explorer.bindunbindallservice",
"jira": "HANATOOLING-13890",
"status": "dev",
"status": "released",
"capabilities": []

@@ -335,3 +419,3 @@ },

"jira": "HANATOOLING-8565",
"status": "dev",
"status": "candidate",
"capabilities": []

@@ -342,3 +426,3 @@ },

"jira": "HANATOOLING-17044",
"status": "candidate",
"status": "released",
"capabilities": []

@@ -353,2 +437,32 @@ },

{
"name": "vsc-hana-explorer.checkdatabaseidwhenbind",
"jira": "HANATOOLING-42893",
"status": "released",
"capabilities": []
},
{
"name": "vsc-hana-explorer.checkschemawhenbind",
"jira": "HANATOOLING-22629",
"status": "released",
"capabilities": []
},
{
"name": "vsc-hana-explorer.create_grantfiles_when_addconnection",
"jira": "HANATOOLING-42444",
"status": "released",
"capabilities": []
},
{
"name": "vsc-hana-explorer.create_procedure_grantor",
"jira": "HANATOOLING-48918",
"status": "candidate",
"capabilities": []
},
{
"name": "vsc-hana-explorer.deploy_multiple_files",
"jira": "HANATOOLING-19584",
"status": "released",
"capabilities": []
},
{
"name": "vsc-hana-explorer.disableAutoUndeployWhenBinding",

@@ -378,2 +492,32 @@ "jira": "HANATOOLING-19162",

{
"name": "vsc-hana-explorer.support_managed_services",
"jira": "HANATOOLING-50482",
"status": "dev",
"capabilities": []
},
{
"name": "vsc-hana-explorer.supportmodeexport",
"jira": "HANATOOLING-41774",
"status": "released",
"capabilities": []
},
{
"name": "vsc-hana-explorer.sync_deploymentstate_with_database",
"jira": "HANATOOLING-48519",
"status": "released",
"capabilities": []
},
{
"name": "vsc-hana-explorer.unbind_services_when_switch_cfspace",
"jira": "HANATOOLING-42898",
"status": "released",
"capabilities": []
},
{
"name": "vsc_auto_commit_setting",
"jira": "HANATOOLING-42807",
"status": "released",
"capabilities": []
},
{
"name": "vsc_choose_time_table",

@@ -391,2 +535,26 @@ "jira": "HANATOOLING-2801",

{
"name": "vsc_db_switch",
"jira": "HANATOOLING-43401",
"status": "released",
"capabilities": []
},
{
"name": "vsc_dbx_copy_object_names",
"jira": "HANATOOLING-43625",
"status": "released",
"capabilities": []
},
{
"name": "vsc_dbx_create_statement",
"jira": "HANATOOLING-31482",
"status": "released",
"capabilities": []
},
{
"name": "vsc_dbx_hdi_admin_connection",
"jira": "HANATOOLING-48171",
"status": "released",
"capabilities": []
},
{
"name": "vsc_dbx_hrtt_connection_setting",

@@ -404,2 +572,14 @@ "jira": "HANATOOLING-30606",

{
"name": "vsc_dbx_select_statement",
"jira": "HANATOOLING-31483",
"status": "dev",
"capabilities": []
},
{
"name": "vsc_dbx_statement_help_panel",
"jira": "HANATOOLING-47211",
"status": "dev",
"capabilities": []
},
{
"name": "vsc_dbx_userstore",

@@ -431,3 +611,3 @@ "jira": "HANATOOLING-30538",

"jira": "HANATOOLING-9303",
"status": "candidate",
"status": "released",
"capabilities": []

@@ -456,3 +636,3 @@ },

"jira": "HANATOOLING-5988",
"status": "candidate",
"status": "released",
"capabilities": []

@@ -469,2 +649,8 @@ },

"jira": "HANATOOLING-31000",
"status": "released",
"capabilities": []
},
{
"name": "vsc_extension_sa.sql_console_adoption_dbx",
"jira": "HANATOOLING-30868",
"status": "candidate",

@@ -476,3 +662,3 @@ "capabilities": []

"jira": "HANATOOLING-15279",
"status": "candidate",
"status": "released",
"capabilities": []

@@ -500,4 +686,4 @@ },

"name": "vsc_parameterized_statements",
"jira": "HANATOOLING-30409",
"status": "dev",
"jira": "HANATOOLING-42797",
"status": "released",
"capabilities": []

@@ -518,5 +704,11 @@ },

{
"name": "vsc_virtual_table_editor",
"jira": "HANATOOLING-47985",
"status": "candidate",
"capabilities": []
},
{
"name": "window_function_integration",
"jira": "HANATOOLING-7117",
"status": "candidate",
"status": "released",
"capabilities": []

@@ -523,0 +715,0 @@ }

@@ -22,2 +22,5 @@ 'use strict';

'Please install it to bind the database module service. Instructions to install "cf CLI" may be found at ' + SAP_CF_CLI_INSTALLATION_DOC;
const GENERATOR_ERROR_MESSAGE = 'The generator encountered an error: ';
const SRC_FOLDER_NAME = 'src';
const HDICONFIG_FILE_NAME = '.hdiconfig';
module.exports = {

@@ -40,5 +43,8 @@ SERVICE_KEY_NAME,

CLOUD_FOUNDRY_PROMPT_DESCRIPTION_NO_LOGIN,
CF_CLI_INFO_MESSAGE
CF_CLI_INFO_MESSAGE,
GENERATOR_ERROR_MESSAGE,
SRC_FOLDER_NAME,
HDICONFIG_FILE_NAME
};

106

generators/generator-hdb-module/index.js

@@ -19,6 +19,8 @@ 'use strict';

MODULE_PATH_CONF,
HANA_CLOUD,
CLOUD_FOUNDRY_PROMPT_DESCRIPTION,
CLOUD_FOUNDRY_PROMPT_DESCRIPTION_NO_LOGIN,
CF_CLI_INFO_MESSAGE
CF_CLI_INFO_MESSAGE,
GENERATOR_ERROR_MESSAGE,
SRC_FOLDER_NAME,
HDICONFIG_FILE_NAME
} = require( './Constants' );

@@ -63,4 +65,3 @@ const fs = require( 'fs' );

if( !this.isCfToolsAvailable ){
pageHeadingForDatabaseInformation = pageHeadingForDatabaseInformation +
'\n' + CF_CLI_INFO_MESSAGE;
pageHeadingForDatabaseInformation = `${pageHeadingForDatabaseInformation}\n${CF_CLI_INFO_MESSAGE}`;
}

@@ -108,5 +109,7 @@ const prompts = [

validate: function( databaseNamespace ) {
if( !databaseNamespace ) { return true; }
const errorMessage = 'Invalid format for the "Namespace" parameter value: the namespace must start'+
' with a letter and may contain letters, digits, dots, dash and underscores.';
if( !databaseNamespace ) {
return true;
}
const errorMessage = 'Invalid format for the "Namespace" parameter value: the namespace must not'+
' contain colon (:) or forward slash (/) characters.';
return Validation.isValid( databaseNamespace, errorMessage );

@@ -129,5 +132,3 @@ }

choices: async function() {
return that.featureToggles.isFeatureEnabled( 'hana_service' ) ?
DATABASE_VERSIONS :
[ HANA_CLOUD ];
return DATABASE_VERSIONS;
},

@@ -141,19 +142,4 @@ 'default': 0

'default': true,
validate: async function( answer ){
that.cloudFoundryPrompt.description = await Utils.isUserLoggedIn() ?
CLOUD_FOUNDRY_PROMPT_DESCRIPTION_NO_LOGIN :
CLOUD_FOUNDRY_PROMPT_DESCRIPTION;
const indexOfCloudFoundryPrompt = that.prompts.items.findIndex( item => item.name === that.cloudFoundryPrompt.name );
if( answer === false && indexOfCloudFoundryPrompt > -1 ){
that.prompts.splice( indexOfCloudFoundryPrompt, 1 );
} else if( answer === true ) {
if( indexOfCloudFoundryPrompt === -1 ) {
that.prompts.splice( that.prompts.size() + 1, 0, that.cloudFoundryPrompt );
} else {
// If 'cloudFoundryPrompt' are already included, then remove and re-include
// to reflect the description change
that.prompts.splice( indexOfCloudFoundryPrompt, 1, that.cloudFoundryPrompt );
}
}
return true;
validate: async function( answer ) {
return that._validateCreateModuleService( answer, that.prompts, that.cloudFoundryPrompt );
},

@@ -178,2 +164,21 @@ guiOptions: {

async _validateCreateModuleService( answer, prompts, cloudFoundryPrompt ) {
cloudFoundryPrompt.description = await Utils.isUserLoggedIn() ?
CLOUD_FOUNDRY_PROMPT_DESCRIPTION_NO_LOGIN :
CLOUD_FOUNDRY_PROMPT_DESCRIPTION;
const indexOfCloudFoundryPrompt = prompts.items.findIndex( item => item.name === cloudFoundryPrompt.name );
if( answer === false && indexOfCloudFoundryPrompt > -1 ){
prompts.splice( indexOfCloudFoundryPrompt, 1 );
} else if( answer === true ) {
if( indexOfCloudFoundryPrompt === -1 ) {
prompts.splice( prompts.size() + 1, 0, cloudFoundryPrompt );
} else {
// If 'cloudFoundryPrompt' are already included, then remove and re-include
// to reflect the description change
prompts.splice( indexOfCloudFoundryPrompt, 1, cloudFoundryPrompt );
}
}
return true;
}
async _handleCfLoginPrompt(){

@@ -218,3 +223,3 @@ const that = this;

let defaultCfOrgIndex = 0;
let defaultCfSpaceIndex = 0;
const defaultCfSpaceIndex = 0;
let cfOrgInfo = null;

@@ -224,3 +229,3 @@ let cfOrgNames = [];

if( cfOrgs.success ){
// this.env.error( new Error( 'The generator encountered an error. ' + cfOrgs.errorMessage ) );
// this.env.error( new Error( GENERATOR_ERROR_MESSAGE + cfOrgs.errorMessage ) );
cfOrgInfo = cfOrgs.orgs; //Array of {orgName : orgGuid}

@@ -252,3 +257,3 @@ cfOrgNames = cfOrgInfo.length > 0 ? Object.keys( cfOrgInfo[ 0 ] ) : [];

if( !cfOrgs.success ){
that.env.error( new Error( 'The generator encountered an error. ' + cfOrgs.errorMessage ) );
that.env.error( new Error( GENERATOR_ERROR_MESSAGE + cfOrgs.errorMessage ) );
} else {

@@ -294,3 +299,3 @@ cfOrgInfo = cfOrgs.orgs; //Array of {orgName : orgGuid}

if( !that.cfSpaces.success ) {
that.env.error( new Error( 'The generator encountered an error. ' + that.cfSpaces.errorMessage ) );
that.env.error( new Error( GENERATOR_ERROR_MESSAGE + that.cfSpaces.errorMessage ) );
}

@@ -359,3 +364,3 @@ return that.cfSpaces.spaces.map( item => Object.keys( item )[0] );

if( !result.success ) {
that.env.error( new Error( 'The generator encountered an error. ' + result.errorMessage ) );
that.env.error( new Error( GENERATOR_ERROR_MESSAGE + result.errorMessage ) );
}

@@ -365,3 +370,3 @@ Object.assign( that.hanaCloudDbInstances, result.hanaCloudServiceInstances );

} catch( e ) {
that.env.error( new Error( 'The generator encountered an error. ' + e.message ) );
that.env.error( new Error( GENERATOR_ERROR_MESSAGE + e.message ) );
}

@@ -397,3 +402,3 @@

if( !result.success ) {
that.env.error( new Error( 'The generator encountered an error. ' + result.errorMessage ) );
that.env.error( new Error( GENERATOR_ERROR_MESSAGE + result.errorMessage ) );
}

@@ -403,3 +408,3 @@ Object.assign( that.serviceInstances, result.serviceInstances );

} catch( e ) {
that.env.error( new Error( 'The generator encountered an error. ' + e.message ) );
that.env.error( new Error( GENERATOR_ERROR_MESSAGE + e.message ) );
}

@@ -439,3 +444,3 @@

let cfOrgInfo = null;
let cfOrgs = await Utils.getOrgs();
const cfOrgs = await Utils.getOrgs();
if( cfOrgs.success ) {

@@ -453,3 +458,3 @@ cfOrgInfo = cfOrgs.orgs; //Array of {orgName : orgGuid}

let selectedSpace = await Utils.getSelectedSpace();
const selectedSpace = await Utils.getSelectedSpace();
if( selectedSpace && Array.isArray( that.cfSpaces.spaces ) ){

@@ -466,4 +471,4 @@ that.cfSpaces.spaces.some( ( item ) => {

async _updateMtaModules() {
let that = this;
let mtaHdbhdbModule = {
const that = this;
const mtaHdbhdbModule = {
name: that.projectOptions.moduleName,

@@ -486,4 +491,4 @@ type: MODULE_TYPE,

async _updateMtaResources() {
let that = this;
let mtaHdbModuleResource = {
const that = this;
const mtaHdbModuleResource = {
name: 'hdi_'+that.projectOptions.moduleName,

@@ -558,3 +563,3 @@ properties: {

const hanaTrial = 'hanatrial';
let serviceType = ( this.databaseInformation.sapHanaDbVersion === HANA_SERVICE &&
const serviceType = ( this.databaseInformation.sapHanaDbVersion === HANA_SERVICE &&
await Utils.isServiceAvailableInCfSpace( hanaTrial, this.cfSpaceGuid ) )

@@ -581,3 +586,4 @@ ? hanaTrial

instanceName,
resourceName
resourceName,
this.featureToggles
);

@@ -590,3 +596,3 @@ this.log( `The Cloud Foundry service instance "${instanceName}" has been bound to the generated database module successfully` );

try {
const vCapContents = await Utils.createVcapContents( instanceName, resourceName, this.apiEndpoint );
const vCapContents = await Utils.createVcapContents( instanceName, resourceName, this.apiEndpoint, this.featureToggles );
await Utils.createEnvFile( dotEnvDirPath, vCapContents );

@@ -631,4 +637,4 @@ } catch( e ) {

this.fs.copyTpl(
this.templatePath( path.join( 'project_name', 'db', 'src', 'hdinamespace' ) ),
path.join( modulePath, 'src', '.hdinamespace' ),
this.templatePath( path.join( 'project_name', 'db', SRC_FOLDER_NAME, 'hdinamespace' ) ),
path.join( modulePath, SRC_FOLDER_NAME, '.hdinamespace' ),
props

@@ -643,3 +649,3 @@ );

this.templatePath( path.join( 'hdiconfig', 'hana_cloud_2021QRC2' ) ),
path.join( modulePath, 'src', '.hdiconfig' )
path.join( modulePath, SRC_FOLDER_NAME, HDICONFIG_FILE_NAME )
);

@@ -649,3 +655,3 @@ } else {

this.templatePath( path.join( 'hdiconfig', databaseType ) ),
path.join( modulePath, 'src', '.hdiconfig' )
path.join( modulePath, SRC_FOLDER_NAME, HDICONFIG_FILE_NAME )
);

@@ -656,3 +662,3 @@ }

this.templatePath( path.join( 'hdiconfig', this.databaseInformation.sapHanaDbVersion.replace( /\s+/g, '_' ).toLowerCase() ) ),
path.join( modulePath, 'src', '.hdiconfig' )
path.join( modulePath, SRC_FOLDER_NAME, HDICONFIG_FILE_NAME )
);

@@ -676,3 +682,3 @@ }

if( await Utils.getSelectedOrg() && await Utils.getSelectedSpace() ){
let e = await this._createService();
const e = await this._createService();
if( e ) {

@@ -679,0 +685,0 @@ errors.push( e );

@@ -9,7 +9,8 @@ 'use strict';

const md5 = require( 'md5' );
const dotenv = require( 'dotenv' );
const{ SERVICE_KEY_NAME, SERVICE_HANA_TRIAL, SERVICE_HANA, HANA_CLOUD, HDI_SHARED, DATABASE_VERSIONS } = require( './Constants' );
const FeatureToggles = new ( require( '@sap/hana-tooling-feature-toggles' ) )( __dirname + '/../../features.json' );
class Utils {
static async createVcapContents( instanceName, resourceName, endpoint ) {
static async createVcapContents( instanceName, resourceName, endpoint, featureToggles ) {
if( !endpoint ){

@@ -36,3 +37,6 @@ const cfTarget = await cfTools.cfGetTarget();

};
return os.EOL + 'VCAP_SERVICES=' + JSON.stringify( rest );
if( featureToggles && featureToggles.isFeatureEnabled( 'quote_env_file' ) ) {
return`${os.EOL}VCAP_SERVICES='${JSON.stringify( rest )}'`;
}
return`${os.EOL}VCAP_SERVICES=${JSON.stringify( rest )}`;
}

@@ -58,3 +62,3 @@

static async initiateLogin( apiEndPoint, userName, password ){
const result = await cfTools.cfLogin( apiEndPoint, userName, password );
const result = await cfTools.cfLogin({ endpoint: apiEndPoint, user: userName, password });
return result === 'OK';

@@ -122,5 +126,2 @@ }

static async getOrgs(){
let orgs = [];
let success = false;
let errorMessage = '';
try {

@@ -130,26 +131,24 @@ const availableOrgs = await cfTools.cfGetAvailableOrgs({

});
if( !availableOrgs || !Array.isArray( availableOrgs ) || availableOrgs.length === 0 ){
return{ success: true, orgs: [ ], errorMessage: 'No Cloud Foundry orgs found.' };
}
const orgs = [];
const obj = {};
if( availableOrgs && Array.isArray( availableOrgs ) && availableOrgs.length > 0 ){
availableOrgs.forEach( item => {
const orgName = item && item.label
? item.label: null;
const orgGuid = item && item.guid
? item.guid: null;
if( orgName && orgGuid ){
obj[orgName] = orgGuid;
}
});
if( Object.keys( obj ).length > 0 ) {
orgs.push( obj );
availableOrgs.forEach( item => {
const orgName = item && item.label
? item.label: null;
const orgGuid = item && item.guid
? item.guid: null;
if( orgName && orgGuid ){
obj[orgName] = orgGuid;
}
success = true;
} else {
errorMessage = 'No Cloud Foundry orgs found.';
success = true;
});
if( Object.keys( obj ).length > 0 ) {
orgs.push( obj );
}
return{ success: true, orgs, errorMessage: '' };
} catch( e ) {
errorMessage = 'Failed to fetch Cloud Foundry orgs, Reason: ' + e.message;
const errorMessage = 'Failed to fetch Cloud Foundry orgs, Reason: ' + e.message;
return{ success: false, orgs: [ ], errorMessage };
}
return{ success, orgs, errorMessage };
}

@@ -159,39 +158,36 @@

static async getSpaces( orgGuid ){
let spaces = [];
let success = false;
let errorMessage = '';
if( orgGuid && typeof orgGuid === 'string' ){
try {
const availableSpaces = await cfTools.cfGetAvailableSpaces( orgGuid );
if( availableSpaces && Array.isArray( availableSpaces ) && availableSpaces.length > 0 ){
if( !orgGuid || typeof orgGuid !== 'string' ){
return{ success: false, spaces: [], errorMessage: '' };
}
availableSpaces.sort( ( a, b ) => {
if( a.label > b.label ) {
return 1;
} else if( a.label < b.label ) {
return-1;
}
return 0;
}).forEach( item => {
const spaceName = item && item.label && item.guid
? item.label: null;
if( spaceName ){
let obj = {};
obj[spaceName] = item.guid;
spaces.push( obj );
} else {
console.log( 'space name and/or space guid not found' );
}
});
success = true;
try {
const availableSpaces = await cfTools.cfGetAvailableSpaces( orgGuid );
if( !availableSpaces || !Array.isArray( availableSpaces ) || availableSpaces.length === 0 ){
return{ success: true, spaces: [], errorMessage: 'No Cloud Foundry spaces found.' };
}
const spaces = [];
availableSpaces.sort( ( a, b ) => {
if( a.label > b.label ) {
return 1;
} else if( a.label < b.label ) {
return-1;
}
return 0;
}).forEach( item => {
const spaceName = item && item.label && item.guid
? item.label: null;
if( spaceName ){
const obj = {};
obj[spaceName] = item.guid;
spaces.push( obj );
} else {
errorMessage = 'No Cloud Foundry spaces found.';
success = true;
console.log( 'space name and/or space guid not found' );
}
} catch( e ) {
errorMessage = 'Failed to fetch Cloud Foundry spaces, Reason: ' + e.message;
return{ success: false, spaces, errorMessage };
}
});
return{ success: true, spaces, errorMessage: '' };
} catch( e ) {
const errorMessage = 'Failed to fetch Cloud Foundry spaces, Reason: ' + e.message;
return{ success: false, spaces: [], errorMessage };
}
return{ success, spaces, errorMessage };
}

@@ -221,3 +217,3 @@

static async bindService( hdbModulePath, serviceName, resourceName ){
static async bindService( hdbModulePath, serviceName, resourceName, featureToggles ){
if( !path.isAbsolute( hdbModulePath ) ) {

@@ -231,2 +227,23 @@ // eslint-disable-next-line max-len

fs.chmodSync( dotenvPath, 0o600 );
if( featureToggles && featureToggles.isFeatureEnabled( 'quote_env_file' ) ) {
// The dotenv values must be quoted to prevent # characters from being interpreted as comments
let dotEnvContent = undefined;
try {
dotEnvContent = dotenv.parse( fs.readFileSync( dotenvPath ) );
} catch( e ) {
let errorMessage = 'An unknown error occurred.';
if( e instanceof Error ) {
errorMessage = e.message;
}
console.error( `Could not parse .env file: ${errorMessage}` );
}
let content = '';
for( const[ key, value ] of Object.entries( dotEnvContent ) ) {
content += `${key}='${value}'\n`;
}
fs.writeFileSync( dotenvPath, content );
}
}

@@ -239,3 +256,3 @@

if( cliResult.exitCode === 0 ){
let outputLines = cliResult.stdout.split( '\n' );
const outputLines = cliResult.stdout.split( '\n' );
outputLines.splice( 0, 3 );

@@ -262,3 +279,3 @@ outputLines.splice( -3, 3 );

console.log( 'Creating the "' + key + '" service key for the "' + serviceName + '" service...' );
let cliResult = await cfTools.Cli.execute( command );
const cliResult = await cfTools.Cli.execute( command );
if( cliResult.exitCode !== 0 ) {

@@ -271,3 +288,3 @@ throw new Error( 'Failed to create "' + key + '" service key for '

console.log( 'Creating the "' + instanceName + '" service...' );
let cliResult = await cfTools.apiCreateServiceInstance( serviceType, servicePlan, instanceName, config );
const cliResult = await cfTools.apiCreateServiceInstance( serviceType, servicePlan, instanceName, config );
if( cliResult.exitCode !== 0 ) {

@@ -283,3 +300,3 @@ throw new Error( 'Failed to create the service "' + instanceName + '"; Reason: '

do{
let cliResult = await cfTools.Cli.execute( [ 'service', instanceName ] );
const cliResult = await cfTools.Cli.execute( [ 'service', instanceName ] );
if( cliResult.exitCode !== 0 ) {

@@ -289,3 +306,3 @@ throw new Error( 'Failed to verify that the service "' + instanceName + '" has been created; Reason: '

}
let lines = cliResult.stdout.split( '\n' );
const lines = cliResult.stdout.split( '\n' );
properties = this._loadProperties( lines );

@@ -302,7 +319,7 @@ if( properties.status === 'create succeeded' ) {

static _loadProperties( lines ) {
let properties = {};
const properties = {};
lines.forEach( ( line ) => {
let pos = line.indexOf( ':' );
const pos = line.indexOf( ':' );
if( pos !== -1 ) {
let key = line.substring( 0, pos );
const key = line.substring( 0, pos );
let value = '';

@@ -377,5 +394,2 @@ if( pos + 1 < line.length ) {

static async getServiceInstanceList( cfSpaceGuid, dbVersion ) {
let serviceInstances = {};
let success = false;
let errorMessage = '';
if( !cfSpaceGuid || typeof cfSpaceGuid !== 'string' ){

@@ -385,7 +399,7 @@ throw new Error( `Cloud Foundry Space guid format error. expected: string(length > 0) found: ${typeof cfSpaceGuid}` );

const upsServiceResult = await Utils.getUserProvidedServiceInstances( cfSpaceGuid );
if( upsServiceResult.success === true ) {
serviceInstances = Object.assign({}, upsServiceResult.upsInstances );
} else {
return{ success: false, serviceInstances: serviceInstances, errorMessage: upsServiceResult.error };
if( upsServiceResult.success !== true ) {
return{ success: false, serviceInstances: {}, errorMessage: upsServiceResult.error };
}
const serviceInstances = Object.assign({}, upsServiceResult.upsInstances );
const isHanaTrialServiceAvailable = await Utils.isServiceAvailableInCfSpace( SERVICE_HANA_TRIAL, cfSpaceGuid );

@@ -401,31 +415,32 @@ try {

});
if( services && Array.isArray( services ) ){
if( services.length === 0 ){
console.log( 'No CF services found.' );
errorMessage = 'No CF services found.';
if( !services || !Array.isArray( services ) ){
const message = 'output is not in the expected format. Expected Array<services>, found: ';
const errorMessage = services ? `${message}${services}`: `${message}undefined`;
return{ success: false, serviceInstances, errorMessage };
}
if( services.length === 0 ){
const errorMessage = 'No CF services found.';
console.log( errorMessage );
return{ success: true, serviceInstances, errorMessage };
}
services.forEach( item => {
let serviceName = null;
if( isHanaTrialServiceAvailable ){
serviceName = Utils._parseServicesFromTrialLandscape( item, dbVersion );
} else {
services.forEach( item => {
serviceName = Utils._parseServiceByTypeAndPlan( item, HDI_SHARED, SERVICE_HANA );
}
let serviceName = null;
if( isHanaTrialServiceAvailable ){
serviceName = Utils._parseServicesFromTrialLandscape( item, dbVersion );
} else {
serviceName = Utils._parseServiceByTypeAndPlan( item, HDI_SHARED, SERVICE_HANA );
}
if( serviceName ){
serviceInstances[ serviceName ] = item.guid;
}
});
if( serviceName ){
serviceInstances[ serviceName ] = item.guid;
}
});
}
success = true;
} else {
const message = 'output is not in the expected format. Expected Array<services>, found: ';
errorMessage = services ? `${message}${services}`: `${message}undefined`;
}
return{ success: true, serviceInstances, errorMessage: '' };
} catch( e ) {
errorMessage = 'Could not parse the API response for the Cloud Foundry services list.';
const errorMessage = 'Could not parse the API response for the Cloud Foundry services list.';
return{ success: false, serviceInstances: {}, errorMessage };
}
return{ success, serviceInstances: serviceInstances, errorMessage };
}

@@ -437,10 +452,7 @@

}
let hanaCloudServiceInstances = {};
let success = false;
let errorMessage = '';
if( !cfSpaceGuid || typeof cfSpaceGuid !== 'string' ){
throw new Error( `Cloud Foundry Space guid format error. expected: string(length > 0) found: ${typeof cfSpaceGuid}` );
}
const serviceType = dbVersion === HANA_CLOUD || !FeatureToggles.isFeatureEnabled( 'hana_service' ) ? 'hana-cloud': 'hana-db';
const servicePlan = dbVersion === HANA_CLOUD || !FeatureToggles.isFeatureEnabled( 'hana_service' ) ? 'hana': null;
const serviceType = dbVersion === HANA_CLOUD ? 'hana-cloud': 'hana-db';
const servicePlan = dbVersion === HANA_CLOUD ? 'hana': null;
try {

@@ -455,33 +467,30 @@ const services = await cfTools.cfGetManagedServiceInstances({

});
if( services && Array.isArray( services ) ){
if( services.length === 0 ){
console.log( `No "SAP HANA Cloud" service instances found.` );
errorMessage = `No "SAP HANA Cloud" service instances found.`;
} else {
services.forEach( item => {
let serviceName = Utils._parseServiceByTypeAndPlan( item, servicePlan, serviceType );
if( serviceName ){
hanaCloudServiceInstances[ serviceName ] = item.guid;
}
});
}
success = true;
} else {
if( !services || !Array.isArray( services ) ){
const message = 'output is not in the expected format. Expected Array<services>, found: ';
errorMessage = services ?
const errorMessage = services ?
`${message}${services}`:
`${message}undefined`
;
return{ success: false, hanaCloudServiceInstances: {}, errorMessage };
}
if( services.length === 0 ){
const errorMessage = `No "SAP HANA Cloud" service instances found.`;
console.log( errorMessage );
return{ success: true, hanaCloudServiceInstances: {}, errorMessage };
}
const hanaCloudServiceInstances = {};
services.forEach( item => {
const serviceName = Utils._parseServiceByTypeAndPlan( item, servicePlan, serviceType );
if( serviceName ){
hanaCloudServiceInstances[ serviceName ] = item.guid;
}
});
return{ success: true, hanaCloudServiceInstances, errorMessage: '' };
} catch( e ) {
errorMessage = 'Failed to fetch "SAP HANA Cloud" service instances, Reason: ' + e.message;
const errorMessage = 'Failed to fetch "SAP HANA Cloud" service instances, Reason: ' + e.message;
return{ success: false, hanaCloudServiceInstances: {}, errorMessage };
}
return{ success, hanaCloudServiceInstances: hanaCloudServiceInstances, errorMessage };
}
static async getUserProvidedServiceInstances( cfSpaceGuid ){
const upsInstances = {};
let success = false;
let error = '';
try {

@@ -497,39 +506,43 @@ const ups = await cfTools.cfGetUpsInstances({

if( !ups || ups.length === 0 ) {
console.log( 'No Cloud Foundry user-provided services found.' );
error = 'No Cloud Foundry user-provided services found.';
success = true;
} else {
if( Array.isArray( ups ) ){
ups.forEach( resource => {
let serviceName = null;
const serviceTags = resource.tags || [];
if( Array.isArray( serviceTags ) ){
serviceTags.some( tag => {
if( tag && typeof tag === 'string' && tag.toLowerCase() === 'hana' ) {
serviceName = resource.label;
return true;
}
});
} else if( typeof serviceTags === 'string' ){
serviceName = serviceTags.toLowerCase() === 'hana' ?
resource.label :
null;
}
const error = 'No Cloud Foundry user-provided services found.';
console.log( error );
return{ upsInstances: {}, error, success: true };
}
if( !Array.isArray( ups ) ){
const error = 'output is not in the expected format.';
return{ upsInstances: {}, error, success: false };
}
if( resource.guid && serviceName ){
upsInstances[ serviceName ] = resource.guid;
}
});
success = true;
} else {
error = 'output is not in the expected format.';
const upsInstances = {};
ups.forEach( resource => {
const serviceName = Utils.getServiceNameFromResource( resource );
if( resource.guid && serviceName ){
upsInstances[ serviceName ] = resource.guid;
}
}
});
return{ upsInstances, error: '', success: true };
} catch( e ) {
error = 'Failed to fetch user-provided service instances, Reason: ' + e.message;
const error = 'Failed to fetch user-provided service instances, Reason: ' + e.message;
return{ upsInstances: {}, error, success: false };
}
return{ upsInstances, error, success };
}
static getServiceNameFromResource( resource ) {
let serviceName = null;
const serviceTags = resource.tags || [];
if( Array.isArray( serviceTags ) ){
serviceTags.some( tag => {
if( tag && typeof tag === 'string' && tag.toLowerCase() === 'hana' ) {
serviceName = resource.label;
return true;
}
});
} else if( typeof serviceTags === 'string' ){
serviceName = serviceTags.toLowerCase() === 'hana' ?
resource.label :
null;
}
return serviceName;
}
static commandExists( commandName ){

@@ -536,0 +549,0 @@ return commandExistsSync( commandName );

'use strict';
const Utils = require( './generator-hdb-module/Utils' );
const isValid = ( text, errorMessge ) => {
if( RegExp( /[a-zA-Z]/ ).test( text.charAt( 0 ) ) &&
RegExp( /^[a-zA-Z0-9._-]+$/ ).test( text ) &&
!RegExp( /\.\./ ).test( text ) &&
!RegExp( /\.-/ ).test( text ) &&
!RegExp( /\.[0-9]/ ).test( text ) &&
RegExp( /[a-zA-Z0-9-_]/ ).test( text.charAt( text.length - 1 ) )
) {
if( /[/:]/.test( text ) ) {
return errorMessge;
} else {
return true;
} else {
return errorMessge;
}

@@ -19,3 +13,5 @@ };

const validateSchemaName = ( schemaName ) => {
if( !schemaName ) return true;
if( !schemaName ) {
return true;
}

@@ -22,0 +18,0 @@ if( !RegExp( /[a-zA-Z0-9]/ ).test( schemaName.charAt( 0 ) ) ||

{
"name": "@sap/generator-add-hdb-module",
"version": "1.4.0",
"version": "1.5.0",
"lockfileVersion": 1,

@@ -19,4 +19,4 @@ "requires": true,

"@babel/highlight": {
"version": "7.16.10",
"integrity": "sha512-5FnTQLSLswEj6IkgVw5KusNUUFY9ZGqe/TRFnP/BKYHYgfh7tc+C7mwiy95/yNP7Dh9x580Vv8r7u7ZfTBFxdw==",
"version": "7.17.12",
"integrity": "sha512-7yykMVF3hfZY2jsHZEEgLc+3x4o1O+fYyULu11GynEUQNwB6lua+IIQn1FiJxNucd5UlyJryrwsOh8PL9Sn8Qg==",
"requires": {

@@ -67,10 +67,10 @@ "@babel/helper-validator-identifier": "^7.16.7",

"@octokit/openapi-types": {
"version": "11.2.0",
"integrity": "sha512-PBsVO+15KSlGmiI8QAzaqvsNlZlrDlyAJYcrXBCvVUxCp7VnXjkwPoFHgjEJXx3WF9BAwkA6nfCUA7i9sODzKA=="
"version": "12.4.0",
"integrity": "sha512-Npcb7Pv30b33U04jvcD7l75yLU0mxhuX2Xqrn51YyZ5WTkF04bpbxLaZ6GcaTqu03WZQHoO/Gbfp95NGRueDUA=="
},
"@octokit/plugin-paginate-rest": {
"version": "2.17.0",
"integrity": "sha512-tzMbrbnam2Mt4AhuyCHvpRkS0oZ5MvwwcQPYGtMv4tUa5kkzG58SVB0fcsLulOZQeRnOgdkZWkRUiyBlh0Bkyw==",
"version": "2.19.0",
"integrity": "sha512-hQ4Qysg2hNmEMuZeJkvyzM4eSZiTifOKqYAMsW8FnxFKowhuwWICSgBQ9Gn9GpUmgKB7qaf1hFvMjYaTAg5jQA==",
"requires": {
"@octokit/types": "^6.34.0"
"@octokit/types": "^6.36.0"
}

@@ -83,6 +83,6 @@ },

"@octokit/plugin-rest-endpoint-methods": {
"version": "5.13.0",
"integrity": "sha512-uJjMTkN1KaOIgNtUPMtIXDOjx6dGYysdIFhgA52x4xSadQCz3b/zJexvITDVpANnfKPW/+E0xkOvLntqMYpviA==",
"version": "5.15.0",
"integrity": "sha512-Gsw9+Xm56jVhfbJoy4pt6eOOyf8/3K6CAnx1Sl7U2GhZWcg8MR6YgXWnpfdF69S2ViMXLA7nfvTDAsZpFlkLRw==",
"requires": {
"@octokit/types": "^6.34.0",
"@octokit/types": "^6.36.0",
"deprecation": "^2.3.1"

@@ -123,6 +123,6 @@ }

"@octokit/types": {
"version": "6.34.0",
"integrity": "sha512-s1zLBjWhdEI2zwaoSgyOFoKSl109CUcVBCc7biPJ3aAf6LGLU6szDvi31JPU7bxfla2lqfhjbbg/5DdFNxOwHw==",
"version": "6.37.0",
"integrity": "sha512-BXWQhFKRkjX4dVW5L2oYa0hzWOAqsEsujXsQLSdepPoDZfYdubrD1KDGpyNldGXtR8QM/WezDcxcIN1UKJMGPA==",
"requires": {
"@octokit/openapi-types": "^11.2.0"
"@octokit/openapi-types": "^12.4.0"
}

@@ -142,6 +142,6 @@ },

"@sap/cf-tools": {
"version": "2.1.1",
"integrity": "sha512-GM1Os0/zLyJNNSwKawOy1zRC38qMg8K/gUvxThbqDKuwfR5raMZZjlHwuoLgF74MsJJ+kDDk71LWRJn9WWzH4w==",
"version": "3.0.3",
"integrity": "sha512-Z12MNlLKT6ZHKrNrzHewvTxFt/WQUiz3o3iCNNF8fgIFtt0wKKZ/8iLG0xZeaRbR7RdGNugWD40fjseAEWTMmw==",
"requires": {
"comment-json": "4.1.0",
"comment-json": "4.2.2",
"lodash": "4.17.21",

@@ -241,20 +241,4 @@ "properties-reader": "2.2.0",

"@sap/hana-tooling-feature-toggles": {
"version": "1.0.1",
"integrity": "sha512-/nuvymtuXGk/ppsyhvS/WTUlYRYINTkIva0OB6OHNXxp0DGJ3yaEFRBlLdbr8bEKqQ9RUbm7j1DvjUvbnVl5kQ==",
"requires": {
"optional-require": "1.1.8"
},
"dependencies": {
"optional-require": {
"version": "1.1.8",
"integrity": "sha512-jq83qaUb0wNg9Krv1c5OQ+58EK+vHde6aBPzLvPPqJm89UQWsvSuFy9X/OSNJnFeSOKo7btE0n8Nl2+nE+z5nA==",
"requires": {
"require-at": "^1.0.6"
}
},
"require-at": {
"version": "1.0.6",
"integrity": "sha512-7i1auJbMUrXEAZCOQ0VNJgmcT2VOKPRl2YGJwgpHpC9CE91Mv4/4UYIUm4chGJaI381ZDq1JUicFii64Hapd8g=="
}
}
"version": "1.1.0",
"integrity": "sha512-1XIvzXtNMX0xFV9fhFkGsHmSg7GxI99+9gYy8pRGoeKAZP9qhcEOZMcAqnuQcfqI2y5ikYfEODF80yQsRTYyOg=="
},

@@ -325,3 +309,3 @@ "@sap/mta-lib": {

"version": "0.0.2",
"integrity": "sha1-wKHS86cJLgN3S/qD8UwPxXkKhmc="
"integrity": "sha512-yrLQ/yVUFXkzg7EDQsPieE/53+0RlaWTs+wBrvW36cyilJ2SaDWfl4Yj7MtLTXleV9uEKefbAGUPv2/iWSooRA=="
},

@@ -337,3 +321,3 @@ "color-convert": {

"version": "1.1.3",
"integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU="
"integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw=="
},

@@ -345,7 +329,7 @@ "command-exists": {

"comment-json": {
"version": "4.1.0",
"integrity": "sha512-WEghmVYaNq9NlWbrkzQTSsya9ycLyxJxpTQfZEan6a5Jomnjw18zS3Podf8q1Zf9BvonvQd/+Z7Z39L7KKzzdQ==",
"version": "4.2.2",
"integrity": "sha512-H8T+kl3nZesZu41zO2oNXIJWojNeK3mHxCLrsBNu6feksBXsgb+PtYz5daP5P86A0F3sz3840KVYehr04enISQ==",
"requires": {
"array-timsort": "^1.0.3",
"core-util-is": "^1.0.2",
"core-util-is": "^1.0.3",
"esprima": "^4.0.1",

@@ -358,3 +342,3 @@ "has-own-prop": "^2.0.0",

"version": "0.0.1",
"integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s="
"integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg=="
},

@@ -376,3 +360,3 @@ "core-util-is": {

"version": "0.0.2",
"integrity": "sha1-iNf/fsDfuG9xPch7u0LQRNPmxBs="
"integrity": "sha512-mCxBlsHFYh9C+HVpiEacem8FEBnMXgU9gy4zmNC+SXAZNB/1idgp/aulFJ4FgCi7GPEVbfyng092GqL2k2rmow=="
},

@@ -394,2 +378,6 @@ "dargs": {

},
"dotenv": {
"version": "16.0.1",
"integrity": "sha512-1K6hR6wtk2FviQ4kEiSjFiH5rpzEVi8WW0x96aztHVMhEspNpc4DVOUTEHtEva5VThQ8IaBX1Pe4gSzpVVUsKQ=="
},
"end-of-stream": {

@@ -411,3 +399,3 @@ "version": "1.4.4",

"version": "1.0.5",
"integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ="
"integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg=="
},

@@ -443,3 +431,3 @@ "esprima": {

"version": "1.0.0",
"integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8="
"integrity": "sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw=="
},

@@ -465,4 +453,4 @@ "function-bind": {

"glob": {
"version": "7.2.0",
"integrity": "sha512-lmLf6gtyrPq8tTjSmrO94wBeQbFR3HbLHbuyD69wuyQkImp2hWqMGB47OX65FBkPffO641IP9jWa1z4ivqG26Q==",
"version": "7.2.3",
"integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==",
"requires": {

@@ -472,3 +460,3 @@ "fs.realpath": "^1.0.0",

"inherits": "2",
"minimatch": "^3.0.4",
"minimatch": "^3.1.1",
"once": "^1.3.0",

@@ -479,4 +467,4 @@ "path-is-absolute": "^1.0.0"

"graceful-fs": {
"version": "4.2.9",
"integrity": "sha512-NtNxqUcXgpW2iMrfqSfR73Glt39K+BLwWsPs94yR63v45T0Wbej7eRmL5cWfwEgqXnmjQp3zaJTshdRW/qC2ZQ=="
"version": "4.2.10",
"integrity": "sha512-9ByhssR2fPVsNZj478qUUbKfmL0+t5BDVyjShtyZZLiK7ZDAArFFfopyOTj0M05wE2tJPisA4iTnnXl2YoPvOA=="
},

@@ -492,3 +480,3 @@ "has": {

"version": "3.0.0",
"integrity": "sha1-tdRU3CGZriJWmfNGfloH87lVuv0="
"integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw=="
},

@@ -509,3 +497,3 @@ "has-own-prop": {

"version": "1.0.6",
"integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=",
"integrity": "sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==",
"requires": {

@@ -526,3 +514,3 @@ "once": "^1.3.0",

"version": "0.2.1",
"integrity": "sha1-d8mYQFJ6qOyxqLppe4BkWnqSap0="
"integrity": "sha512-zz06S8t0ozoDXMG+ube26zeCTNXcKIPJZJi8hBrF4idCLms4CG9QtK7qBl1boi5ODzFpjswb5JPmHCbMpjaYzg=="
},

@@ -534,4 +522,4 @@ "is-buffer": {

"is-core-module": {
"version": "2.8.1",
"integrity": "sha512-SdNCUs284hr40hFTFP6l0IfZ/RSrMXF3qgoRHd3/79unUTvrFO/JoXwkGm+5J/Oe3E/b5GsnG330uUNgRpu1PA==",
"version": "2.9.0",
"integrity": "sha512-+5FPy5PnwmO3lvfMb0AsoPaBG+5KHUI0wYFXOtYPnVVVspTFUuMZNfNaNVRt3FZadstu2c8x23vykRW/NBoU6A==",
"requires": {

@@ -555,3 +543,3 @@ "has": "^1.0.3"

"version": "2.0.0",
"integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA="
"integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw=="
},

@@ -568,3 +556,3 @@ "js-tokens": {

"version": "4.0.0",
"integrity": "sha1-h3Gq4HmbZAdrdmQPygWPnBDjPss=",
"integrity": "sha512-m6F1R3z8jjlf2imQHS2Qez5sjKWQzbuuhuJ/FKYFRZvPE3PuHcSMVZzfsLhGVOkfd20obL5SWEBew5ShlquNxg==",
"requires": {

@@ -668,3 +656,3 @@ "graceful-fs": "^4.1.6"

"version": "1.4.0",
"integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=",
"integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==",
"requires": {

@@ -715,3 +703,3 @@ "wrappy": "1"

"version": "1.0.1",
"integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18="
"integrity": "sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg=="
},

@@ -743,7 +731,7 @@ "path-key": {

"version": "1.3.2",
"integrity": "sha1-llOgNvt8HuQjQvIyXM7v6jkmxI0="
"integrity": "sha512-RofWgt/7fL5wP1Y7fxE7/EmTLzQVnB0ycyibJ0OOHIlJqTNzglYFxVwETOcIoJqJmpDXJ9xImDv+Fq34F/d4Dw=="
},
"querystring": {
"version": "0.2.0",
"integrity": "sha1-sgmEkgO7Jd+CDadW50cAWHhSFiA="
"integrity": "sha512-X/xY82scca2tau62i9mDyU9K+I+djTMUsvwf7xnUX5GLvVzgJybOJf4Y6o9Zx3oJK/LSXg5tTZBjwzqVPaPO2g=="
},

@@ -777,3 +765,3 @@ "read-pkg": {

"version": "0.6.2",
"integrity": "sha1-hSBLVNuoLVdC4oyWdW70OvUOM4Q=",
"integrity": "sha512-HFM8rkZ+i3zrV+4LQjwQ0W+ez98pApMGM3HUrN04j3CqzPOzl9nmP15Y8YXNm8QHGv/eacOVEjqhmWpkRV0NAw==",
"requires": {

@@ -785,9 +773,9 @@ "resolve": "^1.1.6"

"version": "1.6.1",
"integrity": "sha1-jcrkcOHIirwtYA//Sndihtp15jc="
"integrity": "sha512-PV0dzCYDNfRi1jCDbJzpW7jNNDRuCOG/jI5ctQcGKt/clZD+YcPS3yIlWuTJMmESC8aevCFmWJy5wjAFgNqN6w=="
},
"resolve": {
"version": "1.22.0",
"integrity": "sha512-Hhtrw0nLeSrFQ7phPp4OOcVjLPIeMnRlr5mcnVuMe7M/7eBn98A3hmFRLoFo3DLZkivSYwhRUJTyPyWAk56WLw==",
"version": "1.22.1",
"integrity": "sha512-nBpuuYuY5jFsli/JIs1oldw6fOQCBioohqWZg/2hiaOybXOft4lonv85uDOKXdf8rhyK159cxU5cDcK/NKk8zw==",
"requires": {
"is-core-module": "^2.8.1",
"is-core-module": "^2.9.0",
"path-parse": "^1.0.7",

@@ -809,4 +797,4 @@ "supports-preserve-symlinks-flag": "^1.0.0"

"semver": {
"version": "7.3.5",
"integrity": "sha512-PoeGJYh8HK4BTO/a9Tf6ZG3veo/A7ZVsYrSA6J8ny9nb3B1VrpkuN+z9OE5wfE5p6H4LchYZsegiQgbJD94ZFQ==",
"version": "7.3.7",
"integrity": "sha512-QlYTucUYOews+WeEujDoEGziz4K6c47V/Bd+LjSSYcA94p+DmINdf7ncaUinThfvZyu13lN9OY1XDxt8C0Tw0g==",
"requires": {

@@ -892,7 +880,7 @@ "lru-cache": "^6.0.0"

"version": "0.2.0",
"integrity": "sha1-f17oI66AUgfACvLfSoTsP8+lcLQ="
"integrity": "sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw=="
},
"tr46": {
"version": "0.0.3",
"integrity": "sha1-gYT9NH2snNwYWZLzpmIuFLnZq2o="
"integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw=="
},

@@ -913,3 +901,3 @@ "type-fest": {

"version": "0.11.0",
"integrity": "sha1-ODjpfPxgUh63PFJajlW/3Z4uKPE=",
"integrity": "sha512-kbailJa29QrtXnxgq+DdCEGlbTeYM2eJUxsz6vjZavrCYPMIFHMKQmSKYAIuUK2i7hgPm28a8piX5NTUtM/LKQ==",
"requires": {

@@ -938,7 +926,7 @@ "punycode": "1.3.2",

"version": "3.0.1",
"integrity": "sha1-JFNCdeKnvGvnvIZhHMFq4KVlSHE="
"integrity": "sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ=="
},
"whatwg-url": {
"version": "5.0.0",
"integrity": "sha1-lmRU6HZUYuN2RNNib2dCzotwll0=",
"integrity": "sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==",
"requires": {

@@ -958,3 +946,3 @@ "tr46": "~0.0.3",

"version": "1.0.2",
"integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8="
"integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ=="
},

@@ -961,0 +949,0 @@ "yallist": {

{
"name": "@sap/generator-add-hdb-module",
"displayName": "SAP HANA Database Module",
"version": "1.4.0",
"version": "1.5.0",
"description": "A database module contains design-time database artifacts. On deployment, a database module is assigned an HDI container to which the corresponding run-time database objects are deployed.",

@@ -30,7 +30,8 @@ "license": "SEE LICENSE IN LICENSE",

"@sap-devx/yeoman-ui-types": "1.3.1",
"@sap/cf-tools": "2.1.1",
"@sap/cf-tools": "3.0.3",
"@sap/generator-base-mta-module": "1.3.7",
"@sap/hana-tooling-feature-toggles": "1.0.1",
"@sap/hana-tooling-feature-toggles": "1.1.0",
"@sap/mta-lib": "1.7.4",
"command-exists": "1.2.9",
"dotenv": "16.0.1",
"md5": "2.3.0",

@@ -37,0 +38,0 @@ "rimraf": "3.0.2",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc