opticore-webapp-core 1.0.3 → 1.0.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -48,8 +48,7 @@ __export(index_exports, {
48
48
  YamlParsing: () => YamlParsing,
49
49
  dateTimeFormatted: () => dateTimeFormatted,
50
50
  loggerConfig: () => loggerConfig,
51
- optionalArgumentConnectionUtil: () => optionalArgumentConnectionUtil,
52
- translateWebAppCoreLanguageLoader: () => translateWebAppCoreLanguageLoader
51
+ optionalArgumentConnectionUtil: () => optionalArgumentConnectionUtil
53
52
  });
54
53
  module.exports = __toCommonJS(index_exports);
55
54
 
@@ -1156,9 +1155,14 @@ var import_url = require("url");
1156
1155
  var translateWebAppCoreLanguageLoader = () => {
1157
1156
  const __filename2 = (0, import_url.fileURLToPath)(importMetaUrl);
1158
1157
  const __dirname = import_path3.default.dirname(__filename2);
1159
- const translateMsgJsonFilePath = import_path3.default.join(__dirname, "../../../", "utils", "translations");
1158
+ const translateMsgJsonFilePath = import_path3.default.join(__dirname, "../../../../", "dist", "utils", "translations");
1160
1159
  import_opticore_translator11.TranslationLoader.loadTranslations(translateMsgJsonFilePath, import_opticore_env_access4.getEnvVariable.defaultLocal);
1161
1160
  };
1161
+
1162
+ // src/index.ts
1163
+ (() => {
1164
+ translateWebAppCoreLanguageLoader();
1165
+ })();
1162
1166
  // Annotate the CommonJS export names for ESM import in node:
