RussellSpitzer commented on a change in pull request #2520:
URL: https://github.com/apache/iceberg/pull/2520#discussion_r620801590
##########
File path: core/src/main/java/org/apache/iceberg/ManifestFiles.java
##########
@@ -80,9 +98,26 @@ private ManifestFiles() {
* @return a {@link ManifestReader}
*/
public static ManifestReader<DataFile> read(ManifestFile manifest, FileIO
io, Map<Integer, PartitionSpec> specsById) {
+ return read(manifest, io, EncryptionManagers.defaultManager(), specsById);
+ }
+
+ /**
+ * Returns a new {@link ManifestReader} for an encrypted {@link
ManifestFile}.
+ *
+ * @param manifest an encrypted {@link ManifestFile}
+ * @param io a {@link FileIO}
+ * @param encryption a {@link EncryptionManager}
+ * @param specsById a Map from spec ID to partition spec
+ * @return a {@link ManifestReader}
+ */
+ public static ManifestReader<DataFile> read(ManifestFile manifest, FileIO
io, EncryptionManager encryption,
+ Map<Integer, PartitionSpec>
specsById) {
Preconditions.checkArgument(manifest.content() == ManifestContent.DATA,
- "Cannot read a delete manifest with a ManifestReader: %s", manifest);
- InputFile file = io.newInputFile(manifest.path());
+ "Cannot read a delete manifest with ManifestReader: %s", manifest);
Review comment:
I'm not sure that the previous version of this error message is wrong
since it's trying to create a ManifestReader to read a delete manifest ... I
dunno, makes enough sense either way to me although I think I prefer the
original
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]