@twin.org/node-core 0.9.4-next.5 → 0.9.4

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.
Files changed (44) hide show
  1. package/dist/es/builders/engineEnvBuilder.js +369 -470
  2. package/dist/es/builders/engineEnvBuilder.js.map +1 -1
  3. package/dist/es/builders/engineServerEnvBuilder.js +2 -5
  4. package/dist/es/builders/engineServerEnvBuilder.js.map +1 -1
  5. package/dist/es/builders/helper/envHelpers.js +0 -39
  6. package/dist/es/builders/helper/envHelpers.js.map +1 -1
  7. package/dist/es/cli.js +1 -1
  8. package/dist/es/cli.js.map +1 -1
  9. package/dist/es/commands/bootstrapDev.js +3 -3
  10. package/dist/es/commands/bootstrapDev.js.map +1 -1
  11. package/dist/es/commands/help.js +1 -1
  12. package/dist/es/commands/help.js.map +1 -1
  13. package/dist/es/commands/identityCreate.js +2 -2
  14. package/dist/es/commands/identityCreate.js.map +1 -1
  15. package/dist/es/commands/identityVerificationMethodCreate.js +2 -2
  16. package/dist/es/commands/identityVerificationMethodCreate.js.map +1 -1
  17. package/dist/es/commands/userCreate.js +1 -1
  18. package/dist/es/commands/userCreate.js.map +1 -1
  19. package/dist/es/commands/vaultKeyCreate.js +1 -1
  20. package/dist/es/commands/vaultKeyCreate.js.map +1 -1
  21. package/dist/es/commands/vaultKeyImport.js +1 -1
  22. package/dist/es/commands/vaultKeyImport.js.map +1 -1
  23. package/dist/es/models/IEngineEnvironmentVariables.js.map +1 -1
  24. package/dist/es/models/IEngineServerEnvironmentVariables.js.map +1 -1
  25. package/dist/es/models/engineEnvironmentVariableKeys.js +3 -14
  26. package/dist/es/models/engineEnvironmentVariableKeys.js.map +1 -1
  27. package/dist/es/models/engineServerEnvironmentVariableKeys.js +0 -1
  28. package/dist/es/models/engineServerEnvironmentVariableKeys.js.map +1 -1
  29. package/dist/es/node.js +21 -40
  30. package/dist/es/node.js.map +1 -1
  31. package/dist/types/builders/engineEnvBuilder.d.ts +0 -7
  32. package/dist/types/builders/helper/envHelpers.d.ts +0 -30
  33. package/dist/types/models/IEngineEnvironmentVariables.d.ts +12 -48
  34. package/dist/types/models/IEngineServerEnvironmentVariables.d.ts +0 -4
  35. package/docs/changelog.md +24 -180
  36. package/docs/reference/index.md +0 -1
  37. package/docs/reference/interfaces/IEngineEnvironmentVariables.md +21 -93
  38. package/docs/reference/interfaces/IEngineServerEnvironmentVariables.md +0 -8
  39. package/locales/en.json +1 -3
  40. package/package.json +34 -34
  41. package/dist/es/models/deprecatedEnvironmentVariableKeys.js +0 -16
  42. package/dist/es/models/deprecatedEnvironmentVariableKeys.js.map +0 -1
  43. package/dist/types/models/deprecatedEnvironmentVariableKeys.d.ts +0 -7
  44. package/docs/reference/functions/isMailboxEnabled.md +0 -20
@@ -1,16 +1,15 @@
1
1
  // Copyright 2024 IOTA Stiftung.
2
2
  // SPDX-License-Identifier: Apache-2.0.
3
- import { cpus } from "node:os";
4
3
  import path from "node:path";
5
4
  import { Is, Mutex } from "@twin.org/core";
6
5
  import { EngineCloneMode } from "@twin.org/engine-models";
7
- import { AttestationComponentType, AttestationConnectorType, AuditableItemGraphComponentType, AuditableItemStreamComponentType, AutomationActionType, AutomationComponentType, BackgroundTaskComponentType, BlobStorageComponentType, BlobStorageConnectorType, ContextIdHandlerComponentType, DataConverterConnectorType, DataExtractorConnectorType, DataProcessingComponentType, DataspaceControlPlaneComponentType, DataspaceDataPlaneComponentType, DltConfigType, DocumentManagementComponentType, EmailProtocolConnectorType, EngineTypeHelper, EntityStorageConnectorType, EventBusComponentType, EventBusConnectorType, FaucetConnectorType, FederatedCatalogueComponentType, FederatedCatalogueFilterComponentType, HealthComponentType, IdentityComponentType, IdentityConnectorType, IdentityProfileComponentType, IdentityProfileConnectorType, IdentityResolverComponentType, IdentityResolverConnectorType, ImmutableProofComponentType, LoggingComponentType, LoggingConnectorType, MailboxComponentType, MailStorageComponentType, MessagingAdminComponentType, MessagingComponentType, MessagingEmailConnectorType, MessagingPushNotificationConnectorType, MessagingSmsConnectorType, MetricsCollectorComponentType, MetricsProducerComponentType, NftComponentType, NftConnectorType, NotarizationComponentType, NotarizationConnectorType, PlatformComponentType, RightsManagementPapComponentType, RightsManagementPdpComponentType, RightsManagementPepComponentType, RightsManagementPipComponentType, RightsManagementPmpComponentType, RightsManagementPnapComponentType, RightsManagementPnpComponentType, RightsManagementPolicyArbiterComponentType, RightsManagementPolicyEnforcementProcessorComponentType, RightsManagementPolicyExecutionActionComponentType, RightsManagementPolicyInformationSourceComponentType, RightsManagementPolicyNegotiatorComponentType, RightsManagementPolicyObligationEnforcerComponentType, RightsManagementPolicyRequesterComponentType, RightsManagementPxpComponentType, SchemaVersionMigrationComponentType, TaskSchedulerComponentType, TelemetryComponentType, TelemetryConnectorType, TenantAdminComponentType, TracingComponentType, TracingConnectorType, TrustComponentType, TrustGeneratorComponentType, TrustVerifierComponentType, VaultConnectorType, WalletConnectorType } from "@twin.org/engine-types";
6
+ import { AttestationComponentType, AttestationConnectorType, AuditableItemGraphComponentType, AuditableItemStreamComponentType, AutomationComponentType, BackgroundTaskComponentType, BlobStorageComponentType, BlobStorageConnectorType, ContextIdHandlerComponentType, DataProcessingComponentType, DataspaceControlPlaneComponentType, DataspaceDataPlaneComponentType, DltConfigType, DocumentManagementComponentType, EngineTypeHelper, EntityStorageConnectorType, EventBusComponentType, EventBusConnectorType, FaucetConnectorType, FederatedCatalogueComponentType, HealthComponentType, IdentityComponentType, IdentityConnectorType, IdentityProfileComponentType, IdentityProfileConnectorType, IdentityResolverComponentType, IdentityResolverConnectorType, ImmutableProofComponentType, LoggingComponentType, LoggingConnectorType, MessagingAdminComponentType, MessagingComponentType, MessagingEmailConnectorType, MessagingPushNotificationConnectorType, MessagingSmsConnectorType, MetricsCollectorComponentType, MetricsProducerComponentType, NftComponentType, NftConnectorType, NotarizationComponentType, NotarizationConnectorType, PlatformComponentType, RightsManagementPapComponentType, RightsManagementPdpComponentType, RightsManagementPepComponentType, RightsManagementPipComponentType, RightsManagementPmpComponentType, RightsManagementPnapComponentType, RightsManagementPnpComponentType, RightsManagementPxpComponentType, SchemaVersionMigrationComponentType, TaskSchedulerComponentType, TelemetryComponentType, TelemetryConnectorType, TenantAdminComponentType, TracingComponentType, TracingConnectorType, TrustComponentType, TrustVerifierComponentType, VaultConnectorType, WalletConnectorType } from "@twin.org/engine-types";
8
7
  import { OpenTelemetryExporterTypes } from "@twin.org/logging-connector-opentelemetry";
9
8
  import { OpenTelemetryReaderTypes } from "@twin.org/telemetry-connector-opentelemetry";
10
9
  import { OpenTelemetryProcessorTypes } from "@twin.org/tracing-connector-opentelemetry";
11
10
  import { CONTEXT_ID_HANDLER_FEATURE_DID, CONTEXT_ID_HANDLER_FEATURE_TENANT } from "../defaults.js";
12
11
  import { isAuthEntityStorageRequired } from "./engineServerEnvBuilder.js";
