aboutsummaryrefslogtreecommitdiff
path: root/weed/s3api/filer_util.go
diff options
context:
space:
mode:
authorChris Lu <chris.lu@gmail.com>2020-03-22 23:52:55 -0700
committerChris Lu <chris.lu@gmail.com>2020-03-22 23:52:55 -0700
commitfbca6b29bd48eeed54511a9b53b937597eee5d19 (patch)
treee1e8aa9ea986ab116c62fce57c3441c0a33a1c6c /weed/s3api/filer_util.go
parentb77b4cc3a295b9a37cd051fd9d61bbe02b4c35bb (diff)
downloadseaweedfs-fbca6b29bd48eeed54511a9b53b937597eee5d19.tar.xz
seaweedfs-fbca6b29bd48eeed54511a9b53b937597eee5d19.zip
refactoring
Diffstat (limited to 'weed/s3api/filer_util.go')
-rw-r--r--weed/s3api/filer_util.go10
1 files changed, 5 insertions, 5 deletions
diff --git a/weed/s3api/filer_util.go b/weed/s3api/filer_util.go
index 2793ee71d..be985c893 100644
--- a/weed/s3api/filer_util.go
+++ b/weed/s3api/filer_util.go
@@ -13,7 +13,7 @@ import (
)
func (s3a *S3ApiServer) mkdir(parentDirectoryPath string, dirName string, fn func(entry *filer_pb.Entry)) error {
- return s3a.withFilerClient(func(client filer_pb.SeaweedFilerClient) error {
+ return s3a.WithFilerClient(func(client filer_pb.SeaweedFilerClient) error {
entry := &filer_pb.Entry{
Name: dirName,
@@ -47,7 +47,7 @@ func (s3a *S3ApiServer) mkdir(parentDirectoryPath string, dirName string, fn fun
}
func (s3a *S3ApiServer) mkFile(parentDirectoryPath string, fileName string, chunks []*filer_pb.FileChunk) error {
- return s3a.withFilerClient(func(client filer_pb.SeaweedFilerClient) error {
+ return s3a.WithFilerClient(func(client filer_pb.SeaweedFilerClient) error {
entry := &filer_pb.Entry{
Name: fileName,
@@ -79,7 +79,7 @@ func (s3a *S3ApiServer) mkFile(parentDirectoryPath string, fileName string, chun
func (s3a *S3ApiServer) list(parentDirectoryPath, prefix, startFrom string, inclusive bool, limit int) (entries []*filer_pb.Entry, err error) {
- err = s3a.withFilerClient(func(client filer_pb.SeaweedFilerClient) error {
+ err = s3a.WithFilerClient(func(client filer_pb.SeaweedFilerClient) error {
request := &filer_pb.ListEntriesRequest{
Directory: parentDirectoryPath,
@@ -119,7 +119,7 @@ func (s3a *S3ApiServer) list(parentDirectoryPath, prefix, startFrom string, incl
func (s3a *S3ApiServer) rm(parentDirectoryPath, entryName string, isDeleteData, isRecursive bool) error {
- return s3a.withFilerClient(func(client filer_pb.SeaweedFilerClient) error {
+ return s3a.WithFilerClient(func(client filer_pb.SeaweedFilerClient) error {
err := doDeleteEntry(client, parentDirectoryPath, entryName, isDeleteData, isRecursive)
if err != nil {
@@ -153,7 +153,7 @@ func doDeleteEntry(client filer_pb.SeaweedFilerClient, parentDirectoryPath strin
func (s3a *S3ApiServer) exists(parentDirectoryPath string, entryName string, isDirectory bool) (exists bool, err error) {
- err = s3a.withFilerClient(func(client filer_pb.SeaweedFilerClient) error {
+ err = s3a.WithFilerClient(func(client filer_pb.SeaweedFilerClient) error {
request := &filer_pb.LookupDirectoryEntryRequest{
Directory: parentDirectoryPath,