Skip to content
This repository has been archived by the owner on Jun 26, 2024. It is now read-only.

chore: use filter in entities query for selections as well #201

Merged
merged 6 commits into from
Jun 15, 2024

Conversation

saxenakshitiz
Copy link
Contributor

No description provided.

@saxenakshitiz saxenakshitiz requested a review from a team as a code owner May 21, 2024 07:06
Copy link

github-actions bot commented May 21, 2024

Test Results

367 tests  +1   367 ✅ +1   9s ⏱️ -1s
 68 suites +1     0 💤 ±0 
 68 files   +1     0 ❌ ±0 

Results for commit 9eae09e. ± Comparison against base commit 77592de.

This pull request removes 31 and adds 17 tests. Note that renamed tests count towards both.

      long: 60
      string: "PT1M"
      valueType: LONG
      valueType: STRING
    alias: "numCalls"
    columnName: "SERVICE.numCalls"
    value {
    }
  columnIdentifier {
…
org.hypertrace.gateway.service.baseline.BaselineServiceImplTest ‑ [1] function: AVGRATE
arguments {
  columnIdentifier {
    columnName: "SERVICE.numCalls"
    alias: "numCalls"
  }
}
arguments {
  literal {
    value {
      valueType: STRING
      string: "PT1M"
    }
  }
}
alias: "numCalls"

org.hypertrace.gateway.service.baseline.BaselineServiceImplTest ‑ [2] function: AVGRATE
arguments {
  columnIdentifier {
    columnName: "SERVICE.numCalls"
    alias: "numCalls"
  }
}
arguments {
  literal {
    value {
      valueType: LONG
      long: 60
    }
  }
}
alias: "numCalls"

org.hypertrace.gateway.service.explore.ExploreServiceTest ‑ [10] aggregations-with-groupby
org.hypertrace.gateway.service.explore.ExploreServiceTest ‑ [11] aggregations-with-groupby-and-the-rest-deprecated
org.hypertrace.gateway.service.explore.ExploreServiceTest ‑ [12] group-by-with-group-limit
org.hypertrace.gateway.service.explore.ExploreServiceTest ‑ [13] grouped-time-aggregation-with-group-limit
org.hypertrace.gateway.service.explore.ExploreServiceTest ‑ [14] simple-aggregations
org.hypertrace.gateway.service.explore.ExploreServiceTest ‑ [15] time-aggregations-space-filtered
org.hypertrace.gateway.service.explore.ExploreServiceTest ‑ [1] grouped-time-aggregation-with-group-limit-with-null-and-nonnull-value-group
org.hypertrace.gateway.service.explore.ExploreServiceTest ‑ [2] aggregations-with-multiple-groupbys-and-the-rest-deprecated
…

♻️ This comment has been updated with latest results.

@saxenakshitiz saxenakshitiz changed the title chore: use filter in entities query in selections as well chore: use filter in entities query for selections as well May 24, 2024
Comment on lines 204 to 205
// set up source filter to be used during selections
// filterTree.acceptVisitor(new SourceFilterVisitor(executionContext));
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do we need this?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

removed this commented section

@@ -330,7 +318,7 @@ QueryNode buildAndFilterTree(EntitiesRequest entitiesRequest) {
}

Map<AttributeSource, Filter> sourceToAndFilterMap =
new HashMap<>(buildSourceToAndFilterMap(entitiesRequest.getFilter()));
Map.copyOf(context.getExpressionContext().getSourceToFilterMap());
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

returns an unmodifiable map. The map is being modified on L328

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's correct. Moved it back to HashMap

@saxenakshitiz saxenakshitiz merged commit c613c1e into main Jun 15, 2024
7 checks passed
@saxenakshitiz saxenakshitiz deleted the use_filters_in_selections branch June 15, 2024 05:19
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants