Package org.projectnessie.api
Interface ContentApi
-
- All Known Subinterfaces:
HttpContentApi
public interface ContentApi
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description ContentgetContent(@Valid ContentKey key, @Valid @Pattern(regexp="^[A-Za-z](((?![.][.])[A-Za-z0-9./_-])*[A-Za-z0-9_-])?$",message="Reference name must start with a letter, followed by letters, digits, one of the ./_- characters, not end with a slash or dot, not contain \'..\'") String ref, @Valid @Pattern(regexp="^[0-9a-fA-F]{8,64}$",message="Hash must consist of the hex representation of 4-32 bytes") String hashOnRef)GetMultipleContentsResponsegetMultipleContents(@Valid @Pattern(regexp="^[A-Za-z](((?![.][.])[A-Za-z0-9./_-])*[A-Za-z0-9_-])?$",message="Reference name must start with a letter, followed by letters, digits, one of the ./_- characters, not end with a slash or dot, not contain \'..\'") String ref, @Valid @Pattern(regexp="^[0-9a-fA-F]{8,64}$",message="Hash must consist of the hex representation of 4-32 bytes") String hashOnRef, @Valid @NotNull GetMultipleContentsRequest request)Similar togetContent(ContentKey, String, String), but takes multipleContentKeys and returns theContentfor the one or moreContentKeys in a named-reference (aBranchorTag).
-
-
-
Method Detail
-
getContent
Content getContent(@Valid @Valid ContentKey key, @Valid @Pattern(regexp="^[A-Za-z](((?![.][.])[A-Za-z0-9./_-])*[A-Za-z0-9_-])?$",message="Reference name must start with a letter, followed by letters, digits, one of the ./_- characters, not end with a slash or dot, not contain \'..\'") @Valid @Pattern(regexp="^[A-Za-z](((?![.][.])[A-Za-z0-9./_-])*[A-Za-z0-9_-])?$",message="Reference name must start with a letter, followed by letters, digits, one of the ./_- characters, not end with a slash or dot, not contain \'..\'") String ref, @Valid @Nullable @Pattern(regexp="^[0-9a-fA-F]{8,64}$",message="Hash must consist of the hex representation of 4-32 bytes") @Valid @Pattern(regexp="^[0-9a-fA-F]{8,64}$",message="Hash must consist of the hex representation of 4-32 bytes") String hashOnRef) throws NessieNotFoundException
This operation returns theContentfor aContentKeyin a named-reference (aBranchorTag).If the table-metadata is tracked globally (Iceberg), Nessie returns a
Contentobject, that contains the most up-to-date part for the globally tracked part (Iceberg: table-metadata) plus the per-Nessie-reference/hash specific part (Iceberg: snapshot-ID, schema-ID, partition-spec-ID, default-sort-order-ID).- Parameters:
key- theContentKeys to retrieveref- named-reference to retrieve the content forhashOnRef- hash onrefto retrieve the content for, translates toHEAD, if missing/null- Returns:
- list of
GetMultipleContentsResponse.ContentWithKeys - Throws:
NessieNotFoundException- ifreforhashOnRefdoes not exist
-
getMultipleContents
GetMultipleContentsResponse getMultipleContents(@Valid @Pattern(regexp="^[A-Za-z](((?![.][.])[A-Za-z0-9./_-])*[A-Za-z0-9_-])?$",message="Reference name must start with a letter, followed by letters, digits, one of the ./_- characters, not end with a slash or dot, not contain \'..\'") @Valid @Pattern(regexp="^[A-Za-z](((?![.][.])[A-Za-z0-9./_-])*[A-Za-z0-9_-])?$",message="Reference name must start with a letter, followed by letters, digits, one of the ./_- characters, not end with a slash or dot, not contain \'..\'") String ref, @Valid @Nullable @Pattern(regexp="^[0-9a-fA-F]{8,64}$",message="Hash must consist of the hex representation of 4-32 bytes") @Valid @Pattern(regexp="^[0-9a-fA-F]{8,64}$",message="Hash must consist of the hex representation of 4-32 bytes") String hashOnRef, @Valid @NotNull @Valid @NotNull GetMultipleContentsRequest request) throws NessieNotFoundException
Similar togetContent(ContentKey, String, String), but takes multipleContentKeys and returns theContentfor the one or moreContentKeys in a named-reference (aBranchorTag).If the table-metadata is tracked globally (Iceberg), Nessie returns a
Contentobject, that contains the most up-to-date part for the globally tracked part (Iceberg: table-metadata) plus the per-Nessie-reference/hash specific part (Iceberg: snapshot-id, schema-id, partition-spec-id, default-sort-order-id).- Parameters:
ref- named-reference to retrieve the content forhashOnRef- hash onrefto retrieve the content for, translates toHEAD, if missing/nullrequest- theContentKeys to retrieve- Returns:
- list of
GetMultipleContentsResponse.ContentWithKeys - Throws:
NessieNotFoundException- ifreforhashOnRefdoes not exist
-
-