@aws-amplify/api-graphql 2.2.21 → 2.2.22-cloud-logging.3

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.
@@ -11838,7 +11838,11 @@ function (_super) {
11838
11838
  };
11839
11839
 
11840
11840
  AWSAppSyncRealTimeProvider.prototype._handleIncomingSubscriptionMessage = function (message) {
11841
- logger.debug("subscription message from AWS AppSync RealTime: " + message.data);
11841
+ if (message.data && message.data === '{"type":"ka"}') {
11842
+ logger.verbose("subscription message from AWS AppSync RealTime: " + message.data);
11843
+ } else {
11844
+ logger.debug("subscription message from AWS AppSync RealTime: " + message.data);
11845
+ }
11842
11846
 
11843
11847
  var _a = JSON.parse(message.data),
11844
11848
  _b = _a.id,
@@ -11857,12 +11861,21 @@ function (_super) {
11857
11861
  subscriptionReadyCallback = _c.subscriptionReadyCallback,
11858
11862
  subscriptionFailedCallback = _c.subscriptionFailedCallback;
11859
11863
 
11860
- logger.debug({
11861
- id: id,
11862
- observer: observer,
11863
- query: query,
11864
- variables: variables
11865
- });
11864
+ if (!id && !observer && !query && Object.keys(variables).length === 0) {
11865
+ logger.verbose({
11866
+ id: id,
11867
+ observer: observer,
11868
+ query: query,
11869
+ variables: variables
11870
+ });
11871
+ } else {
11872
+ logger.debug({
11873
+ id: id,
11874
+ observer: observer,
11875
+ query: query,
11876
+ variables: variables
11877
+ });
11878
+ }
11866
11879
 
11867
11880
  if (type === MESSAGE_TYPES.GQL_DATA && payload && payload.data) {
11868
11881
  if (observer) {