(builderId string)
| 71 | ) |
| 72 | |
| 73 | func GetOrCreateController(builderId string) *BuilderController { |
| 74 | mapLock.Lock() |
| 75 | defer mapLock.Unlock() |
| 76 | |
| 77 | bc := controllerMap[builderId] |
| 78 | if bc != nil { |
| 79 | return bc |
| 80 | } |
| 81 | |
| 82 | bc = &BuilderController{ |
| 83 | builderId: builderId, |
| 84 | status: BuilderStatus_Init, |
| 85 | statusVersion: 0, |
| 86 | } |
| 87 | controllerMap[builderId] = bc |
| 88 | |
| 89 | return bc |
| 90 | } |
| 91 | |
| 92 | func GetController(builderId string) *BuilderController { |
| 93 | mapLock.Lock() |
no outgoing calls
no test coverage detected