vamsikarnika commented on code in PR #12696:
URL: https://github.com/apache/hudi/pull/12696#discussion_r1965963656
##########
hudi-timeline-service/src/main/java/org/apache/hudi/timeline/service/handlers/Handler.java:
##########
@@ -20,23 +20,24 @@
import org.apache.hudi.common.table.view.FileSystemViewManager;
import org.apache.hudi.storage.HoodieStorage;
+import org.apache.hudi.storage.HoodieStorageUtils;
import org.apache.hudi.storage.StorageConfiguration;
import org.apache.hudi.timeline.service.TimelineService;
-import java.io.IOException;
-
public abstract class Handler {
protected final StorageConfiguration<?> conf;
protected final TimelineService.Config timelineServiceConfig;
- protected final HoodieStorage storage;
protected final FileSystemViewManager viewManager;
public Handler(StorageConfiguration<?> conf, TimelineService.Config
timelineServiceConfig,
- HoodieStorage storage, FileSystemViewManager viewManager)
throws IOException {
- this.conf = conf;
+ FileSystemViewManager viewManager) {
+ this.conf = conf.newInstance();
this.timelineServiceConfig = timelineServiceConfig;
- this.storage = storage;
this.viewManager = viewManager;
}
+
+ public HoodieStorage getStorage(String path) {
+ return HoodieStorageUtils.getStorage(path, conf);
+ }
Review Comment:
This can be made protected. Fixed it.
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]