[server] Use per-table remote data directory when storing lake table offset files
- Dominant language
- Java
- Stars
- 2.1k
- Forks
- 625
- Avg merge
- 3d 14h
- Merged PRs (30d)
- 97
Description
### Search before asking
- [x] I searched in the [issues](https://github.com/apache/fluss/issues) and found nothing similar.
### Description
**Current Situation:**
`LakeTableHelper` stores the lake table snapshot offset file to a remote path derived from the global `remote.data.dir` configuration, which is injected at construction time:
```java
public LakeTableHelper(ZooKeeperClient zkClient, String remoteDataDir) {
this.zkClient = zkClient;
this.remoteDataDir = remoteDataDir;
}
```
`storeLakeTableOffsetsFile()` then builds the remote path using this fixed `remoteDataDir`:
```java
public FsPath storeLakeTableOffsetsFile(TablePath tablePath, TableBucketOffsets offsets)
```
With the introduction of multiple remote data directories (`remote.data.dirs`), each table is assigned its own `remoteDataDir` at creation time and persisted in `TableRegistration`. We should also store the lake snapshot offset file to the table's specific remote data dir.
### Willingness to contribute
- [x] I'm willing to submit a PR!
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by reading LakeTableHelper, especially its constructor and storeLakeTableOffsetsFile(), then trace how the table-specific remoteDataDir is persisted in TableRegistration. Confirm the existing offset-file path behavior and update the implementation so it uses the table's assigned directory; done means lake snapshot offset files are stored under that per-table location.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- data-engineering
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 50/100