mirror of
https://github.com/minio/minio
synced 2026-08-29 14:36:37 -04:00
Initial work for xml list objects
This commit is contained in:
parent
5a4f472638
commit
53190e1210
6 changed files with 148 additions and 10 deletions
|
|
@ -5,16 +5,16 @@ import (
|
|||
"net/http"
|
||||
)
|
||||
|
||||
func Start(handler http.Handler) (chan<- string, <-chan error) {
|
||||
func Start(handler http.Handler, address string) (chan<- string, <-chan error) {
|
||||
ctrlChannel := make(chan string)
|
||||
errorChannel := make(chan error)
|
||||
go start(ctrlChannel, errorChannel, handler)
|
||||
go start(ctrlChannel, errorChannel, handler, address)
|
||||
return ctrlChannel, errorChannel
|
||||
}
|
||||
|
||||
func start(ctrlChannel <-chan string, errorChannel chan<- error, router http.Handler) {
|
||||
log.Println("Starting HTTP Server")
|
||||
err := http.ListenAndServe(":8080", router)
|
||||
func start(ctrlChannel <-chan string, errorChannel chan<- error, router http.Handler, address string) {
|
||||
log.Println("Starting HTTP Server on " + address)
|
||||
err := http.ListenAndServe(address, router)
|
||||
errorChannel <- err
|
||||
close(errorChannel)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue