Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can I set more configuration when access hdfs? #311

Open
wymli opened this issue Jan 12, 2023 · 0 comments
Open

Can I set more configuration when access hdfs? #311

wymli opened this issue Jan 12, 2023 · 0 comments

Comments

@wymli
Copy link

wymli commented Jan 12, 2023

I'm accessing a remote fs using hdfs protocol, but some conf in core-site.xml should be changed.
I wonder could we access hdfs like the following code, dynamically set key value config.

Configuration conf = new Configuration();
conf.set("fs.cfs.impl", "com.volcengine.cloudfs.fs.CfsFileSystem");
conf.set("cfs.client.network.segment", vpcNet);
conf.set("cfs.access.key", ak);
conf.set("cfs.secret.key", sk);

// Optional:
// conf.set("cfs.security.token", sk);

FileSystem fs = FileSystem.get("cfs://xxxx.cfs-cn-beijing.ivolces.com", conf);
@wymli wymli closed this as completed Jan 21, 2023
@wymli wymli reopened this Apr 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant