debugging a hung mutex lock
This commit is contained in:
parent
9b9c51d964
commit
49a06843e9
2
init.go
2
init.go
|
@ -43,6 +43,8 @@ func Init() *Forge {
|
||||||
f.rillUpdate(20, 10)
|
f.rillUpdate(20, 10)
|
||||||
|
|
||||||
if f.configSave {
|
if f.configSave {
|
||||||
|
// taking this out to debug Marshal() panic
|
||||||
|
// os.Exit(-1)
|
||||||
f.ConfigSave()
|
f.ConfigSave()
|
||||||
f.configSave = false
|
f.configSave = false
|
||||||
}
|
}
|
||||||
|
|
3
rill.go
3
rill.go
|
@ -30,6 +30,7 @@ func (f *Forge) rillUpdate(pool1 int, pool2 int) (int, error) {
|
||||||
// Concurrency = 10
|
// Concurrency = 10
|
||||||
err := rill.ForEach(rills, pool2, func(repo *gitpb.Repo) error {
|
err := rill.ForEach(rills, pool2, func(repo *gitpb.Repo) error {
|
||||||
counter += 1
|
counter += 1
|
||||||
|
// log.Info("rill.ForEach() gopath=", repo.GetGoPath())
|
||||||
return f.updateRepo(repo)
|
return f.updateRepo(repo)
|
||||||
})
|
})
|
||||||
|
|
||||||
|
@ -38,7 +39,7 @@ func (f *Forge) rillUpdate(pool1 int, pool2 int) (int, error) {
|
||||||
|
|
||||||
func (f *Forge) updateRepo(repo *gitpb.Repo) error {
|
func (f *Forge) updateRepo(repo *gitpb.Repo) error {
|
||||||
if !repo.IsValidDir() {
|
if !repo.IsValidDir() {
|
||||||
log.Printf("%10s %-50s", "bad git dir\n", repo.FullPath)
|
log.Printf("%10s %-50s gopath=%s\n", "git dir is missing:", repo.FullPath, repo.GetGoPath())
|
||||||
f.Repos.DeleteByFullPath(repo.FullPath)
|
f.Repos.DeleteByFullPath(repo.FullPath)
|
||||||
f.configSave = true
|
f.configSave = true
|
||||||
return nil
|
return nil
|
||||||
|
|
Loading…
Reference in New Issue