@shushed/helpers 0.0.198-v2-20251105075102 → 0.0.198-v2-20251105081148

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.
@@ -598,7 +598,6 @@ class EnvEngine extends runtime_1.default {
598
598
  },
599
599
  body: JSON.stringify({
600
600
  ...rnConfig,
601
- topicName: rnConfig.topicName,
602
601
  subscriptionName: subscriptionQualifiedName,
603
602
  operation: 'upsert',
604
603
  })
@@ -116,13 +116,13 @@ class PubSubHelper extends runtime_1.default {
116
116
  async createOrUpdate(opts) {
117
117
  const [topics] = await this.pubSub.getTopics();
118
118
  const topicName = opts.topicName;
119
- const mainSubscriptionName = opts.subscriptionName || opts.topicName;
119
+ const mainSubscriptionName = opts.subscriptionName || topicName;
120
+ const tableSubscriptionName = `${mainSubscriptionName}.bq`;
120
121
  const mainDlqTopicName = `${mainSubscriptionName}.dlq`;
121
- const tableDlqTopicName = `${mainSubscriptionName}.bq.dlq`;
122
122
  const mainDlqSubscriptionName = `${mainSubscriptionName}.dlq`;
123
- const tableSubscriptionName = `${mainSubscriptionName}.bq`;
124
- const tableDlqSubscriptionName = `${topicName}.bq.dlq`;
125
- let mainTopic = topics.find(x => this.getNameFromFullyQualifiedName(x.name) === opts.topicName);
123
+ const tableDlqTopicName = `${mainSubscriptionName}.bq.dlq`;
124
+ const tableDlqSubscriptionName = `${mainSubscriptionName}.bq.dlq`;
125
+ let mainTopic = topics.find(x => this.getNameFromFullyQualifiedName(x.name) === topicName);
126
126
  let mainDlqTopic = topics.find(x => this.getNameFromFullyQualifiedName(x.name) === mainDlqTopicName);
127
127
  let tableDlqTopic = topics.find(x => this.getNameFromFullyQualifiedName(x.name) === tableDlqTopicName);
128
128
  let mainTopicSubscriptions = null;
@@ -291,9 +291,11 @@ class PubSubHelper extends runtime_1.default {
291
291
  };
292
292
  const opts = Object.assign({}, defaultOptions, inputOpts);
293
293
  let nextMetadata = null;
294
- if (subscriptionMetaData?.pushConfig?.pushEndpoint) {
295
- nextMetadata = nextMetadata || {};
296
- nextMetadata.pushConfig = null;
294
+ if (!isSubscriptionBigQuery(opts)) {
295
+ if (subscriptionMetaData?.pushConfig?.pushEndpoint) {
296
+ nextMetadata = nextMetadata || {};
297
+ nextMetadata.pushConfig = null;
298
+ }
297
299
  }
298
300
  if (opts.dlqTopic) {
299
301
  if (opts.dlqTopic.name !== subscriptionMetaData?.deadLetterPolicy?.deadLetterTopic
@@ -319,9 +321,11 @@ class PubSubHelper extends runtime_1.default {
319
321
  nextMetadata.enableExactlyOnceDelivery = null;
320
322
  }
321
323
  }
322
- if ((opts.subscriptionFilter && subscriptionMetaData?.filter) && opts.subscriptionFilter !== subscriptionMetaData?.filter) {
323
- nextMetadata = nextMetadata || {};
324
- nextMetadata.filter = opts.subscriptionFilter || null;
324
+ if (!isSubscriptionBigQuery(opts)) {
325
+ if ((opts.subscriptionFilter && subscriptionMetaData?.filter) && opts.subscriptionFilter !== subscriptionMetaData?.filter) {
326
+ nextMetadata = nextMetadata || {};
327
+ nextMetadata.filter = opts.subscriptionFilter || null;
328
+ }
325
329
  }
326
330
  if (opts.retryMinDelay != subscriptionMetaData?.retryPolicy?.minimumBackoff?.seconds
327
331
  || opts.retryMaxDelay != subscriptionMetaData?.retryPolicy?.maximumBackoff?.seconds) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@shushed/helpers",
3
- "version": "0.0.198-v2-20251105075102",
3
+ "version": "0.0.198-v2-20251105081148",
4
4
  "author": "",
5
5
  "license": "UNLICENSED",
6
6
  "description": "",