@cubejs-client/core 1.7.12 → 1.7.14

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.
@@ -3696,14 +3696,28 @@ var CubeApi = /*#__PURE__*/function () {
3696
3696
  value:
3697
3697
  /**
3698
3698
  * Get meta description of cubes available for querying.
3699
+ *
3700
+ * Pass `onlyViews: true` to request views only — the response's `cubes` array
3701
+ * then contains only entries whose `type` is `view`.
3702
+ *
3703
+ * ```js
3704
+ * const meta = await cubeApi.meta({ onlyViews: true });
3705
+ * ```
3706
+ *
3707
+ * Compatibility note: over HTTP, servers predating the flag ignore it and return
3708
+ * the full model, so callers should not assume the response is filtered. Over
3709
+ * `WebSocketTransport` such servers reject the message with a 400 instead, since
3710
+ * they validate `meta` params strictly.
3699
3711
  */
3700
3712
  function meta(options, callback) {
3701
3713
  var _this8 = this;
3702
3714
  return this.loadMethod(function () {
3703
- return _this8.request('meta', {
3715
+ return _this8.request('meta', _objectSpread2({
3704
3716
  signal: options === null || options === void 0 ? void 0 : options.signal,
3705
3717
  baseRequestId: options === null || options === void 0 ? void 0 : options.baseRequestId
3706
- });
3718
+ }, options !== null && options !== void 0 && options.onlyViews ? {
3719
+ onlyViews: true
3720
+ } : {}));
3707
3721
  }, function (body) {
3708
3722
  return new Meta(body);
3709
3723
  }, options, callback);
@@ -3798,7 +3812,13 @@ var CubeApi = /*#__PURE__*/function () {
3798
3812
  throw new Error(parsed.error);
3799
3813
  }
3800
3814
  if (parsed.data) {
3801
- rows.push.apply(rows, _toConsumableArray(parsed.data));
3815
+ // Append rows one at a time instead of spreading the whole chunk as
3816
+ // call arguments (`rows.push(...parsed.data)`). A large single-chunk
3817
+ // result (e.g. 130k+ rows) otherwise exceeds V8's argument-count
3818
+ // limit and throws "RangeError: Maximum call stack size exceeded".
3819
+ for (var i = 0; i < parsed.data.length; i++) {
3820
+ rows.push(parsed.data[i]);
3821
+ }
3802
3822
  }
3803
3823
  }
3804
3824
  }