1163
1167
  0 && (module.exports = {
1164
1168
  CLogLevel,
@@ -1179,6 +1183,5 @@ var translateWebAppCoreLanguageLoader = () => {
1179
1183
  YamlParsing,
1180
1184
  dateTimeFormatted,
1181
1185
  loggerConfig,
1182
- optionalArgumentConnectionUtil,
1183
- translateWebAppCoreLanguageLoader
1186
+ optionalArgumentConnectionUtil
1184
1187
  });
package/dist/index.d.cts CHANGED
@@ -363,8 +363,6 @@ declare class PathModuleVerifier {
363
363
  private static isModulePathLoaded;
364
364
  }
365
365
 
366
- declare const translateWebAppCoreLanguageLoader: () => void;
367
-
368
366
  interface IBodyParserOptions {
369
367
  type: string;
370
368
  }
@@ -435,4 +433,4 @@ declare function TTextBodyParser(options: IBodyParserOptions): void;
435
433
  */
436
434
  declare function TUrlencodedBodyParser(options: IBodyParserOptions): void;
437
435
 
438
- export { CLogLevel, CSignRSAKeyComponent, Environment, type IBodyParserOptions, type IResponseBodyEndFromResponseEvent, type IResponseBodyWriteFromResponseEvent, type IWrappingBodyResponse, MMongoCheckerDatabase, MMySqlCheckerDatabase, MPostgresCheckerDatabase, PathModuleVerifier, RSAKeyDecryption, RSAKeyEncryption, SAsymmetricCryptionDataWithPrivateRSAKey, SAsymmetricCryptionDataWithPublicRSAKey, SCheckerMongoDatabaseConnection, SCheckerMySqlDatabaseConnection, SCheckerPostgresDatabaseConnection, TJSONBodyParser, type TLogLevel, type TOriginalWriteEncoding, type TParseFunction, TRawBodyParser, TTextBodyParser, TUrlencodedBodyParser, Utility, YamlParsing, dateTimeFormatted, loggerConfig, optionalArgumentConnectionUtil, translateWebAppCoreLanguageLoader };
436
+ export { CLogLevel, CSignRSAKeyComponent, Environment, type IBodyParserOptions, type IResponseBodyEndFromResponseEvent, type IResponseBodyWriteFromResponseEvent, type IWrappingBodyResponse, MMongoCheckerDatabase, MMySqlCheckerDatabase, MPostgresCheckerDatabase, PathModuleVerifier, RSAKeyDecryption, RSAKeyEncryption, SAsymmetricCryptionDataWithPrivateRSAKey, SAsymmetricCryptionDataWithPublicRSAKey, SCheckerMongoDatabaseConnection, SCheckerMySqlDatabaseConnection, SCheckerPostgresDatabaseConnection, TJSONBodyParser, type TLogLevel, type TOriginalWriteEncoding, type TParseFunction, TRawBodyParser, TTextBodyParser, TUrlencodedBodyParser, Utility, YamlParsing, dateTimeFormatted, loggerConfig, optionalArgumentConnectionUtil };
package/dist/index.d.ts CHANGED
@@ -363,8 +363,6 @@ declare class PathModuleVerifier {
363
363
  private static isModulePathLoaded;
364
364
  }
365
365
 
366
- declare const translateWebAppCoreLanguageLoader: () => void;
367
-
368
366
  interface IBodyParserOptions {
369
367
  type: string;
370
368
  }
@@ -435,4 +433,4 @@ declare function TTextBodyParser(options: IBodyParserOptions): void;
435
433
  */
436
434
  declare function TUrlencodedBodyParser(options: IBodyParserOptions): void;
437
435
 
438
- export { CLogLevel, CSignRSAKeyComponent, Environment, type IBodyParserOptions, type IResponseBodyEndFromResponseEvent, type IResponseBodyWriteFromResponseEvent, type IWrappingBodyResponse, MMongoCheckerDatabase, MMySqlCheckerDatabase, MPostgresCheckerDatabase, PathModuleVerifier, RSAKeyDecryption, RSAKeyEncryption, SAsymmetricCryptionDataWithPrivateRSAKey, SAsymmetricCryptionDataWithPublicRSAKey, SCheckerMongoDatabaseConnection, SCheckerMySqlDatabaseConnection, SCheckerPostgresDatabaseConnection, TJSONBodyParser, type TLogLevel, type TOriginalWriteEncoding, type TParseFunction, TRawBodyParser, TTextBodyParser, TUrlencodedBodyParser, Utility, YamlParsing, dateTimeFormatted, loggerConfig, optionalArgumentConnectionUtil, translateWebAppCoreLanguageLoader };
436
+ export { CLogLevel, CSignRSAKeyComponent, Environment, type IBodyParserOptions, type IResponseBodyEndFromResponseEvent, type IResponseBodyWriteFromResponseEvent, type IWrappingBodyResponse, MMongoCheckerDatabase, MMySqlCheckerDatabase, MPostgresCheckerDatabase, PathModuleVerifier, RSAKeyDecryption, RSAKeyEncryption, SAsymmetricCryptionDataWithPrivateRSAKey, SAsymmetricCryptionDataWithPublicRSAKey, SCheckerMongoDatabaseConnection, SCheckerMySqlDatabaseConnection, SCheckerPostgresDatabaseConnection, TJSONBodyParser, type TLogLevel, type TOriginalWriteEncoding, type TParseFunction, TRawBodyParser, TTextBodyParser, TUrlencodedBodyParser, Utility, YamlParsing, dateTimeFormatted, loggerConfig, optionalArgumentConnectionUtil };
package/dist/index.js CHANGED
@@ -1104,9 +1104,14 @@ import { fileURLToPath } from "url";
1104
1104
  var translateWebAppCoreLanguageLoader = () => {
1105
1105
  const __filename2 = fileURLToPath(import.meta.url);
1106
1106
  const __dirname2 = path2.dirname(__filename2);
1107
- const translateMsgJsonFilePath = path2.join(__dirname2, "../../../", "utils", "translations");
1107
+ const translateMsgJsonFilePath = path2.join(__dirname2, "../../../../", "dist", "utils", "translations");
1108
1108
  TranslationLoader11.loadTranslations(translateMsgJsonFilePath, getEnvVariable4.defaultLocal);
1109
1109
  };
1110
+
1111
+ // src/index.ts
1112
+ (() => {
1113
+ translateWebAppCoreLanguageLoader();
1114
+ })();
1110
1115
  export {
1111
1116
  CLogLevel,
1112
1117
  CSignRSAKeyComponent,
@@ -1126,6 +1131,5 @@ export {
1126
1131
  YamlParsing,
1127
1132
  dateTimeFormatted,
1128
1133
  loggerConfig,
1129
- optionalArgumentConnectionUtil,
1130
- translateWebAppCoreLanguageLoader
1134
+ optionalArgumentConnectionUtil
1131
1135
  };
@@ -0,0 +1,130 @@
1
+ {
2
+ "erBadDbError": "ER_BAD_DB_ERROR",
3
+ "erAccessDeniedError": "ER_ACCESS_DENIED_ERROR",
4
+ "erNotSupportedAuthMode": "ER_NOT_SUPPORTED_AUTH_MODE",
5
+ "eAiAgain": "EAI_AGAIN",
6
+ "dbConnection": "Database connection",
7
+ "dbConnectionClosed": "MySQL connection is closed",
8
+ "mysqlErrorCon": "MysqlError connection",
9
+ "mySQLError": "MysqlError",
10
+ "mySqlCloseConnection": "MySql close connection",
11
+ "dbConnexionSuccess": "The database connection was successful 🚀",
12
+ "mongoConnectionSuccess": "Connection to database is successfully.",
13
+ "connSuccess": "success connection",
14
+ "mongoDBConnectionChecker": "MongoDB Connection Checker",
15
+ "mongoConnection": "connection",
16
+ "mongoDBAuthentication": "authentication",
17
+ "mongoDBConnection": "MongoDB connection",
18
+ "mongoDBAuthenticationFailed": "failed",
19
+ "mongoDBUnableParsingUrl": "unable to parse",
20
+ "mongoDBConnectionUrl": "url",
21
+ "mongoDBServerSelection": "MongoServer selection error",
22
+ "mongoDBServer": "MongoServer",
23
+ "mongoDBConnectionError": "connection error",
24
+ "mongoDBError": "error",
25
+ "mongoDBAuthenticationError": "Authentication failed, be sure the credentials is correct.",
26
+ "postgresDBConnectionChecker": "PostgresDB Connection Checker",
27
+ "postgresConnection": "connection",
28
+ "postgresConnectionSuccess": "Connection to database is successfully.",
29
+ "postgresSuccessConn": "Postgres client Connection",
30
+ "postgresClosingConnSuccess": "Postgres client is close connection.",
31
+ "postgresEndClientRejection": "Postgres client end rejected",
32
+ "postgresClientError": "Postgres client error",
33
+ "postgresEndRejection": "End rejected",
34
+ "postgresConnError": "Postgres connection error",
35
+ "postgresException": "Exception",
36
+ "rsaKeyNotFound": "RSA key provided is not found.",
37
+ "encryptionWithPrivateKeyFailed": "Encryption With PrivateKey",
38
+ "encryptionFailed": "Encryption failed",
39
+ "verifyExistingKey": "Verify Existing Key",
40
+ "signatureRSAKeyFailed": "Signature verification failed.",
41
+ "signatureRSAKeysError": "Signature RSA Keys Error",
42
+ "errorDecryption": "Error decryption with private key",
43
+ "errorNameNotVerifyingRSAKey": "Error Verify RSA Key",
44
+ "decryptionWithPublicKeyFailed": "Decryption With PublicKey",
45
+ "decryptionFailed": "Decryption failed",
46
+ "verifyRSAKey": "Verify RSA Keys",
47
+ "verifyRSAKeyFailed": "Verify RSA Keys Failed",
48
+ "notVerifying": "Verification failed",
49
+ "mongoServerError": "MongoServerSelectionError: getaddrinfo EAI_AGAIN ({dbHost} is not allow to database connection)",
50
+ "dbUrlParsingError": "Unable to parse {dbHost}:{dbPort} with URL",
51
+ "errorDBHost": "A database host {host} does not allow connection. Please either set the host like this: {localhost} in your .env file",
52
+ "unknownDB": "Database {database} is unknown. Please try to use Database CLI to create your database, or do it manually in your Database Management System",
53
+ "accessDeniedToDBCon": "Access denied for user {user}. Database credentials in .env file are User: {user} and Password: {password}. '{user}''{password}'@'localhost'. Try to set user and password in .env file",
54
+ "badFormat": "Unsupported YAML line format",
55
+ "parsingFailed": "YAML Parsing failed",
56
+ "unsupportedFormat": "Unsupported YAML format",
57
+ "readingError": "Error reading YAML file",
58
+ "invalidRequest": "Invalid request",
59
+ "moduleNotLoaded": "The following module paths are not loaded: {notLoadedPaths}",
60
+ "serverRouteNotExist": "This route : http://{host}:{port} do not exist.",
61
+ "webServer": "Web server",
62
+ "listening": "listening",
63
+ "webHost": "host",
64
+ "badHost": "bad host",
65
+ "hostNotFound": "not found",
66
+ "errorHostUrl": "The host and port are not define, please define them in .env",
67
+ "badPort": "bad port",
68
+ "errorPort": "The port is not correct. Please define a right port with number port.",
69
+ "errorHost": "The host can't be empty or blank. Please define a string host in .env",
70
+ "serverStart": "Server start",
71
+ "serverStartError": "Server start error",
72
+ "processExitCode": "Process will exit with code: {code}",
73
+ "beforeExit": "BeforeExit",
74
+ "processBeforeExit": "process before exit",
75
+ "childProcessDiscon": "Child process disconnected",
76
+ "processDiscon": "process disconnected",
77
+ "disconnected": "Disconnected",
78
+ "completed": "completed",
79
+ "finishingProcessWell": "The process finished as expected and everything is ok",
80
+ "serverStopped": "[OK] The server shutting down",
81
+ "somethingWentWrong": "Something went wrong",
82
+ "genErrors": "General Errors",
83
+ "exited": "Exited",
84
+ "incorrectCmd": "Incorrect using of shell commands",
85
+ "misuseShell": "Misuse of shell builtins",
86
+ "cmdNotExecutable": "The command is found but is not executable (e.g., trying to execute a directory)",
87
+ "cmdNotFound": "Command not found",
88
+ "cmdNotFoundInSystemPath": "The command was not found in the system's PATH or is misspelled",
89
+ "argInvalid": "Invalid argument",
90
+ "scriptEndedManuallyByCtrlC": "Indicates that the script was manually terminated by the user using the Control-C (SIGINT) signal",
91
+ "processEndedBySIGKILL": "Indicates that the process was terminated by a SIGKILL signal, possibly due to an out-of-memory situation",
92
+ "scriptEnded": "Script terminated",
93
+ "accessProcessIllegally": "Indicates that the process accessed an illegal memory address (segfault)",
94
+ "defaultSegment": "Segmentation fault",
95
+ "processReceivedSigtermSignal": "Indicates that the process received a SIGTERM signal to terminate",
96
+ "processReceived": "process received a SIGTERM",
97
+ "exitCode": "An exit code that is outside the allowable range (0-255 for Unix-like systems)",
98
+ "outRange": "out of range",
99
+ "errorOccurring": "Error is occurring",
100
+ "errors": "errors",
101
+ "promiseRejectionHandled": "Promise rejection is handled at : {promise}",
102
+ "rejectionPromise": "rejection promise",
103
+ "uncaughtExceptionHandled": "uncaught exception handled",
104
+ "unhandledRejectionAtPromise": "Unhandled Rejection at: Promise {promise} -- reason {reason}",
105
+ "unhandledRejection": "Unhandled rejection",
106
+ "processGotMsg": "process got message {message}",
107
+ "msgException": "message exception",
108
+ "promiseReason": "{promise} -- {reason}",
109
+ "multipleResolvesDetected": "Multiple resolves detected : {type}",
110
+ "serverWebStopped": "The Web server has been stopped !",
111
+ "okSuccess": "[ OK ] Success",
112
+ "processPIDReceivedSignal": "Process ${process.pid} received a SIGTERM signal : {signal}",
113
+ "serverClosed": "Server is closed",
114
+ "allProcessStopped": "All processes are stopped",
115
+ "serverDroppedCon": "The server dropped new connections",
116
+ "serverMaxCon": "Server maxConnection",
117
+ "internalServerError": "Internal Server Error",
118
+ "resStatusNotFunc": "res.status is not a function",
119
+ "respndNotFunc": "response not Function",
120
+ "expressErrorHandlingMiddleware": "Express error-handling middleware",
121
+ "expressError": "Express error",
122
+ "serverRunning": "The server is running in",
123
+ "okServerListening": "[OK] Web server listening",
124
+ "webServerUseNodeVersion": "The Web server is using Node.js version",
125
+ "startupTime": "Startup time:",
126
+ "totalMemory": "Resident Set Size - total memory allocated for the process execution :",
127
+ "memoryUsedDuringExecution": "Actual memory used during the execution :",
128
+ "memoryUsedByUser": "Memory usage by user :",
129
+ "memoryUsedBySystem": "Memory usage by system :"
130
+ }
@@ -0,0 +1,49 @@
1
+ {
2
+ "erBadDbError": "ER_BAD_DB_ERROR",
3
+ "erAccessDeniedError": "ER_ACCESS_DENIED_ERROR",
4
+ "erNotSupportedAuthMode": "ER_NOT_SUPPORTED_AUTH_MODE",
5
+ "eAiAgain": "EAI_AGAIN",
6
+ "dbConnection": "DataBase connection",
7
+ "dbConnectionClosed": "MySQL connection is closed",
8
+ "mysqlErrorCon": "MysqlError connection",
9
+ "mySQLError": "MysqlError",
10
+ "mySqlCloseConnection": "MySql close connection",
11
+ "mongoConnectionSuccess": "Connection to database is successfully.",
12
+ "mongoDBConnectionChecker": "MongoDB Connection Checker",
13
+ "mongoConnection": "connection",
14
+ "mongoDBAuthentication": "authentication",
15
+ "mongoDBConnection": "MongoDB connection",
16
+ "mongoDBAuthenticationFailed": "failed",
17
+ "mongoDBUnableParsingUrl": "unable to parse",
18
+ "mongoDBConnectionUrl": "url",
19
+ "mongoDBServerSelection": "MongoServer selection error",
20
+ "mongoDBServer": "MongoServer",
21
+ "mongoDBConnectionError": "connection error",
22
+ "mongoDBError": "error",
23
+ "mongoDBAuthenticationError": "Authentication failed, be sure the credentials is correct.",
24
+ "postgresDBConnectionChecker": "PostgresDB Connection Checker",
25
+ "postgresConnection": "connection",
26
+ "postgresConnectionSuccess": "Connection to database is successfully.",
27
+ "postgresSuccessConn": "Postgres client Connection",
28
+ "postgresClosingConnSuccess": "Postgres client is close connection.",
29
+ "postgresEndClientRejection": "Postgres client end rejected",
30
+ "postgresClientError": "Postgres client error",
31
+ "postgresEndRejection": "End rejected",
32
+ "postgresConnError": "Postgres connection error",
33
+ "postgresException": "Exception",
34
+ "rsaKeyNotFound": "RSA key provided is not found.",
35
+ "encryptionWithPrivateKeyFailed": "Encryption With PrivateKey",
36
+ "encryptionFailed": "Encryption failed",
37
+ "verifyExistingKey": "Verify Existing Key",
38
+ "signatureRSAKeyFailed": "Signature verification failed.",
39
+ "signatureRSAKeysError": "Signature RSA Keys Error",
40
+ "errorDecryption": "Error decryption with private key",
41
+ "errorNameNotVerifyingRSAKey": "Error Verify RSA Key",
42
+ "decryptionWithPublicKeyFailed": "Decryption With PublicKey",
43
+ "decryptionFailed": "Decryption failed",
44
+ "verifyRSAKey": "Verify RSA Keys",
45
+ "verifyRSAKeyFailed": "Verify RSA Keys Failed",
46
+ "notVerifying": "Verification failed",
47
+ "mongoServerError": "MongoServerSelectionError: getaddrinfo EAI_AGAIN ({dbHost} is not allow to database connection)",
48
+ "dbUrlParsingError": "Unable to parse ${dbHost}:${dbPort} with URL"
49
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "opticore-webapp-core",
3
- "version": "1.0.3",
3
+ "version": "1.0.5",
4
4
  "description": "opticore Web Application core module",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",