atroo / node-weedfs

Node.js Client Library for SeaweedFS.
https://github.com/chrislusf/seaweedfs
17 stars 9 forks source link

Add filer API #14

Open aliwalker opened 5 years ago

aliwalker commented 5 years ago

Hi, @phal0r ! I've been wandering around seaweedfs since we need some sort of DFS for middle-end architecture. Seaweed is well suited for us, mainly because it provides a set of filer API(To be specific, we'll store wepack's output files to seaweedfs, so directories and file names are particularly important for us). So I'd like to know if filer API will be added in the future.

phal0r commented 5 years ago

Hi @aliwalker , I did not work with filer yet, so I have no experience using it. What I read from the docs, I think integration should be quite straight forward.

So it is not much to do client-side. Do you have other use cases that are not covered with this approach?

aliwalker commented 5 years ago

@phal0r , sorry that I didn't have time to reply.

Yes, the filer API is really straight forward to add. I've copied your code directly and modified a bit. See this. It is a framework specific plugin and I added your copy right notice in the source code there.

Since I'm not an experienced engineer yet, my opinions might be immature 😁:

Still, I think that Filer APIs could be an enhancement to this library.