@@ -25,17 +25,6 @@ func ComputeRegistrationNeeds(db gorp.SqlExecutor, allBinaryReqs sdk.Requirement
25
25
26
26
for _ , r := range reqs {
27
27
switch r .Type {
28
- case sdk .BinaryRequirement :
29
- exist := false
30
- for _ , e := range allBinaryReqs {
31
- if e .Value == r .Value {
32
- exist = true
33
- break
34
- }
35
- }
36
- if ! exist {
37
- return updateAllToCheckRegistration (db )
38
- }
39
28
case sdk .OSArchRequirement :
40
29
nbOSArchReq ++
41
30
case sdk .ModelRequirement :
@@ -63,21 +52,6 @@ func ComputeRegistrationNeeds(db gorp.SqlExecutor, allBinaryReqs sdk.Requirement
63
52
return nil
64
53
}
65
54
66
- // updateAllToCheckRegistration is like need_registration but without exclusive mode
67
- func updateAllToCheckRegistration (db gorp.SqlExecutor ) error {
68
- query := `UPDATE worker_model SET check_registration = $1`
69
- res , err := db .Exec (query , true )
70
- if err != nil {
71
- return sdk .WithStack (err )
72
- }
73
- rows , err := res .RowsAffected ()
74
- if err != nil {
75
- return sdk .WithStack (err )
76
- }
77
- log .Debug (context .Background (), "updateAllToCheckRegistration> %d worker model(s) check registration" , rows )
78
- return nil
79
- }
80
-
81
55
// UpdateSpawnErrorWorkerModel updates worker model error registration
82
56
func UpdateSpawnErrorWorkerModel (db gorp.SqlExecutor , modelID int64 , spawnError sdk.SpawnErrorForm ) error {
83
57
spawnError .Error = sdk .RemoveNotPrintableChar (spawnError .Error )
0 commit comments