Rework the way database is open/re-open in aptly

Allow database to be initialized without opening, unify all the
open paths to retry on failure.

In API router make sure open requests are matched with acks in explicit
way.

This also enables re-open attempts in all the aptly commands, so it
should make running aptly CLI much easier now hopefully.

Fix up system tests for oldoldstable ;)
This commit is contained in:
Andrey Smirnov
2017-07-05 00:17:48 +03:00
parent af2f7baf63
commit 211ac0501f
36 changed files with 138 additions and 106 deletions

View File

@@ -1,7 +1,9 @@
package main
import (
"math/rand"
"os"
"time"
"github.com/smira/aptly/aptly"
"github.com/smira/aptly/cmd"
@@ -17,5 +19,7 @@ func main() {
aptly.Version = Version
rand.Seed(time.Now().UnixNano())
os.Exit(cmd.Run(cmd.RootCommand(), os.Args[1:], true))
}