def METHOD_NAME(self, local_path: str):
    rows = []
    row_count = len(next(iter(self._buffer.values())))
    row_index = 0
    while row_index < row_count:
        row = {}
        for k, v in self._buffer.items():
            row[k] = v[row_index]
        rows.append(row)
        row_index = row_index + 1
    data = {
        "rows": rows,
    }
    file_path = Path(local_path + ".json")
    try:
        with file_path.open("w") as json_file:
            json.dump(data, json_file, indent=2)
    except Exception as e:
        self._throw(f"Failed to persist row-based file {file_path}, error: {e}")
    logger.info(f"Successfully persist row-based file {file_path}")
    return [file_path]