@gradientedge/cdk-utils 9.80.0 → 9.81.0

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.
@@ -62,5 +62,5 @@ export declare class AzureEventgridManager {
62
62
  * @param props eventgrid system topic subscription properties
63
63
  * @see [CDKTF Eventgrid System Topic Subscription Module]{@link https://github.com/cdktf/cdktf-provider-azurerm/blob/main/docs/eventgridSystemTopicEventSubscription.typescript.md}
64
64
  */
65
- createEventgridSystemTopicEventSubscription(id: string, scope: CommonAzureConstruct, props: EventgridSystemTopicEventSubscriptionProps, systemTopic: EventgridSystemTopic): EventgridSystemTopicEventSubscription;
65
+ createEventgridSystemTopicEventSubscription(id: string, scope: CommonAzureConstruct, props: EventgridSystemTopicEventSubscriptionProps, systemTopic: EventgridSystemTopic | DataAzurermEventgridTopic): EventgridSystemTopicEventSubscription;
66
66
  }
@@ -45,7 +45,7 @@ class AzureKeyVaultManager {
45
45
  location: resourceGroup.location,
46
46
  resourceGroupName: resourceGroup.name,
47
47
  skuName: props.skuName ?? 'standard',
48
- enableRbacAuthorization: props.enableRbacAuthorization ?? true,
48
+ rbacAuthorizationEnabled: props.rbacAuthorizationEnabled ?? true,
49
49
  softDeleteRetentionDays: props.softDeleteRetentionDays ?? 90,
50
50
  purgeProtectionEnabled: props.purgeProtectionEnabled ?? true,
51
51
  tags: props.tags ?? {
@@ -2,8 +2,9 @@ import { ServicebusNamespace } from '@cdktf/provider-azurerm/lib/servicebus-name
2
2
  import { ServicebusTopic } from '@cdktf/provider-azurerm/lib/servicebus-topic';
3
3
  import { ServicebusSubscription } from '@cdktf/provider-azurerm/lib/servicebus-subscription';
4
4
  import { ServicebusQueue } from '@cdktf/provider-azurerm/lib/servicebus-queue';
5
+ import { DataAzurermServicebusQueue } from '@cdktf/provider-azurerm/lib/data-azurerm-servicebus-queue';
5
6
  import { CommonAzureConstruct } from '../../common';
6
- import { ServicebusTopicProps, ServicebusSubscriptionProps, ServicebusNamespaceProps, ServicebusQueueProps } from './types';
7
+ import { ServicebusTopicProps, ServicebusSubscriptionProps, ServicebusNamespaceProps, ServicebusQueueProps, DataAzurermServicebusQueueProps } from './types';
7
8
  /**
8
9
  * @classdesc Provides operations on Azure Servicebus
9
10
  * - A new instance of this class is injected into {@link CommonAzureConstruct} constructor.
@@ -54,4 +55,12 @@ export declare class AzureServicebusManager {
54
55
  * @see [CDKTF Servicebus Subscription Module]{@link https://github.com/cdktf/cdktf-provider-azurerm/blob/main/docs/servicebusSubscription.typescript.md}
55
56
  */
56
57
  createServicebusSubscription(id: string, scope: CommonAzureConstruct, props: ServicebusSubscriptionProps): ServicebusSubscription;
58
+ /**
59
+ * @summary Method to resolve a new servicebus queue
60
+ * @param id scoped id of the resource
61
+ * @param scope scope in which this resource is defined
62
+ * @param props servicebus queue properties
63
+ * @see [CDKTF Servicebus Queue Module]{@link https://github.com/cdktf/cdktf-provider-azurerm/blob/main/docs/servicebusQueue.typescript.md}
64
+ */
65
+ resolveServicebusQueue(id: string, scope: CommonAzureConstruct, props: DataAzurermServicebusQueueProps): DataAzurermServicebusQueue;
57
66
  }
@@ -6,6 +6,7 @@ const servicebus_namespace_1 = require("@cdktf/provider-azurerm/lib/servicebus-n
6
6
  const servicebus_topic_1 = require("@cdktf/provider-azurerm/lib/servicebus-topic");
7
7
  const servicebus_subscription_1 = require("@cdktf/provider-azurerm/lib/servicebus-subscription");
8
8
  const servicebus_queue_1 = require("@cdktf/provider-azurerm/lib/servicebus-queue");
9
+ const data_azurerm_servicebus_queue_1 = require("@cdktf/provider-azurerm/lib/data-azurerm-servicebus-queue");
9
10
  const utils_1 = require("../../utils");
10
11
  /**
11
12
  * @classdesc Provides operations on Azure Servicebus
@@ -124,5 +125,25 @@ class AzureServicebusManager {
124
125
  (0, utils_1.createAzureTfOutput)(`${id}-servicebusSubscriptionId`, scope, servicebusSubscription.id);
125
126
  return servicebusSubscription;
126
127
  }
128
+ /**
129
+ * @summary Method to resolve a new servicebus queue
130
+ * @param id scoped id of the resource
131
+ * @param scope scope in which this resource is defined
132
+ * @param props servicebus queue properties
133
+ * @see [CDKTF Servicebus Queue Module]{@link https://github.com/cdktf/cdktf-provider-azurerm/blob/main/docs/servicebusQueue.typescript.md}
134
+ */
135
+ resolveServicebusQueue(id, scope, props) {
136
+ if (!props)
137
+ throw `Props undefined for ${id}`;
138
+ const servicebusQueue = new data_azurerm_servicebus_queue_1.DataAzurermServicebusQueue(scope, `${id}-sq`, {
139
+ ...props,
140
+ name: scope.resourceNameFormatter.format(props.name, scope.props.resourceNameOptions?.serviceBusQueue),
141
+ namespaceId: props.namespaceId,
142
+ });
143
+ (0, utils_1.createAzureTfOutput)(`${id}-servicebusQueueName`, scope, servicebusQueue.name);
144
+ (0, utils_1.createAzureTfOutput)(`${id}-servicebusQueueFriendlyUniqueId`, scope, servicebusQueue.friendlyUniqueId);
145
+ (0, utils_1.createAzureTfOutput)(`${id}-servicebusQueueId`, scope, servicebusQueue.id);
146
+ return servicebusQueue;
147
+ }
127
148
  }
128
149
  exports.AzureServicebusManager = AzureServicebusManager;
@@ -2,6 +2,7 @@ import { ServicebusNamespaceConfig } from '@cdktf/provider-azurerm/lib/servicebu
2
2
  import { ServicebusTopicConfig } from '@cdktf/provider-azurerm/lib/servicebus-topic';
3
3
  import { ServicebusQueueConfig } from '@cdktf/provider-azurerm/lib/servicebus-queue';
4
4
  import { ServicebusSubscriptionConfig } from '@cdktf/provider-azurerm/lib/servicebus-subscription';
5
+ import { DataAzurermServicebusQueueConfig } from '@cdktf/provider-azurerm/lib/data-azurerm-servicebus-queue';
5
6
  export interface ServicebusNamespaceProps extends ServicebusNamespaceConfig {
6
7
  }
7
8
  export interface ServicebusTopicProps extends ServicebusTopicConfig {
@@ -10,3 +11,5 @@ export interface ServicebusQueueProps extends ServicebusQueueConfig {
10
11
  }
11
12
  export interface ServicebusSubscriptionProps extends ServicebusSubscriptionConfig {
12
13
  }
14
+ export interface DataAzurermServicebusQueueProps extends DataAzurermServicebusQueueConfig {
15
+ }
@@ -109,7 +109,7 @@ class CloudflareAccessManager {
109
109
  : scope.zoneManager.resolveZone(`${id}-data-zone`, scope, { name: scope.props.domainName })?.zoneId;
110
110
  const accessGroup = new zero_trust_access_group_1.ZeroTrustAccessGroup(scope, `${id}`, {
111
111
  ...props,
112
- name: `${props.name}-${scope.props.stage}`,
112
+ name: `${props.name} - ${scope.props.stage.toUpperCase()}`,
113
113
  zoneId,
114
114
  });
115
115
  (0, utils_1.createCloudflareTfOutput)(`${id}-accessGroupFriendlyUniqueId`, scope, accessGroup.friendlyUniqueId);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gradientedge/cdk-utils",
3
- "version": "9.80.0",
3
+ "version": "9.81.0",
4
4
  "description": "Utilities for AWS CDK provisioning",
5
5
  "main": "dist/index.js",
6
6
  "engines": {
@@ -176,7 +176,7 @@ export class AzureEventgridManager {
176
176
  id: string,
177
177
  scope: CommonAzureConstruct,
178
178
  props: EventgridSystemTopicEventSubscriptionProps,
179
- systemTopic: EventgridSystemTopic
179
+ systemTopic: EventgridSystemTopic | DataAzurermEventgridTopic
180
180
  ) {
181
181
  if (!props) throw `Props undefined for ${id}`
182
182
 
@@ -46,7 +46,7 @@ export class AzureKeyVaultManager {
46
46
  location: resourceGroup.location,
47
47
  resourceGroupName: resourceGroup.name,
48
48
  skuName: props.skuName ?? 'standard',
49
- enableRbacAuthorization: props.enableRbacAuthorization ?? true,
49
+ rbacAuthorizationEnabled: props.rbacAuthorizationEnabled ?? true,
50
50
  softDeleteRetentionDays: props.softDeleteRetentionDays ?? 90,
51
51
  purgeProtectionEnabled: props.purgeProtectionEnabled ?? true,
52
52
  tags: props.tags ?? {
@@ -3,6 +3,7 @@ import { ServicebusNamespace } from '@cdktf/provider-azurerm/lib/servicebus-name
3
3
  import { ServicebusTopic } from '@cdktf/provider-azurerm/lib/servicebus-topic'
4
4
  import { ServicebusSubscription } from '@cdktf/provider-azurerm/lib/servicebus-subscription'
5
5
  import { ServicebusQueue } from '@cdktf/provider-azurerm/lib/servicebus-queue'
6
+ import { DataAzurermServicebusQueue } from '@cdktf/provider-azurerm/lib/data-azurerm-servicebus-queue'
6
7
  import { CommonAzureConstruct } from '../../common'
7
8
  import { createAzureTfOutput } from '../../utils'
8
9
  import {
@@ -10,6 +11,7 @@ import {
10
11
  ServicebusSubscriptionProps,
11
12
  ServicebusNamespaceProps,
12
13
  ServicebusQueueProps,
14
+ DataAzurermServicebusQueueProps,
13
15
  } from './types'
14
16
 
15
17
  /**
@@ -141,4 +143,27 @@ export class AzureServicebusManager {
141
143
 
142
144
  return servicebusSubscription
143
145
  }
146
+
147
+ /**
148
+ * @summary Method to resolve a new servicebus queue
149
+ * @param id scoped id of the resource
150
+ * @param scope scope in which this resource is defined
151
+ * @param props servicebus queue properties
152
+ * @see [CDKTF Servicebus Queue Module]{@link https://github.com/cdktf/cdktf-provider-azurerm/blob/main/docs/servicebusQueue.typescript.md}
153
+ */
154
+ public resolveServicebusQueue(id: string, scope: CommonAzureConstruct, props: DataAzurermServicebusQueueProps) {
155
+ if (!props) throw `Props undefined for ${id}`
156
+
157
+ const servicebusQueue = new DataAzurermServicebusQueue(scope, `${id}-sq`, {
158
+ ...props,
159
+ name: scope.resourceNameFormatter.format(props.name, scope.props.resourceNameOptions?.serviceBusQueue),
160
+ namespaceId: props.namespaceId,
161
+ })
162
+
163
+ createAzureTfOutput(`${id}-servicebusQueueName`, scope, servicebusQueue.name)
164
+ createAzureTfOutput(`${id}-servicebusQueueFriendlyUniqueId`, scope, servicebusQueue.friendlyUniqueId)
165
+ createAzureTfOutput(`${id}-servicebusQueueId`, scope, servicebusQueue.id)
166
+
167
+ return servicebusQueue
168
+ }
144
169
  }
@@ -2,8 +2,10 @@ import { ServicebusNamespaceConfig } from '@cdktf/provider-azurerm/lib/servicebu
2
2
  import { ServicebusTopicConfig } from '@cdktf/provider-azurerm/lib/servicebus-topic'
3
3
  import { ServicebusQueueConfig } from '@cdktf/provider-azurerm/lib/servicebus-queue'
4
4
  import { ServicebusSubscriptionConfig } from '@cdktf/provider-azurerm/lib/servicebus-subscription'
5
+ import { DataAzurermServicebusQueueConfig } from '@cdktf/provider-azurerm/lib/data-azurerm-servicebus-queue'
5
6
 
6
7
  export interface ServicebusNamespaceProps extends ServicebusNamespaceConfig {}
7
8
  export interface ServicebusTopicProps extends ServicebusTopicConfig {}
8
9
  export interface ServicebusQueueProps extends ServicebusQueueConfig {}
9
10
  export interface ServicebusSubscriptionProps extends ServicebusSubscriptionConfig {}
11
+ export interface DataAzurermServicebusQueueProps extends DataAzurermServicebusQueueConfig {}
@@ -141,7 +141,7 @@ export class CloudflareAccessManager {
141
141
 
142
142
  const accessGroup = new ZeroTrustAccessGroup(scope, `${id}`, {
143
143
  ...props,
144
- name: `${props.name}-${scope.props.stage}`,
144
+ name: `${props.name} - ${scope.props.stage.toUpperCase()}`,
145
145
  zoneId,
146
146
  })
147
147