Skip to content

Commit cc95565

Browse files
conflict
1 parent d1d3378 commit cc95565

File tree

3 files changed

+13
-10
lines changed

3 files changed

+13
-10
lines changed

tests/acceptance/features/cliCommands/backupConsistency.feature

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
@env-config @backup-consistency
1+
@env-config
22
Feature: backup consistency
33
As a user
44
I want to check my data for inconsistencies

tests/ociswrapper/ocis/ocis.go

+11-8
Original file line numberDiff line numberDiff line change
@@ -40,14 +40,15 @@ func Stop() (bool, string) {
4040
log.Println(fmt.Sprintf("Services running before terminating: %s with process and id: %v\n", listservice, pid))
4141
process, err := os.FindProcess(pid)
4242
err = process.Signal(syscall.SIGINT)
43-
if err != nil {
44-
if !strings.HasSuffix(err.Error(), "process already finished") {
45-
log.Fatalln(err)
46-
} else {
47-
return true, "oCIS server is already stopped"
48-
}
49-
}
50-
process.Wait()
43+
if err != nil {
44+
if !strings.HasSuffix(err.Error(), "process already finished") {
45+
log.Fatalln(err)
46+
} else {
47+
return true, "oCIS server is already stopped"
48+
}
49+
}
50+
process.Wait()
51+
delete(runningCommands, "ocis")
5152
}
5253

5354
cmd = nil
@@ -69,6 +70,8 @@ func Restart(envMap []string) (bool, string) {
6970
}
7071

7172
func IsOcisRunning() bool {
73+
pid, _ := runningCommands["ocis"]
74+
log.Println(fmt.Sprintf("Services process id to terminate: %s\n", pid))
7275
if runningCommands["ocis"] > 0 {
7376
return true
7477
}

tests/ociswrapper/wrapper/handlers/handler.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,7 @@ func StartOcisHandler(res http.ResponseWriter, req *http.Request) {
161161
sendResponse(res, http.StatusOK, message)
162162
return
163163
}
164-
164+
common.Wg.Wait()
165165
sendResponse(res, http.StatusInternalServerError, message)
166166
}
167167

0 commit comments

Comments
 (0)