Skip to content

Commit

Permalink
server: Remove deadcode/deprecated code. (minio#2088)
Browse files Browse the repository at this point in the history
  • Loading branch information
harshavardhana authored and abperiasamy committed Jul 4, 2016
1 parent 1ec86da commit 4cfbdb1
Show file tree
Hide file tree
Showing 6 changed files with 5 additions and 56 deletions.
17 changes: 0 additions & 17 deletions api-resources.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,23 +50,6 @@ func getListObjectsV2Args(values url.Values) (prefix, token, startAfter, delimit
return
}

// Parse bucket url queries
func getBucketResources(values url.Values) (listType int, prefix, marker, delimiter string, maxkeys int, encodingType string) {
if values.Get("list-type") != "" {
listType, _ = strconv.Atoi(values.Get("list-type"))
}
prefix = values.Get("prefix")
marker = values.Get("marker")
delimiter = values.Get("delimiter")
if values.Get("max-keys") != "" {
maxkeys, _ = strconv.Atoi(values.Get("max-keys"))
} else {
maxkeys = maxObjectList
}
encodingType = values.Get("encoding-type")
return
}

// Parse bucket url queries for ?uploads
func getBucketMultipartResources(values url.Values) (prefix, keyMarker, uploadIDMarker, delimiter string, maxUploads int, encodingType string) {
prefix = values.Get("prefix")
Expand Down
12 changes: 5 additions & 7 deletions appveyor.yml
Original file line number Diff line number Diff line change
@@ -1,26 +1,24 @@
# version format
version: "{build}"

# Operating system (build VM template)
os: Visual Studio 2015
os: Windows Server 2012 R2

# Platform.
platform: x64

clone_folder: c:\gopath\src\github.com\minio\minio

# environment variables
environment:
GOPATH: c:\gopath
GO_EXTLINK_ENABLED: 0
GO15VENDOREXPERIMENT: 1

# scripts that run after cloning repository
install:
- '"C:\Program Files\Microsoft SDKs\Windows\v7.1\Bin\SetEnv.cmd" /x64'
- set PATH=%GOPATH%\bin;c:\go\bin;%PATH%
- rd C:\Go /s /q
- appveyor DownloadFile https://storage.googleapis.com/golang/go1.6.windows-amd64.zip
- 7z x go1.6.windows-amd64.zip -oC:\ >nul
- go version
- go env
- cd %GOPATH%\src\github.com\minio\minio

# to run your custom scripts instead of automatic MSBuild
build_script:
Expand Down
5 changes: 0 additions & 5 deletions fs-v1-multipart.go
Original file line number Diff line number Diff line change
Expand Up @@ -206,11 +206,6 @@ func (fs fsObjects) ListMultipartUploads(bucket, prefix, keyMarker, uploadIDMark
// all the disks. `uploads.json` carries metadata regarding on going
// multipart operation on the object.
func (fs fsObjects) newMultipartUpload(bucket string, object string, meta map[string]string) (uploadID string, err error) {
// No metadata is set, allocate a new one.
if meta == nil {
meta = make(map[string]string)
}

// Initialize `fs.json` values.
fsMeta := newFSMetaV1()

Expand Down
6 changes: 0 additions & 6 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ package main
import (
"fmt"
"os"
"path/filepath"
"sort"

"github.com/minio/cli"
Expand Down Expand Up @@ -141,11 +140,6 @@ func checkMainSyntax(c *cli.Context) {
}
}

// mustGetProfilePath must get location that the profile will be written to.
func mustGetProfilePath() string {
return filepath.Join(mustGetConfigPath(), globalMinioProfilePath)
}

func main() {
app := registerApp()
app.Before = func(c *cli.Context) error {
Expand Down
18 changes: 0 additions & 18 deletions object-errors.go
Original file line number Diff line number Diff line change
Expand Up @@ -197,15 +197,6 @@ func (e ObjectNameInvalid) Error() string {
return "Object name invalid: " + e.Bucket + "#" + e.Object
}

// UnExpectedDataSize - Reader contains more/less data than specified.
type UnExpectedDataSize struct {
Size int
}

func (e UnExpectedDataSize) Error() string {
return fmt.Sprintf("Contains more data than specified size of %d bytes.", e.Size)
}

// IncompleteBody You did not provide the number of bytes specified by the Content-Length HTTP header.
type IncompleteBody GenericError

Expand Down Expand Up @@ -241,15 +232,6 @@ func (e InvalidPart) Error() string {
return "One or more of the specified parts could not be found"
}

// InvalidPartOrder parts are not ordered as Requested
type InvalidPartOrder struct {
UploadID string
}

func (e InvalidPartOrder) Error() string {
return "Invalid part order sent for " + e.UploadID
}

// PartTooSmall - error if part size is less than 5MB.
type PartTooSmall struct {
PartSize int64
Expand Down
3 changes: 0 additions & 3 deletions xl-v1-errors.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,3 @@ var errXLReadQuorum = errors.New("Read failed. Insufficient number of disks onli

// errXLWriteQuorum - did not meet write quorum.
var errXLWriteQuorum = errors.New("Write failed. Insufficient number of disks online")

// errXLDataCorrupt - err data corrupt.
var errXLDataCorrupt = errors.New("Data likely corrupted, read failed.")

0 comments on commit 4cfbdb1

Please sign in to comment.