code: static boolean needsPropIdInClause(Set<String> queryPropIds,
              String[] entitySpecPropIds) {
  
          Set<String> entitySpecPropIdsSet = Arrays.asSet(entitySpecPropIds);
  
          // Filter propIds that are not in the entitySpecPropIds array.
          List<String> filteredPropIds = new ArrayList<>(
                  entitySpecPropIds.length);
          for (String propId : queryPropIds) {
              if (entitySpecPropIdsSet.contains(propId)) {
                  filteredPropIds.add(propId);
              }
          }
          return (filteredPropIds.size() < entitySpecPropIds.length * 0.85f)
                  && (filteredPropIds.size() <= 2000);
      }
docs: Returns whether an IN clause containing the proposition ids of interest
  should be added to the WHERE clause.
  
  @param queryPropIds the proposition ids to query.
  @param entitySpecPropIds the proposition ids corresponding to the current
  entity spec.
  @return <code>true</code> if the query contains < 85% of the proposition
  ids that are known to the data source and if the where clause would
  contain less than or equal to 2000 codes.