13
- import { commaSeparatedListToArray, envArray, envBoolean, envChoice, envCount, envDateTime, envInteger, envListToArray, envMinToMs, envMinutes, envMs, envSecToMs, envSeconds } from "./helper/envHelpers.js";
12
+ import { commaSeparatedListToArray, envArray, envBoolean, envCount, envDateTime, envInteger, envMinToMs, envMinutes, envMs, envSecToMs, envSeconds } from "./helper/envHelpers.js";
14
13
  /**
15
14
  * Build the engine core configuration from environment variables.
16
15
  * @param envVars The environment variables.
@@ -33,7 +32,7 @@ export async function buildEngineConfiguration(envVars) {
33
32
  types: {}
34
33
  };
35
34
  const mutexTimeoutMs = envMs(envVars, "mutexTimeoutDefault");
36
- if (Is.notEmpty(mutexTimeoutMs)) {
35
+ if (!Is.empty(mutexTimeoutMs)) {
37
36
  Mutex.setDefaultTimeoutMs(mutexTimeoutMs);
38
37
  }
39
38
  await configureSchemaMigration(coreConfig, envVars);
@@ -52,7 +51,6 @@ export async function buildEngineConfiguration(envVars) {
52
51
  await configureMetricsCollector(coreConfig, envVars);
53
52
  await configureTracing(coreConfig, envVars);
54
53
  await configureMessaging(coreConfig, envVars);
55
- await configureMailbox(coreConfig, envVars);
56
54
  await configureAutomation(coreConfig, envVars);
57
55
  await configureHealth(coreConfig, envVars);
58
56
  await configureFaucet(coreConfig, envVars);
@@ -83,165 +81,163 @@ export async function buildEngineConfiguration(envVars) {
83
81
  async function configureEntityStorage(coreConfig, envVars) {
84
82
  coreConfig.types ??= {};
85
83
  coreConfig.types.entityStorageConnector ??= [];
86
- const entityStorageConnectorTypes = envListToArray(envVars, "entityStorageConnectorType", Object.values(EntityStorageConnectorType));
87
- for (const entityStorageConnectorType of entityStorageConnectorTypes) {
88
- if (entityStorageConnectorType === EntityStorageConnectorType.Memory) {
89
- coreConfig.types.entityStorageConnector.push({
90
- type: EntityStorageConnectorType.Memory,
91
- options: {
92
- config: {
93
- mutexTimeoutMs: envMs(envVars, "entityStorageMutexTimeout")
94
- }
95
- }
96
- });
97
- }
98
- else if (entityStorageConnectorType === EntityStorageConnectorType.File) {
99
- coreConfig.types.entityStorageConnector.push({
100
- type: EntityStorageConnectorType.File,
101
- options: {
102
- config: {
103
- directory: envVars.storageFileRoot ?? "",
104
- mutexTimeoutMs: envMs(envVars, "entityStorageMutexTimeout")
105
- },
106
- folderPrefix: envVars.entityStorageTablePrefix
107
- }
108
- });
109
- }
110
- else if (entityStorageConnectorType === EntityStorageConnectorType.AwsDynamoDb) {
111
- coreConfig.types.entityStorageConnector.push({
112
- type: EntityStorageConnectorType.AwsDynamoDb,
113
- options: {
114
- config: {
115
- region: envVars.awsDynamodbRegion ?? "",
116
- authMode: envVars.awsDynamodbAuthMode,
117
- accessKeyId: envVars.awsDynamodbAccessKeyId,
118
- secretAccessKey: envVars.awsDynamodbSecretAccessKey,
119
- endpoint: envVars.awsDynamodbEndpoint,
120
- connectionTimeoutMs: envMs(envVars, "awsDynamodbConnectionTimeout"),
121
- mutexTimeoutMs: envMs(envVars, "entityStorageMutexTimeout")
122
- },
123
- tablePrefix: envVars.entityStorageTablePrefix
124
- }
125
- });
126
- }
127
- else if (entityStorageConnectorType === EntityStorageConnectorType.AzureCosmosDb) {
128
- coreConfig.types.entityStorageConnector.push({
129
- type: EntityStorageConnectorType.AzureCosmosDb,
130
- options: {
131
- config: {
132
- endpoint: envVars.azureCosmosdbEndpoint ?? "",
133
- key: envVars.azureCosmosdbKey ?? "",
134
- databaseId: envVars.azureCosmosdbDatabaseId ?? "",
135
- containerId: envVars.azureCosmosdbContainerId ?? "",
136
- mutexTimeoutMs: envMs(envVars, "entityStorageMutexTimeout")
137
- },
138
- tablePrefix: envVars.entityStorageTablePrefix
139
- }
140
- });
141
- }
142
- else if (entityStorageConnectorType === EntityStorageConnectorType.GcpFirestoreDb) {
143
- coreConfig.types.entityStorageConnector.push({
144
- type: EntityStorageConnectorType.GcpFirestoreDb,
145
- options: {
146
- config: {
147
- projectId: envVars.gcpFirestoreProjectId ?? "",
148
- credentials: envVars.gcpFirestoreCredentials ?? "",
149
- databaseId: envVars.gcpFirestoreDatabaseId ?? "",
150
- collectionName: envVars.gcpFirestoreCollectionName ?? "",
151
- endpoint: envVars.gcpFirestoreEndpoint ?? "",
152
- mutexTimeoutMs: envMs(envVars, "entityStorageMutexTimeout")
153
- },
154
- tablePrefix: envVars.entityStorageTablePrefix
155
- }
156
- });
157
- }
158
- else if (entityStorageConnectorType === EntityStorageConnectorType.ScyllaDb) {
159
- coreConfig.types.entityStorageConnector.push({
160
- type: EntityStorageConnectorType.ScyllaDb,
161
- options: {
162
- config: {
163
- hosts: commaSeparatedListToArray(envVars.scylladbHosts),
164
- localDataCenter: envVars.scylladbLocalDataCenter ?? "",
165
- keyspace: envVars.scylladbKeyspace ?? "",
166
- port: envInteger(envVars, "scylladbPort"),
167
- mutexTimeoutMs: envMs(envVars, "entityStorageMutexTimeout"),
168
- pool: {
169
- coreConnectionsPerHost: envCount(envVars, "scylladbPoolCoreConnectionsPerHost"),
170
- maxRequestsPerConnection: envCount(envVars, "scylladbPoolMaxRequestsPerConnection")
171
- }
172
- },
173
- tablePrefix: envVars.entityStorageTablePrefix
174
- }
175
- });
176
- }
177
- else if (entityStorageConnectorType === EntityStorageConnectorType.MySqlDb) {
178
- coreConfig.types.entityStorageConnector.push({
179
- type: EntityStorageConnectorType.MySqlDb,
180
- options: {
181
- config: {
182
- host: envVars.mySqlHost ?? "",
183
- port: envInteger(envVars, "mySqlPort"),
184
- user: envVars.mySqlUser ?? "",
185
- password: envVars.mySqlPassword ?? "",
186
- database: envVars.mySqlDatabase ?? "",
187
- mutexTimeoutMs: envMs(envVars, "entityStorageMutexTimeout"),
188
- pool: {
189
- connectionLimit: envCount(envVars, "mySqlPoolConnectionLimit"),
190
- maxIdle: envCount(envVars, "mySqlPoolMaxIdle"),
191
- idleTimeout: envMs(envVars, "mySqlPoolIdleTimeout"),
192
- enableKeepAlive: envBoolean(envVars, "mySqlPoolEnableKeepAlive"),
193
- waitForConnections: envBoolean(envVars, "mySqlPoolWaitForConnections"),
194
- queueLimit: envCount(envVars, "mySqlPoolQueueLimit")
195
- }
196
- },
197
- tablePrefix: envVars.entityStorageTablePrefix
198
- }
199
- });
200
- }
201
- else if (entityStorageConnectorType === EntityStorageConnectorType.MongoDb) {
202
- coreConfig.types.entityStorageConnector.push({
203
- type: EntityStorageConnectorType.MongoDb,
204
- options: {
205
- config: {
206
- host: envVars.mongoDbHost ?? "",
207
- port: envInteger(envVars, "mongoDbPort"),
208
- user: envVars.mongoDbUser ?? "",
209
- password: envVars.mongoDbPassword ?? "",
210
- database: envVars.mongoDbDatabase ?? "",
211
- mutexTimeoutMs: envMs(envVars, "entityStorageMutexTimeout"),
212
- pool: {
213
- maxPoolSize: envCount(envVars, "mongoDbPoolMaxPoolSize"),
214
- minPoolSize: envCount(envVars, "mongoDbPoolMinPoolSize"),
215
- maxIdleTimeMs: envMs(envVars, "mongoDbPoolMaxIdleTime"),
216
- waitQueueTimeoutMs: envMs(envVars, "mongoDbPoolWaitQueueTimeout")
217
- }
218
- },
219
- tablePrefix: envVars.entityStorageTablePrefix
220
- }
221
- });
222
- }
223
- else if (entityStorageConnectorType === EntityStorageConnectorType.PostgreSql) {
224
- coreConfig.types.entityStorageConnector.push({
225
- type: EntityStorageConnectorType.PostgreSql,
226
- options: {
227
- config: {
228
- host: envVars.postgreSqlHost ?? "",
229
- port: envInteger(envVars, "postgreSqlPort"),
230
- user: envVars.postgreSqlUser ?? "",
231
- password: envVars.postgreSqlPassword ?? "",
232
- database: envVars.postgreSqlDatabase ?? "",
233
- mutexTimeoutMs: envMs(envVars, "entityStorageMutexTimeout"),
234
- pool: {
235
- max: envCount(envVars, "postgreSqlPoolMax"),
236
- idleTimeout: envSeconds(envVars, "postgreSqlPoolIdleTimeout"),
237
- connectTimeout: envSeconds(envVars, "postgreSqlPoolConnectTimeout"),
238
- maxLifetime: envSeconds(envVars, "postgreSqlPoolMaxLifetime")
239
- }
240
- },
241
- tablePrefix: envVars.entityStorageTablePrefix
84
+ const entityStorageConnectorTypes = commaSeparatedListToArray(envVars.entityStorageConnectorType);
85
+ if (entityStorageConnectorTypes.includes(EntityStorageConnectorType.Memory)) {
86
+ coreConfig.types.entityStorageConnector.push({
87
+ type: EntityStorageConnectorType.Memory,
88
+ options: {
89
+ config: {
90
+ mutexTimeoutMs: envMs(envVars, "entityStorageMutexTimeout")
242
91
  }
243
- });
244
- }
92
+ }
93
+ });
94
+ }
95
+ if (entityStorageConnectorTypes.includes(EntityStorageConnectorType.File)) {
96
+ coreConfig.types.entityStorageConnector.push({
97
+ type: EntityStorageConnectorType.File,
98
+ options: {
99
+ config: {
100
+ directory: envVars.storageFileRoot ?? "",
101
+ mutexTimeoutMs: envMs(envVars, "entityStorageMutexTimeout")
102
+ },
103
+ folderPrefix: envVars.entityStorageTablePrefix
104
+ }
105
+ });
106
+ }
107
+ if (entityStorageConnectorTypes.includes(EntityStorageConnectorType.AwsDynamoDb)) {
108
+ coreConfig.types.entityStorageConnector.push({
109
+ type: EntityStorageConnectorType.AwsDynamoDb,
110
+ options: {
111
+ config: {
112
+ region: envVars.awsDynamodbRegion ?? "",
113
+ authMode: envVars.awsDynamodbAuthMode,
114
+ accessKeyId: envVars.awsDynamodbAccessKeyId,
115
+ secretAccessKey: envVars.awsDynamodbSecretAccessKey,
116
+ endpoint: envVars.awsDynamodbEndpoint,
117
+ connectionTimeoutMs: envMs(envVars, "awsDynamodbConnectionTimeout"),
118
+ mutexTimeoutMs: envMs(envVars, "entityStorageMutexTimeout")
119
+ },
120
+ tablePrefix: envVars.entityStorageTablePrefix
121
+ }
122
+ });
123
+ }
124
+ if (entityStorageConnectorTypes.includes(EntityStorageConnectorType.AzureCosmosDb)) {
125
+ coreConfig.types.entityStorageConnector.push({
126
+ type: EntityStorageConnectorType.AzureCosmosDb,
127
+ options: {
128
+ config: {
129
+ endpoint: envVars.azureCosmosdbEndpoint ?? "",
130
+ key: envVars.azureCosmosdbKey ?? "",
131
+ databaseId: envVars.azureCosmosdbDatabaseId ?? "",
132
+ containerId: envVars.azureCosmosdbContainerId ?? "",
133
+ mutexTimeoutMs: envMs(envVars, "entityStorageMutexTimeout")
134
+ },
135
+ tablePrefix: envVars.entityStorageTablePrefix
136
+ }
137
+ });
138
+ }
139
+ if (entityStorageConnectorTypes.includes(EntityStorageConnectorType.GcpFirestoreDb)) {
140
+ coreConfig.types.entityStorageConnector.push({
141
+ type: EntityStorageConnectorType.GcpFirestoreDb,
142
+ options: {
143
+ config: {
144
+ projectId: envVars.gcpFirestoreProjectId ?? "",
145
+ credentials: envVars.gcpFirestoreCredentials ?? "",
146
+ databaseId: envVars.gcpFirestoreDatabaseId ?? "",
147
+ collectionName: envVars.gcpFirestoreCollectionName ?? "",
148
+ endpoint: envVars.gcpFirestoreEndpoint ?? "",
149
+ mutexTimeoutMs: envMs(envVars, "entityStorageMutexTimeout")
150
+ },
151
+ tablePrefix: envVars.entityStorageTablePrefix
152
+ }
153
+ });
154
+ }
155
+ if (entityStorageConnectorTypes.includes(EntityStorageConnectorType.ScyllaDb)) {
156
+ coreConfig.types.entityStorageConnector.push({
157
+ type: EntityStorageConnectorType.ScyllaDb,
158
+ options: {
159
+ config: {
160
+ hosts: commaSeparatedListToArray(envVars.scylladbHosts),
161
+ localDataCenter: envVars.scylladbLocalDataCenter ?? "",
162
+ keyspace: envVars.scylladbKeyspace ?? "",
163
+ port: envInteger(envVars, "scylladbPort"),
164
+ mutexTimeoutMs: envMs(envVars, "entityStorageMutexTimeout"),
165
+ pool: {
166
+ coreConnectionsPerHost: envCount(envVars, "scylladbPoolCoreConnectionsPerHost"),
167
+ maxRequestsPerConnection: envCount(envVars, "scylladbPoolMaxRequestsPerConnection")
168
+ }
169
+ },
170
+ tablePrefix: envVars.entityStorageTablePrefix
171
+ }
172
+ });
173
+ }
174
+ if (entityStorageConnectorTypes.includes(EntityStorageConnectorType.MySqlDb)) {
175
+ coreConfig.types.entityStorageConnector.push({
176
+ type: EntityStorageConnectorType.MySqlDb,
177
+ options: {
178
+ config: {
179
+ host: envVars.mySqlHost ?? "",
180
+ port: envInteger(envVars, "mySqlPort"),
181
+ user: envVars.mySqlUser ?? "",
182
+ password: envVars.mySqlPassword ?? "",
183
+ database: envVars.mySqlDatabase ?? "",
184
+ mutexTimeoutMs: envMs(envVars, "entityStorageMutexTimeout"),
185
+ pool: {
186
+ connectionLimit: envCount(envVars, "mySqlPoolConnectionLimit"),
187
+ maxIdle: envCount(envVars, "mySqlPoolMaxIdle"),
188
+ idleTimeout: envMs(envVars, "mySqlPoolIdleTimeout"),
189
+ enableKeepAlive: envBoolean(envVars, "mySqlPoolEnableKeepAlive"),
190
+ waitForConnections: envBoolean(envVars, "mySqlPoolWaitForConnections"),
191
+ queueLimit: envCount(envVars, "mySqlPoolQueueLimit")
192
+ }
193
+ },
194
+ tablePrefix: envVars.entityStorageTablePrefix
195
+ }
196
+ });
197
+ }
198
+ if (entityStorageConnectorTypes.includes(EntityStorageConnectorType.MongoDb)) {
199
+ coreConfig.types.entityStorageConnector.push({
200
+ type: EntityStorageConnectorType.MongoDb,
201
+ options: {
202
+ config: {
203
+ host: envVars.mongoDbHost ?? "",
204
+ port: envInteger(envVars, "mongoDbPort"),
205
+ user: envVars.mongoDbUser ?? "",
206
+ password: envVars.mongoDbPassword ?? "",
207
+ database: envVars.mongoDbDatabase ?? "",
208
+ mutexTimeoutMs: envMs(envVars, "entityStorageMutexTimeout"),
209
+ pool: {
210
+ maxPoolSize: envCount(envVars, "mongoDbPoolMaxPoolSize"),
211
+ minPoolSize: envCount(envVars, "mongoDbPoolMinPoolSize"),
212
+ maxIdleTimeMs: envMs(envVars, "mongoDbPoolMaxIdleTime"),
213
+ waitQueueTimeoutMs: envMs(envVars, "mongoDbPoolWaitQueueTimeout")
214
+ }
215
+ },
216
+ tablePrefix: envVars.entityStorageTablePrefix
217
+ }
218
+ });
219
+ }
220
+ if (entityStorageConnectorTypes.includes(EntityStorageConnectorType.PostgreSql)) {
221
+ coreConfig.types.entityStorageConnector.push({
222
+ type: EntityStorageConnectorType.PostgreSql,
223
+ options: {
224
+ config: {
225
+ host: envVars.postgreSqlHost ?? "",
226
+ port: envInteger(envVars, "postgreSqlPort"),
227
+ user: envVars.postgreSqlUser ?? "",
228
+ password: envVars.postgreSqlPassword ?? "",
229
+ database: envVars.postgreSqlDatabase ?? "",
230
+ mutexTimeoutMs: envMs(envVars, "entityStorageMutexTimeout"),
231
+ pool: {
232
+ max: envCount(envVars, "postgreSqlPoolMax"),
233
+ idleTimeout: envSeconds(envVars, "postgreSqlPoolIdleTimeout"),
234
+ connectTimeout: envSeconds(envVars, "postgreSqlPoolConnectTimeout"),
235
+ maxLifetime: envSeconds(envVars, "postgreSqlPoolMaxLifetime")
236
+ }
237
+ },
238
+ tablePrefix: envVars.entityStorageTablePrefix
239
+ }
240
+ });
245
241
  }
246
242
  const defaultEntityStorageConnectorType = envVars.entityStorageConnectorDefault ?? entityStorageConnectorTypes[0];
247
243
  if (Is.arrayValue(entityStorageConnectorTypes)) {
@@ -261,88 +257,85 @@ async function configureEntityStorage(coreConfig, envVars) {
261
257
  */
