@Override
  protected void addPartitions(IMetaStoreClient client, List<Partition> partitions)
      throws TException {
    partitions.stream().forEach(partition -> partition.setParameters(partParams));
    super.addPartitions(client, partitions);
  }
Test class for list partitions with configurable include/exclude pattern on parameters.
Embedded Metastore uses JDO, Remote Metastore uses direct SQL to query the partitions:
MetaStoreFactoryForTests.getMetaStores()
ql/src/test/org/apache/hadoop/hive/metastore/TestListPartitionsWithXIncludeParams.java