Esempio n. 1
0
// getNewAPI instantiate a new minio API
func getNewAPI() MinioAPI {
	// ignore errors for now
	d, err := donut.New()
	fatalIf(err.Trace(), "Instantiating donut failed.", nil)

	return MinioAPI{
		OP:    make(chan APIOperation),
		Donut: d,
	}
}
Esempio n. 2
0
File: api.go Progetto: kahing/minio
// New instantiate a new minio API
func New() Minio {
	// ignore errors for now
	d, err := donut.New()
	if err != nil {
		panic(err)
	}
	return Minio{
		OP:    make(chan Operation),
		Donut: d,
	}
}
Esempio n. 3
0
// getNewAPI instantiate a new minio API
func getNewAPI(anonymous bool) API {
	// ignore errors for now
	d, err := donut.New()
	fatalIf(err.Trace(), "Instantiating donut failed.", nil)

	return API{
		OP:        make(chan APIOperation),
		Donut:     d,
		Anonymous: anonymous,
	}
}