262
258
  async function configureBlobStorage(coreConfig, envVars) {
263
259
  coreConfig.types.blobStorageConnector ??= [];
264
- const blobStorageConnectorTypes = envListToArray(envVars, "blobStorageConnectorType", Object.values(BlobStorageConnectorType));
265
- for (const blobStorageConnectorType of blobStorageConnectorTypes) {
266
- if (blobStorageConnectorType === BlobStorageConnectorType.Memory) {
267
- coreConfig.types.blobStorageConnector.push({
268
- type: BlobStorageConnectorType.Memory
269
- });
270
- }
271
- else if (blobStorageConnectorType === BlobStorageConnectorType.File) {
272
- coreConfig.types.blobStorageConnector.push({
273
- type: BlobStorageConnectorType.File,
274
- options: {
275
- config: {
276
- directory: Is.stringValue(envVars.storageFileRoot)
277
- ? path.join(envVars.storageFileRoot, "blob-storage")
278
- : ""
279
- },
280
- storagePrefix: envVars.blobStoragePrefix
281
- }
282
- });
283
- }
284
- else if (blobStorageConnectorType === BlobStorageConnectorType.Ipfs) {
285
- coreConfig.types.blobStorageConnector.push({
286
- type: BlobStorageConnectorType.Ipfs,
287
- options: {
288
- config: {
289
- apiUrl: envVars.ipfsApiUrl ?? "",
290
- bearerToken: envVars.ipfsBearerToken
291
- }
292
- }
293
- });
294
- }
295
- else if (blobStorageConnectorType === BlobStorageConnectorType.AwsS3) {
296
- coreConfig.types.blobStorageConnector.push({
297
- type: BlobStorageConnectorType.AwsS3,
298
- options: {
299
- config: {
300
- region: envVars.awsS3Region ?? "",
301
- bucketName: envVars.awsS3BucketName ?? "",
302
- authMode: envVars.awsS3AuthMode,
303
- accessKeyId: envVars.awsS3AccessKeyId,
304
- secretAccessKey: envVars.awsS3SecretAccessKey,
305
- endpoint: envVars.awsS3Endpoint
306
- },
307
- storagePrefix: envVars.blobStoragePrefix
308
- }
309
- });
310
- }
311
- else if (blobStorageConnectorType === BlobStorageConnectorType.AzureStorage) {
312
- coreConfig.types.blobStorageConnector.push({
313
- type: BlobStorageConnectorType.AzureStorage,
314
- options: {
315
- config: {
316
- accountName: envVars.azureStorageAccountName ?? "",
317
- accountKey: envVars.azureStorageAccountKey ?? "",
318
- containerName: envVars.azureStorageContainerName ?? "",
319
- endpoint: envVars.azureStorageEndpoint ?? ""
320
- },
321
- storagePrefix: envVars.blobStoragePrefix
322
- }
323
- });
324
- }
325
- else if (blobStorageConnectorType === BlobStorageConnectorType.GcpStorage) {
326
- coreConfig.types.blobStorageConnector.push({
327
- type: BlobStorageConnectorType.GcpStorage,
328
- options: {
329
- config: {
330
- projectId: envVars.gcpStorageProjectId ?? "",
331
- credentials: envVars.gcpStorageCredentials ?? "",
332
- bucketName: envVars.gcpStorageBucketName ?? "",
333
- apiEndpoint: envVars.gcpFirestoreEndpoint
334
- },
335
- storagePrefix: envVars.blobStoragePrefix
260
+ const blobStorageConnectorTypes = commaSeparatedListToArray(envVars.blobStorageConnectorType);
261
+ if (blobStorageConnectorTypes.includes(BlobStorageConnectorType.Memory)) {
262
+ coreConfig.types.blobStorageConnector.push({
263
+ type: BlobStorageConnectorType.Memory
264
+ });
265
+ }
266
+ if (blobStorageConnectorTypes.includes(BlobStorageConnectorType.File)) {
267
+ coreConfig.types.blobStorageConnector.push({
268
+ type: BlobStorageConnectorType.File,
269
+ options: {
270
+ config: {
271
+ directory: Is.stringValue(envVars.storageFileRoot)
272
+ ? path.join(envVars.storageFileRoot, "blob-storage")
273
+ : ""
274
+ },
275
+ storagePrefix: envVars.blobStoragePrefix
276
+ }
277
+ });
278
+ }
279
+ if (blobStorageConnectorTypes.includes(BlobStorageConnectorType.Ipfs)) {
280
+ coreConfig.types.blobStorageConnector.push({
281
+ type: BlobStorageConnectorType.Ipfs,
282
+ options: {
283
+ config: {
284
+ apiUrl: envVars.ipfsApiUrl ?? "",
285
+ bearerToken: envVars.ipfsBearerToken
336
286
  }
337
- });
338
- }
287
+ }
288
+ });
289
+ }
290
+ if (blobStorageConnectorTypes.includes(BlobStorageConnectorType.AwsS3)) {
291
+ coreConfig.types.blobStorageConnector.push({
292
+ type: BlobStorageConnectorType.AwsS3,
293
+ options: {
294
+ config: {
295
+ region: envVars.awsS3Region ?? "",
296
+ bucketName: envVars.awsS3BucketName ?? "",
297
+ authMode: envVars.awsS3AuthMode,
298
+ accessKeyId: envVars.awsS3AccessKeyId,
299
+ secretAccessKey: envVars.awsS3SecretAccessKey,
300
+ endpoint: envVars.awsS3Endpoint
301
+ },
302
+ storagePrefix: envVars.blobStoragePrefix
303
+ }
304
+ });
305
+ }
306
+ if (blobStorageConnectorTypes.includes(BlobStorageConnectorType.AzureStorage)) {
307
+ coreConfig.types.blobStorageConnector.push({
308
+ type: BlobStorageConnectorType.AzureStorage,
309
+ options: {
310
+ config: {
311
+ accountName: envVars.azureStorageAccountName ?? "",
312
+ accountKey: envVars.azureStorageAccountKey ?? "",
313
+ containerName: envVars.azureStorageContainerName ?? "",
314
+ endpoint: envVars.azureStorageEndpoint ?? ""
315
+ },
316
+ storagePrefix: envVars.blobStoragePrefix
317
+ }
318
+ });
319
+ }
320
+ if (blobStorageConnectorTypes.includes(BlobStorageConnectorType.GcpStorage)) {
321
+ coreConfig.types.blobStorageConnector.push({
322
+ type: BlobStorageConnectorType.GcpStorage,
323
+ options: {
324
+ config: {
325
+ projectId: envVars.gcpStorageProjectId ?? "",
326
+ credentials: envVars.gcpStorageCredentials ?? "",
327
+ bucketName: envVars.gcpStorageBucketName ?? "",
328
+ apiEndpoint: envVars.gcpFirestoreEndpoint
329
+ },
330
+ storagePrefix: envVars.blobStoragePrefix
331
+ }
332
+ });
339
333
  }
340
334
  if (Is.arrayValue(blobStorageConnectorTypes)) {
341
335
  const defaultStorageConnectorType = envVars.blobStorageConnectorDefault ?? blobStorageConnectorTypes[0];
342
336
  for (const config of coreConfig.types.blobStorageConnector) {
343
337
  if (config.type === defaultStorageConnectorType) {
344
338
  config.isDefault = true;
345
- break;
346
339
  }
347
340
  }
348
341
  }
@@ -368,7 +361,7 @@ async function configureBlobStorage(coreConfig, envVars) {
368
361
  */
369
362
  async function configureLogging(coreConfig, envVars) {
370
363
  coreConfig.types.loggingConnector ??= [];
371
- const loggingConnectorTypes = envListToArray(envVars, "loggingConnector", Object.values(LoggingConnectorType));
364
+ const loggingConnectorTypes = commaSeparatedListToArray(envVars.loggingConnector);
372
365
  let additionalConnectorCount = 0;
373
366
  for (const loggingConnector of loggingConnectorTypes) {
374
367
  if (loggingConnector === LoggingConnectorType.Console) {
@@ -393,7 +386,8 @@ async function configureLogging(coreConfig, envVars) {
393
386
  retainForMs: envMinToMs(envVars, "loggingRetainFor"),
394
387
  maxEntries: envCount(envVars, "loggingMaxEntries"),
395
388
  retentionIntervalMs: envMinToMs(envVars, "loggingRetentionInterval"),
396
- retentionBatchSize: envCount(envVars, "loggingRetentionBatchSize")
389
+ retentionBatchSize: envCount(envVars, "loggingRetentionBatchSize"),
390
+ mutexTimeoutMs: envMs(envVars, "loggingMutexTimeout")
397
391
  }
398
392
  }
399
393
  });
@@ -430,7 +424,8 @@ async function configureLogging(coreConfig, envVars) {
430
424
  directory: envVars.loggingFileDirectory ?? envVars.storageFileRoot ?? "",
431
425
  filename: envVars.loggingFileFilename,
432
426
  maxFileSizeBytes: envCount(envVars, "loggingFileMaxFileSizeBytes"),
433
- maxRetainedFiles: envCount(envVars, "loggingFileMaxRetainedFiles")
427
+ maxRetainedFiles: envCount(envVars, "loggingFileMaxRetainedFiles"),
428
+ mutexTimeoutMs: envMs(envVars, "loggingMutexTimeout")
434
429
  }
435
430
  }
436
431
  });
@@ -468,8 +463,7 @@ async function configureLogging(coreConfig, envVars) {
468
463
  */
469
464
  async function configureVault(coreConfig, envVars) {
470
465
  coreConfig.types.vaultConnector ??= [];
471
- const vaultConnectorType = envChoice(envVars, "vaultConnector", Object.values(VaultConnectorType));
472
- if (vaultConnectorType === VaultConnectorType.EntityStorage) {
466
+ if (envVars.vaultConnector === VaultConnectorType.EntityStorage) {
473
467
  coreConfig.types.vaultConnector.push({
474
468
  type: VaultConnectorType.EntityStorage,
475
469
  options: {
@@ -479,7 +473,7 @@ async function configureVault(coreConfig, envVars) {
479
473
  }
480
474
  });
481
475
  }
482
- else if (vaultConnectorType === VaultConnectorType.Hashicorp) {
476
+ else if (envVars.vaultConnector === VaultConnectorType.Hashicorp) {
483
477
  coreConfig.types.vaultConnector.push({
484
478
  type: VaultConnectorType.Hashicorp,
485
479
  options: {
@@ -502,17 +496,7 @@ async function configureBackgroundTask(coreConfig, envVars) {
502
496
  coreConfig.types.backgroundTaskComponent ??= [];
503
497
  if (isBackgroundTasksRequired(envVars)) {
504
498
  coreConfig.types.backgroundTaskComponent.push({
505
- type: BackgroundTaskComponentType.Service,
506
- options: {
507
- config: {
508
- maxSystemWorkerCount: envCount(envVars, "backgroundTaskMaxSystemWorkerCount", cpus().length * 2),
509
- taskInterval: envMs(envVars, "backgroundTaskInterval"),
510
- retryInterval: envMs(envVars, "backgroundTaskRetryInterval"),
511
- cleanupInterval: envMs(envVars, "backgroundTaskCleanupInterval"),
512
- workerShutdownTimeout: envMs(envVars, "backgroundTaskWorkerShutdownTimeout"),
513
- maxDispatchCount: envCount(envVars, "backgroundTaskMaxDispatchCount")
514
- }
515
- }
499
+ type: BackgroundTaskComponentType.Service
516
500
  });
517
501
  }
518
502
  }
@@ -524,8 +508,7 @@ async function configureBackgroundTask(coreConfig, envVars) {
524
508
  */
525
509
  async function configureEventBus(coreConfig, envVars) {
526
510
  coreConfig.types.eventBusConnector ??= [];
527
- const eventBusConnectorType = envChoice(envVars, "eventBusConnector", Object.values(EventBusConnectorType));
528
- if (eventBusConnectorType === EventBusConnectorType.Local) {
511
+ if (envVars.eventBusConnector === EventBusConnectorType.Local) {
529
512
  coreConfig.types.eventBusConnector.push({
530
513
  type: EventBusConnectorType.Local
531
514
  });
@@ -543,16 +526,16 @@ async function configureEventBus(coreConfig, envVars) {
543
526
  */
544
527
  async function configureTelemetry(coreConfig, envVars) {
545
528
  coreConfig.types.telemetryConnector ??= [];
546
- const telemetryConnectorTypes = envListToArray(envVars, "telemetryConnector", Object.values(TelemetryConnectorType));
529
+ const telemetryConnectorTypes = commaSeparatedListToArray(envVars.telemetryConnector);
547
530
  let additionalConnectorCount = 0;
548
- for (const telemetryConnectorType of telemetryConnectorTypes) {
549
- if (telemetryConnectorType === TelemetryConnectorType.Silent) {
531
+ for (const telemetryConnector of telemetryConnectorTypes) {
532
+ if (telemetryConnector === TelemetryConnectorType.Silent) {
550
533
  coreConfig.types.telemetryConnector.push({
551
534
  type: TelemetryConnectorType.Silent
552
535
  });
553
536
  additionalConnectorCount++;
554
537
  }
555
- else if (telemetryConnectorType === TelemetryConnectorType.EntityStorage) {
538
+ else if (telemetryConnector === TelemetryConnectorType.EntityStorage) {
556
539
  coreConfig.types.telemetryConnector.push({
557
540
  type: TelemetryConnectorType.EntityStorage,
558
541
  options: {
@@ -568,7 +551,7 @@ async function configureTelemetry(coreConfig, envVars) {
568
551
  });
569
552
  additionalConnectorCount++;
570
553
  }
571
- else if (telemetryConnectorType === TelemetryConnectorType.OpenTelemetry) {
554
+ else if (telemetryConnector === TelemetryConnectorType.OpenTelemetry) {
572
555
  let readers;
573
556
  if (envVars.openTelemetryReader === OpenTelemetryReaderTypes.Prometheus) {
574
557
  readers = {
@@ -631,10 +614,8 @@ async function configureMetricsCollector(coreConfig, envVars) {
631
614
  cloneMode: EngineCloneMode.Never
632
615
  });
633
616
  coreConfig.types.metricsProducerComponent ??= [];
634
- const metricsProducers = envListToArray(envVars, "telemetryMetricsProducers", Object.values(MetricsProducerComponentType), [
635
- MetricsProducerComponentType.System,
636
- MetricsProducerComponentType.Process
637
- ]);
617
+ const metricsProducers = commaSeparatedListToArray(envVars.telemetryMetricsProducers ??
618
+ [MetricsProducerComponentType.System, MetricsProducerComponentType.Process].join(","));
638
619
  for (const producerType of metricsProducers) {
639
620
  coreConfig.types.metricsProducerComponent.push({
640
621
  type: producerType,
@@ -652,16 +633,16 @@ async function configureMetricsCollector(coreConfig, envVars) {
652
633
  */
653
634
  async function configureTracing(coreConfig, envVars) {
654
635
  coreConfig.types.tracingConnector ??= [];
655
- const tracingConnectorTypes = envListToArray(envVars, "tracingConnector", Object.values(TracingConnectorType));
636
+ const tracingConnectorTypes = commaSeparatedListToArray(envVars.tracingConnector);
656
637
  let additionalConnectorCount = 0;
657
- for (const tracingConnectorType of tracingConnectorTypes) {
658
- if (tracingConnectorType === TracingConnectorType.Silent) {
638
+ for (const tracingConnector of tracingConnectorTypes) {
639
+ if (tracingConnector === TracingConnectorType.Silent) {
659
640
  coreConfig.types.tracingConnector.push({
660
641
  type: TracingConnectorType.Silent
661
642
  });
662
643
  additionalConnectorCount++;
663
644
  }
664
- else if (tracingConnectorType === TracingConnectorType.EntityStorage) {
645
+ else if (tracingConnector === TracingConnectorType.EntityStorage) {
665
646
  coreConfig.types.tracingConnector.push({
666
647
  type: TracingConnectorType.EntityStorage,
667
648
  options: {
@@ -672,13 +653,7 @@ async function configureTracing(coreConfig, envVars) {
672
653
  });
673
654
  additionalConnectorCount++;
674
655
  }
675
- else if (tracingConnectorType === TracingConnectorType.Console) {
676
- coreConfig.types.tracingConnector.push({
677
- type: TracingConnectorType.Console
678
- });
679
- additionalConnectorCount++;
680
- }
681
- else if (tracingConnectorType === TracingConnectorType.OpenTelemetry) {
656
+ else if (tracingConnector === TracingConnectorType.OpenTelemetry) {
682
657
  const otelTracingConfig = {
683
658
  tracerName: envVars.openTelemetryTracingTracerName,
684
659
  tracerVersion: envVars.openTelemetryTracingTracerVersion
@@ -734,13 +709,15 @@ async function configureAutomation(coreConfig, envVars) {
734
709
  coreConfig.types.automationComponent.push({
735
710
  type: AutomationComponentType.Service
736
711
  });
737
- const automationActionTypes = envListToArray(envVars, "automationActionTypes", Object.values(AutomationActionType));
738
- coreConfig.types.automationAction ??= [];
739
- for (const actionType of automationActionTypes) {
740
- coreConfig.types.automationAction.push({
741
- type: actionType,
742
- isMultiInstance: true
743
- });
712
+ const automationActionTypes = commaSeparatedListToArray(envVars.automationActionTypes);
713
+ if (Is.arrayValue(automationActionTypes)) {
714
+ coreConfig.types.automationAction ??= [];
715
+ for (const actionType of automationActionTypes) {
716
+ coreConfig.types.automationAction.push({
717
+ type: actionType,
718
+ isMultiInstance: true
719
+ });
720
+ }
744
721
  }
745
722
  }
746
723
  }
@@ -843,89 +820,69 @@ async function configureContextIdHandlers(coreConfig, envVars) {
843
820
  * @returns A promise that resolves when the messaging configuration has been applied.
844
821
  */
845
822
  async function configureMessaging(coreConfig, envVars) {
846
- coreConfig.types.messagingEmailConnector ??= [];
847
- coreConfig.types.messagingSmsConnector ??= [];
848
- coreConfig.types.messagingPushNotificationConnector ??= [];
849
- const messagingEmailConnectorType = envChoice(envVars, "messagingEmailConnector", Object.values(MessagingEmailConnectorType));
850
- if (messagingEmailConnectorType === MessagingEmailConnectorType.EntityStorage) {
851
- coreConfig.types.messagingEmailConnector.push({
852
- type: MessagingEmailConnectorType.EntityStorage
853
- });
854
- }
855
- else if (messagingEmailConnectorType === MessagingEmailConnectorType.Aws) {
856
- coreConfig.types.messagingEmailConnector.push({
857
- type: MessagingEmailConnectorType.Aws,
858
- options: {
859
- config: {
860
- region: envVars.awsSesRegion ?? "",
861
- authMode: envVars.awsSesAuthMode,
862
- accessKeyId: envVars.awsSesAccessKeyId,
863
- secretAccessKey: envVars.awsSesSecretAccessKey,
864
- endpoint: envVars.awsSesEndpoint
865
- }
866
- }
867
- });
868
- }
869
- else if (messagingEmailConnectorType === MessagingEmailConnectorType.Smtp) {
870
- coreConfig.types.messagingEmailConnector.push({
871
- type: MessagingEmailConnectorType.Smtp,
872
- options: {
873
- config: {
874
- host: envVars.smtpHost ?? "",
875
- port: envInteger(envVars, "smtpPort"),
876
- secure: envBoolean(envVars, "smtpSecure"),
877
- username: envVars.smtpUsername,
878
- password: envVars.smtpPassword
823
+ if (envBoolean(envVars, "messagingEnabled", false)) {
824
+ coreConfig.types.messagingEmailConnector ??= [];
825
+ coreConfig.types.messagingSmsConnector ??= [];
826
+ coreConfig.types.messagingPushNotificationConnector ??= [];
827
+ if (envVars.messagingEmailConnector === MessagingEmailConnectorType.EntityStorage) {
828
+ coreConfig.types.messagingEmailConnector.push({
829
+ type: MessagingEmailConnectorType.EntityStorage
830
+ });
831
+ }
832
+ else if (envVars.messagingEmailConnector === MessagingEmailConnectorType.Aws) {
833
+ coreConfig.types.messagingEmailConnector.push({
834
+ type: MessagingEmailConnectorType.Aws,
835
+ options: {
836
+ config: {
837
+ region: envVars.awsSesRegion ?? "",
838
+ authMode: envVars.awsSesAuthMode,
839
+ accessKeyId: envVars.awsSesAccessKeyId,
840
+ secretAccessKey: envVars.awsSesSecretAccessKey,
841
+ endpoint: envVars.awsSesEndpoint
842
+ }
879
843
  }
880
- }
881
- });
882
- }
883
- const messagingSmsConnectorType = envChoice(envVars, "messagingSmsConnector", Object.values(MessagingSmsConnectorType));
884
- if (messagingSmsConnectorType === MessagingSmsConnectorType.EntityStorage) {
885
- coreConfig.types.messagingSmsConnector.push({
886
- type: MessagingSmsConnectorType.EntityStorage
887
- });
888
- }
889
- else if (messagingSmsConnectorType === MessagingSmsConnectorType.Aws) {
890
- coreConfig.types.messagingSmsConnector.push({
891
- type: MessagingSmsConnectorType.Aws,
892
- options: {
893
- config: {
894
- region: envVars.awsSesRegion ?? "",
895
- authMode: envVars.awsSesAuthMode,
896
- accessKeyId: envVars.awsSesAccessKeyId,
897
- secretAccessKey: envVars.awsSesSecretAccessKey,
898
- endpoint: envVars.awsSesEndpoint
844
+ });
845
+ }
846
+ if (envVars.messagingSmsConnector === MessagingSmsConnectorType.EntityStorage) {
847
+ coreConfig.types.messagingSmsConnector.push({
848
+ type: MessagingSmsConnectorType.EntityStorage
849
+ });
850
+ }
851
+ else if (envVars.messagingSmsConnector === MessagingSmsConnectorType.Aws) {
852
+ coreConfig.types.messagingSmsConnector.push({
853
+ type: MessagingSmsConnectorType.Aws,
854
+ options: {
855
+ config: {
856
+ region: envVars.awsSesRegion ?? "",
857
+ authMode: envVars.awsSesAuthMode,
858
+ accessKeyId: envVars.awsSesAccessKeyId,
859
+ secretAccessKey: envVars.awsSesSecretAccessKey,
860
+ endpoint: envVars.awsSesEndpoint
861
+ }
899
862
  }
900
- }
901
- });
902
- }
903
- const messagingPushConnectorType = envChoice(envVars, "messagingPushNotificationConnector", Object.values(MessagingPushNotificationConnectorType));
904
- if (messagingPushConnectorType === MessagingPushNotificationConnectorType.EntityStorage) {
905
- coreConfig.types.messagingPushNotificationConnector.push({
906
- type: MessagingPushNotificationConnectorType.EntityStorage
907
- });
908
- }
909
- else if (messagingPushConnectorType === MessagingPushNotificationConnectorType.Aws) {
910
- coreConfig.types.messagingPushNotificationConnector.push({
911
- type: MessagingPushNotificationConnectorType.Aws,
912
- options: {
913
- config: {
914
- region: envVars.awsSesRegion ?? "",
915
- authMode: envVars.awsSesAuthMode,
916
- accessKeyId: envVars.awsSesAccessKeyId,
917
- secretAccessKey: envVars.awsSesSecretAccessKey,
918
- endpoint: envVars.awsSesEndpoint,
919
- applicationsSettings: envArray(envVars, "awsMessagingPushNotificationApplications", [])
863
+ });
864
+ }
865
+ if (envVars.messagingPushNotificationConnector ===
866
+ MessagingPushNotificationConnectorType.EntityStorage) {
867
+ coreConfig.types.messagingPushNotificationConnector.push({
868
+ type: MessagingPushNotificationConnectorType.EntityStorage
869
+ });
870
+ }
871
+ else if (envVars.messagingPushNotificationConnector === MessagingPushNotificationConnectorType.Aws) {
872
+ coreConfig.types.messagingPushNotificationConnector.push({
873
+ type: MessagingPushNotificationConnectorType.Aws,
874
+ options: {
875
+ config: {
876
+ region: envVars.awsSesRegion ?? "",
877
+ authMode: envVars.awsSesAuthMode,
878
+ accessKeyId: envVars.awsSesAccessKeyId,
879
+ secretAccessKey: envVars.awsSesSecretAccessKey,
880
+ endpoint: envVars.awsSesEndpoint,
881
+ applicationsSettings: envArray(envVars, "awsMessagingPushNotificationApplications", [])
882
+ }
920
883
  }
921
- }
922
- });
923
- }
924
- // If any messaging connectors are configured, then we should configure the messaging admin and
925
- // service components as well since they are required for the messaging connectors to work.
926
- if (coreConfig.types.messagingEmailConnector.length > 0 ||
927
- coreConfig.types.messagingSmsConnector.length > 0 ||
928
- coreConfig.types.messagingPushNotificationConnector.length > 0) {
884
+ });
885
+ }
929
886
  coreConfig.types.messagingAdminComponent ??= [];
930
887
  coreConfig.types.messagingAdminComponent.push({
931
888
  type: MessagingAdminComponentType.Service
@@ -934,40 +891,6 @@ async function configureMessaging(coreConfig, envVars) {
934
891
  coreConfig.types.messagingComponent.push({ type: MessagingComponentType.Service });
935
892
  }
936
893
  }
937
- /**
938
- * Configures mailbox components, mail storage components, and email protocol connectors.
939
- * @param coreConfig The core config.
940
- * @param envVars The environment variables.
941
- * @returns A promise that resolves when the mailbox configuration has been applied.
942
- */
943
- async function configureMailbox(coreConfig, envVars) {
944
- coreConfig.types.emailProtocolConnector ??= [];
945
- const emailProtocolConnectorTypes = envListToArray(envVars, "emailProtocolConnector", Object.values(EmailProtocolConnectorType));
946
- for (const emailProtocolConnectorType of emailProtocolConnectorTypes) {
947
- coreConfig.types.emailProtocolConnector.push({
948
- type: emailProtocolConnectorType,
949
- options: {
950
- config: {}
951
- },
952
- cloneMode: EngineCloneMode.Never,
953
- isMultiInstance: true
954
- });
955
- }
956
- // If email protocol connectors are configured, then we should configure the mailbox and mail store
957
- // components as well, since they are required for the email protocol connectors to work.
958
- if (coreConfig.types.emailProtocolConnector.length > 0) {
959
- coreConfig.types.mailStorageComponent ??= [];
960
- coreConfig.types.mailStorageComponent.push({
961
- type: MailStorageComponentType.Service,
962
- cloneMode: EngineCloneMode.Never
963
- });
964
- coreConfig.types.mailboxComponent ??= [];
965
- coreConfig.types.mailboxComponent.push({
966
- type: MailboxComponentType.Service,
967
- cloneMode: EngineCloneMode.Never
968
- });
969
- }
970
- }
971
894
  /**
972
895
  * Configures the faucet.
973
896
  * @param coreConfig The core config.
@@ -976,13 +899,12 @@ async function configureMailbox(coreConfig, envVars) {
976
899
  */
977
900
  async function configureFaucet(coreConfig, envVars) {
978
901
  coreConfig.types.faucetConnector ??= [];
979
- const faucetConnectorType = envChoice(envVars, "faucetConnector", Object.values(FaucetConnectorType));
980
- if (faucetConnectorType === FaucetConnectorType.EntityStorage) {
902
+ if (envVars.faucetConnector === FaucetConnectorType.EntityStorage) {
981
903
  coreConfig.types.faucetConnector.push({
982
904
  type: FaucetConnectorType.EntityStorage
983
905
  });
984
906
  }
985
- else if (faucetConnectorType === FaucetConnectorType.Iota &&
907
+ else if (envVars.faucetConnector === FaucetConnectorType.Iota &&
986
908
  Is.stringValue(envVars.iotaFaucetEndpoint)) {
987
909
  const dltConfig = EngineTypeHelper.getConfigOfType(coreConfig, "dltConfig", DltConfigType.Iota);
988
910
  coreConfig.types.faucetConnector.push({
@@ -1005,13 +927,12 @@ async function configureFaucet(coreConfig, envVars) {
1005
927
  */
1006
928
  async function configureWallet(coreConfig, envVars) {
1007
929
  coreConfig.types.walletConnector ??= [];
1008
- const walletConnectorType = envChoice(envVars, "walletConnector", Object.values(WalletConnectorType));
1009
- if (walletConnectorType === WalletConnectorType.EntityStorage) {
930
+ if (envVars.walletConnector === WalletConnectorType.EntityStorage) {
1010
931
  coreConfig.types.walletConnector.push({
1011
932
  type: WalletConnectorType.EntityStorage
1012
933
  });
1013
934
  }
1014
- else if (walletConnectorType === WalletConnectorType.Iota) {
935
+ else if (envVars.walletConnector === WalletConnectorType.Iota) {
1015
936
  const dltConfig = EngineTypeHelper.getConfigOfType(coreConfig, "dltConfig", DltConfigType.Iota);
1016
937
  coreConfig.types.walletConnector.push({
1017
938
  type: WalletConnectorType.Iota,
@@ -1029,13 +950,12 @@ async function configureWallet(coreConfig, envVars) {
1029
950
  */
1030
951
  async function configureNft(coreConfig, envVars) {
1031
952
  coreConfig.types.nftConnector ??= [];
1032
- const nftConnectorType = envChoice(envVars, "nftConnector", Object.values(NftConnectorType));
1033
- if (nftConnectorType === NftConnectorType.EntityStorage) {
953
+ if (envVars.nftConnector === NftConnectorType.EntityStorage) {
1034
954
  coreConfig.types.nftConnector.push({
1035
955
  type: NftConnectorType.EntityStorage
1036
956
  });
1037
957
  }
1038
- else if (nftConnectorType === NftConnectorType.Iota) {
958
+ else if (envVars.nftConnector === NftConnectorType.Iota) {
1039
959
  const dltConfig = EngineTypeHelper.getConfigOfType(coreConfig, "dltConfig", DltConfigType.Iota);
1040
960
  const config = {
1041
961
  ...dltConfig?.options?.config,
@@ -1061,13 +981,12 @@ async function configureNft(coreConfig, envVars) {
1061
981
  */
1062
982
  async function configureNotarization(coreConfig, envVars) {
1063
983
  coreConfig.types.notarizationConnector ??= [];
1064
- const notarizationConnectorType = envChoice(envVars, "notarizationConnector", Object.values(NotarizationConnectorType));
1065
- if (notarizationConnectorType === NotarizationConnectorType.EntityStorage) {
984
+ if (envVars.notarizationConnector === NotarizationConnectorType.EntityStorage) {
1066
985
  coreConfig.types.notarizationConnector.push({
1067
986
  type: NotarizationConnectorType.EntityStorage
1068
987
  });
1069
988
  }
1070
- else if (notarizationConnectorType === NotarizationConnectorType.Iota) {
989
+ else if (envVars.notarizationConnector === NotarizationConnectorType.Iota) {
1071
990
  const dltConfig = EngineTypeHelper.getConfigOfType(coreConfig, "dltConfig", DltConfigType.Iota);
1072
991
  coreConfig.types.notarizationConnector.push({
1073
992
  type: NotarizationConnectorType.Iota,
@@ -1117,13 +1036,12 @@ async function configureImmutableProof(coreConfig, envVars) {
1117
1036
  */
1118
1037
  async function configureIdentity(coreConfig, envVars) {
1119
1038
  coreConfig.types.identityConnector ??= [];
1120
- const identityConnectorType = envChoice(envVars, "identityConnector", Object.values(IdentityConnectorType));
1121
- if (identityConnectorType === IdentityConnectorType.EntityStorage) {
1039
+ if (envVars.identityConnector === IdentityConnectorType.EntityStorage) {
1122
1040
  coreConfig.types.identityConnector.push({
1123
1041
  type: IdentityConnectorType.EntityStorage
1124
1042
  });
1125
1043
  }
1126
- else if (identityConnectorType === IdentityConnectorType.Iota) {
1044
+ else if (envVars.identityConnector === IdentityConnectorType.Iota) {
1127
1045
  const dltConfig = EngineTypeHelper.getConfigOfType(coreConfig, "dltConfig", DltConfigType.Iota);
1128
1046
  coreConfig.types.identityConnector.push({
1129
1047
  type: IdentityConnectorType.Iota,
@@ -1156,13 +1074,12 @@ async function configureIdentity(coreConfig, envVars) {
1156
1074
  */
1157
1075
  async function configureIdentityResolver(coreConfig, envVars) {
1158
1076
  coreConfig.types.identityResolverConnector ??= [];
1159
- const identityResolverConnectorType = envChoice(envVars, "identityResolverConnector", Object.values(IdentityResolverConnectorType));
1160
- if (identityResolverConnectorType === IdentityResolverConnectorType.EntityStorage) {
1077
+ if (envVars.identityResolverConnector === IdentityResolverConnectorType.EntityStorage) {
1161
1078
  coreConfig.types.identityResolverConnector.push({
1162
1079
  type: IdentityResolverConnectorType.EntityStorage
1163
1080
  });
1164
1081
  }
1165
- else if (identityResolverConnectorType === IdentityResolverConnectorType.Iota) {
1082
+ else if (envVars.identityResolverConnector === IdentityResolverConnectorType.Iota) {
1166
1083
  const dltConfig = EngineTypeHelper.getConfigOfType(coreConfig, "dltConfig", DltConfigType.Iota);
1167
1084
  coreConfig.types.identityResolverConnector.push({
1168
1085
  type: IdentityResolverConnectorType.Iota,
@@ -1176,7 +1093,7 @@ async function configureIdentityResolver(coreConfig, envVars) {
1176
1093
  }
1177
1094
  });
1178
1095
  }
1179
- else if (identityResolverConnectorType === IdentityResolverConnectorType.Universal) {
1096
+ else if (envVars.identityResolverConnector === IdentityResolverConnectorType.Universal) {
1180
1097
  coreConfig.types.identityResolverConnector.push({
1181
1098
  type: IdentityResolverConnectorType.Universal,
1182
1099
  options: {
@@ -1201,8 +1118,7 @@ async function configureIdentityResolver(coreConfig, envVars) {
1201
1118
  */
1202
1119
  async function configureIdentityProfile(coreConfig, envVars) {
1203
1120
  coreConfig.types.identityProfileConnector ??= [];
1204
- const identityProfileConnectorType = envChoice(envVars, "identityProfileConnector", Object.values(IdentityProfileConnectorType));
1205
- if (identityProfileConnectorType === IdentityProfileConnectorType.EntityStorage) {
1121
+ if (envVars.identityProfileConnector === IdentityConnectorType.EntityStorage) {
1206
1122
  coreConfig.types.identityProfileConnector.push({
1207
1123
  type: IdentityProfileConnectorType.EntityStorage
1208
1124
  });
@@ -1220,8 +1136,7 @@ async function configureIdentityProfile(coreConfig, envVars) {
1220
1136
  */
1221
1137
  async function configureAttestation(coreConfig, envVars) {
1222
1138
  coreConfig.types.attestationConnector ??= [];
1223
- const attestationConnectorType = envChoice(envVars, "attestationConnector", Object.values(AttestationConnectorType));
1224
- if (attestationConnectorType === AttestationConnectorType.Nft) {
1139
+ if (envVars.attestationConnector === AttestationConnectorType.Nft) {
1225
1140
  coreConfig.types.attestationConnector.push({
1226
1141
  type: AttestationConnectorType.Nft
1227
1142
  });
@@ -1283,24 +1198,23 @@ async function configureAuditableItemStream(coreConfig, envVars) {
1283
1198
  * @returns A promise that resolves when the data processing configuration has been applied.
1284
1199
  */
1285
1200
  async function configureDataProcessing(coreConfig, envVars) {
1286
- coreConfig.types.dataConverterConnector ??= [];
1287
- const converterConnectors = envListToArray(envVars, "dataConverterConnectors", Object.values(DataConverterConnectorType));
1288
- for (const converterConnector of converterConnectors) {
1289
- coreConfig.types.dataConverterConnector.push({
1290
- type: converterConnector
1291
- });
1292
- }
1293
- coreConfig.types.dataExtractorConnector ??= [];
1294
- const extractorConnectors = envListToArray(envVars, "dataExtractorConnectors", Object.values(DataExtractorConnectorType));
1295
- for (const extractorConnector of extractorConnectors) {
1296
- coreConfig.types.dataExtractorConnector.push({
1297
- type: extractorConnector
1298
- });
1299
- }
1300
- if (coreConfig.types.dataConverterConnector.length > 0 ||
1301
- coreConfig.types.dataExtractorConnector.length > 0) {
1201
+ if (envBoolean(envVars, "dataProcessingEnabled", false)) {
1302
1202
  coreConfig.types.dataProcessingComponent ??= [];
1303
1203
  coreConfig.types.dataProcessingComponent.push({ type: DataProcessingComponentType.Service });
1204
+ coreConfig.types.dataConverterConnector ??= [];
1205
+ const converterConnectors = commaSeparatedListToArray(envVars.dataConverterConnectors);
1206
+ for (const converterConnector of converterConnectors) {
1207
+ coreConfig.types.dataConverterConnector.push({
1208
+ type: converterConnector
1209
+ });
1210
+ }
1211
+ coreConfig.types.dataExtractorConnector ??= [];
1212
+ const extractorConnectors = commaSeparatedListToArray(envVars.dataExtractorConnectors);
1213
+ for (const extractorConnector of extractorConnectors) {
1214
+ coreConfig.types.dataExtractorConnector.push({
1215
+ type: extractorConnector
1216
+ });
1217
+ }
1304
1218
  }
1305
1219
  }
1306
1220
  /**
@@ -1335,7 +1249,7 @@ async function configureTrust(coreConfig, envVars) {
1335
1249
  type: TrustComponentType.Service
1336
1250
  });
1337
1251
  coreConfig.types.trustGeneratorComponent ??= [];
1338
- const trustGeneratorTypes = envListToArray(envVars, "trustGenerators", Object.values(TrustGeneratorComponentType));
1252
+ const trustGeneratorTypes = commaSeparatedListToArray(envVars.trustGenerators);
1339
1253
  for (const trustGeneratorType of trustGeneratorTypes) {
1340
1254
  coreConfig.types.trustGeneratorComponent.push({
1341
1255
  type: trustGeneratorType,
@@ -1348,11 +1262,12 @@ async function configureTrust(coreConfig, envVars) {
1348
1262
  });
1349
1263
  }
1350
1264
  coreConfig.types.trustVerifierComponent ??= [];
1351
- const trustVerifierTypes = envListToArray(envVars, "trustVerifiers", Object.values(TrustVerifierComponentType));
1265
+ const trustVerifierTypes = commaSeparatedListToArray(envVars.trustVerifiers);
1352
1266
  for (const trustVerifierType of trustVerifierTypes) {
1353
- if (trustVerifierType === TrustVerifierComponentType.IdentityAllowDeny) {
1267
+ const type = trustVerifierType;
1268
+ if (type === TrustVerifierComponentType.IdentityAllowDeny) {
1354
1269
  coreConfig.types.trustVerifierComponent.push({
1355
- type: TrustVerifierComponentType.IdentityAllowDeny,
1270
+ type,
1356
1271
  options: {
1357
1272
  config: {
1358
1273
  allowIdentities: commaSeparatedListToArray(envVars.trustIdentitiesAllow),
@@ -1361,9 +1276,9 @@ async function configureTrust(coreConfig, envVars) {
1361
1276
  }
1362
1277
  });
1363
1278
  }
1364
- else if (trustVerifierType === TrustVerifierComponentType.JwtVerifiableCredential) {
1279
+ else {
1365
1280
  coreConfig.types.trustVerifierComponent.push({
1366
- type: TrustVerifierComponentType.JwtVerifiableCredential
1281
+ type
1367
1282
  });
1368
1283
  }
1369
1284
  }
@@ -1441,49 +1356,49 @@ async function configureRightsManagement(coreConfig, envVars) {
1441
1356
  }
1442
1357
  });
1443
1358
  coreConfig.types.rightsManagementPolicyArbiterComponent ??= [];
1444
- const policyArbiterTypes = envListToArray(envVars, "rightsManagementPolicyArbiters", Object.values(RightsManagementPolicyArbiterComponentType));
1359
+ const policyArbiterTypes = commaSeparatedListToArray(envVars.rightsManagementPolicyArbiters);
1445
1360
  for (const policyArbiterType of policyArbiterTypes) {
1446
1361
  coreConfig.types.rightsManagementPolicyArbiterComponent.push({
1447
1362
  type: policyArbiterType
1448
1363
  });
1449
1364
  }
1450
1365
  coreConfig.types.rightsManagementPolicyObligationEnforcerComponent ??= [];
1451
- const policyObligationEnforcerTypes = envListToArray(envVars, "rightsManagementPolicyObligationEnforcers", Object.values(RightsManagementPolicyObligationEnforcerComponentType));
1366
+ const policyObligationEnforcerTypes = commaSeparatedListToArray(envVars.rightsManagementPolicyObligationEnforcers);
1452
1367
  for (const policyObligationEnforcerType of policyObligationEnforcerTypes) {
1453
1368
  coreConfig.types.rightsManagementPolicyObligationEnforcerComponent.push({
1454
1369
  type: policyObligationEnforcerType
1455
1370
  });
1456
1371
  }
1457
1372
  coreConfig.types.rightsManagementPolicyEnforcementProcessorComponent ??= [];
1458
- const policyEnforcementProcessTypes = envListToArray(envVars, "rightsManagementPolicyEnforcementProcessors", Object.values(RightsManagementPolicyEnforcementProcessorComponentType));
1373
+ const policyEnforcementProcessTypes = commaSeparatedListToArray(envVars.rightsManagementPolicyEnforcementProcessors);
1459
1374
  for (const policyEnforcementProcessorType of policyEnforcementProcessTypes) {
1460
1375
  coreConfig.types.rightsManagementPolicyEnforcementProcessorComponent.push({
1461
1376
  type: policyEnforcementProcessorType
1462
1377
  });
1463
1378
  }
1464
1379
  coreConfig.types.rightsManagementPolicyExecutionActionComponent ??= [];
1465
- const policyExecutionActionTypes = envListToArray(envVars, "rightsManagementPolicyExecutionActions", Object.values(RightsManagementPolicyExecutionActionComponentType));
1380
+ const policyExecutionActionTypes = commaSeparatedListToArray(envVars.rightsManagementPolicyExecutionActions);
1466
1381
  for (const policyExecutionActionType of policyExecutionActionTypes) {
1467
1382
  coreConfig.types.rightsManagementPolicyExecutionActionComponent.push({
1468
1383
  type: policyExecutionActionType
1469
1384
  });
1470
1385
  }
1471
1386
  coreConfig.types.rightsManagementPolicyInformationSourceComponent ??= [];
1472
- const policyInformationSourceTypes = envListToArray(envVars, "rightsManagementPolicyInformationSources", Object.values(RightsManagementPolicyInformationSourceComponentType));
1387
+ const policyInformationSourceTypes = commaSeparatedListToArray(envVars.rightsManagementPolicyInformationSources);
1473
1388
  for (const policyInformationSourceType of policyInformationSourceTypes) {
1474
1389
  coreConfig.types.rightsManagementPolicyInformationSourceComponent.push({
1475
1390
  type: policyInformationSourceType
1476
1391
  });
1477
1392
  }
1478
1393
  coreConfig.types.rightsManagementPolicyRequesterComponent ??= [];
1479
- const policyRequesterTypes = envListToArray(envVars, "rightsManagementPolicyRequesters", Object.values(RightsManagementPolicyRequesterComponentType));
1394
+ const policyRequesterTypes = commaSeparatedListToArray(envVars.rightsManagementPolicyRequesters);
1480
1395
  for (const policyRequesterType of policyRequesterTypes) {
1481
1396
  coreConfig.types.rightsManagementPolicyRequesterComponent.push({
1482
1397
  type: policyRequesterType
1483
1398
  });
1484
1399
  }
1485
1400
  coreConfig.types.rightsManagementPolicyNegotiatorComponent ??= [];
1486
- const policyNegotiatorTypes = envListToArray(envVars, "rightsManagementPolicyNegotiators", Object.values(RightsManagementPolicyNegotiatorComponentType));
1401
+ const policyNegotiatorTypes = commaSeparatedListToArray(envVars.rightsManagementPolicyNegotiators);
1487
1402
  for (const policyNegotiatorType of policyNegotiatorTypes) {
1488
1403
  coreConfig.types.rightsManagementPolicyNegotiatorComponent.push({
1489
1404
  type: policyNegotiatorType
@@ -1533,7 +1448,7 @@ async function configureFederatedCatalogue(coreConfig, envVars) {
1533
1448
  }
1534
1449
  });
1535
1450
  coreConfig.types.federatedCatalogueFilterComponent ??= [];
1536
- const filters = envListToArray(envVars, "federatedCatalogueFilters", Object.values(FederatedCatalogueFilterComponentType));
1451
+ const filters = commaSeparatedListToArray(envVars.federatedCatalogueFilters);
1537
1452
  for (const filter of filters) {
1538
1453
  coreConfig.types.federatedCatalogueFilterComponent.push({
1539
1454
  type: filter,
@@ -1656,8 +1571,7 @@ export function isTrustRequired(envVars) {
1656
1571
  export function isBackgroundTasksRequired(envVars) {
1657
1572
  return (envBoolean(envVars, "dataspaceEnabled", false) ||
1658
1573
  isImmutableProofRequired(envVars) ||
1659
- envBoolean(envVars, "healthEnabled", false) ||
1660
- commaSeparatedListToArray(envVars.telemetryConnector).includes(TelemetryConnectorType.EntityStorage));
1574
+ envBoolean(envVars, "healthEnabled", false));
1661
1575
  }
1662
1576
  /**
1663
1577
  * Checks if the immutable proof subsystem is required.
@@ -1705,8 +1619,7 @@ export function isTaskSchedulerRequired(envVars) {
1705
1619
  envBoolean(envVars, "dataspaceEnabled", false) ||
1706
1620
  isRightsManagementRequired(envVars) ||
1707
1621
  isAuthEntityStorageRequired(envVars) ||
1708
- isImmutableProofRequired(envVars) ||
1709
- isMailboxEnabled(envVars));
1622
+ isImmutableProofRequired(envVars));
1710
1623
  }
1711
1624
  /**
1712
1625
  * Checks if the automation subsystem is required.
@@ -1733,20 +1646,6 @@ export function isTelemetryEnabled(envVars) {
1733
1646
  * @returns True if tracing is enabled.
1734
1647
  */
1735
1648
  export function isTracingEnabled(envVars) {
1736
- return commaSeparatedListToArray(envVars.tracingConnector).some(t => t === TracingConnectorType.EntityStorage ||
1737
- t === TracingConnectorType.OpenTelemetry ||
1738
- t === TracingConnectorType.Console);
1739
- }
1740
- /**
1741
- * Checks if the mailbox subsystem is enabled.
1742
- * Returns true when any component that depends on the mailbox subsystem is enabled.
1743
- * @param envVars The environment variables.
1744
- * @returns True if mailbox is enabled.
1745
- */
1746
- export function isMailboxEnabled(envVars) {
1747
- return commaSeparatedListToArray(envVars.emailProtocolConnector).some(t => t === EmailProtocolConnectorType.Imap ||
1748
- t === EmailProtocolConnectorType.Pop3 ||
1749
- t === EmailProtocolConnectorType.Gmail ||
1750
- t === EmailProtocolConnectorType.Outlook);
1649
+ return commaSeparatedListToArray(envVars.tracingConnector).some(t => t === TracingConnectorType.EntityStorage || t === TracingConnectorType.OpenTelemetry);
1751
1650
  }
1752
1651
  //# sourceMappingURL=engineEnvBuilder.js.map