public Map<SystemStreamPartition, List<String>> readTaskPartitionAssignments() {
    try {
      Map<SystemStreamPartition, List<String>> sspToTaskNamesMap = new HashMap<>();
      Map<String, byte[]> allMetadataEntries = metadataStore.all();
      for (Map.Entry<String, byte[]> entry : allMetadataEntries.entrySet()) {
        SystemStreamPartition systemStreamPartition = deserializeSSPFromJson(entry.getKey());
        String taskNamesAsJson = valueSerde.fromBytes(entry.getValue());
        List<String> taskNames = taskNamesMapper.readValue(taskNamesAsJson, new TypeReference<List<String>>() { });
        sspToTaskNamesMap.put(systemStreamPartition, taskNames);
      }
      return sspToTaskNamesMap;
    } catch (Exception e) {
      throw new SamzaException("Exception occurred when reading task partition assignments.", e);
    }
  }
Reads the task partition assignments from the underlying storage layer.
@return the task partition assignments.
samza-core/src/main/java/org/apache/samza/container/grouper/task/TaskPartitionAssignmentManager.java