This is an automated email from the ASF dual-hosted git repository.
ipolyzos pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/fluss.git
The following commit(s) were added to refs/heads/main by this push:
new 5beaaea8a fix some docs of prefix lookup api (#1447)
5beaaea8a is described below
commit 5beaaea8aedb97937a53e11e1e2e2cb666ba7655
Author: CaoZhen <[email protected]>
AuthorDate: Fri Aug 1 03:41:45 2025 -0700
fix some docs of prefix lookup api (#1447)
---
.../java/com/alibaba/fluss/client/lookup/Lookuper.java | 4 ++--
website/docs/apis/java-client.md | 14 ++++++++++++--
2 files changed, 14 insertions(+), 4 deletions(-)
diff --git
a/fluss-client/src/main/java/com/alibaba/fluss/client/lookup/Lookuper.java
b/fluss-client/src/main/java/com/alibaba/fluss/client/lookup/Lookuper.java
index fe7fcc1c2..b24a1fa25 100644
--- a/fluss-client/src/main/java/com/alibaba/fluss/client/lookup/Lookuper.java
+++ b/fluss-client/src/main/java/com/alibaba/fluss/client/lookup/Lookuper.java
@@ -34,8 +34,8 @@ public interface Lookuper {
* Lookups certain row from the given lookup key.
*
* <p>The lookup key must be a primary key if the lookuper is a Primary
Key Lookuper (created by
- * {@code table.newLookuper().create()}), or be the prefix key if the
lookuper is a Prefix Key
- * Lookuper (created by {@code
table.newLookuper().withLookupColumns(prefixKeys).create()}).
+ * {@code table.newLookup().createLookuper()}), or be the prefix key if
the lookuper is a Prefix
+ * Key Lookuper (created by {@code
table.newLookup().lookupBy(prefixKeys).createLookuper()}).
*
* @param lookupKey the lookup key.
* @return the result of lookup.
diff --git a/website/docs/apis/java-client.md b/website/docs/apis/java-client.md
index 497d716b8..c476093d3 100644
--- a/website/docs/apis/java-client.md
+++ b/website/docs/apis/java-client.md
@@ -249,7 +249,17 @@ while (true) {
```
### Lookup
-You can also use the Fluss API to perform lookups on a table. This is useful
for querying specific records based on their primary key.
+You can also use the Fluss API to perform lookups on a table. This is useful
for querying specific records based on their primary key or prefix key.
```java
-LookupResult lookup = table.newLookup().createLookuper().lookup(rowKey).get();
+// Lookup by primary key
+LookupResult lookup = table.newLookup()
+ .createLookuper()
+ .lookup(rowKey)
+ .get();
+// Lookup by prefix key
+LookupResult prefixLookup = table.newLookup()
+ .lookupBy(prefixKeys)
+ .createLookuper()
+ .lookup(rowKey)
+ .get();
```
\ No newline at end of file