File tree 2 files changed +7
-2
lines changed
2 files changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -349,13 +349,18 @@ export class ApplicationController {
349
349
const isCpuChanged = origin . resource . limitCPU !== doc . resource . limitCPU
350
350
const isMemoryChanged =
351
351
origin . resource . limitMemory !== doc . resource . limitMemory
352
+ const isAutoscalingCanceled =
353
+ ! doc . autoscaling . enable && origin . autoscaling . enable
352
354
353
355
if ( ! isEqual ( doc . autoscaling , origin . autoscaling ) ) {
354
356
const { hpa, app } = await this . instance . get ( appid )
355
357
await this . instance . reapplyHorizontalPodAutoscaler ( app , hpa )
356
358
}
357
359
358
- if ( isRunning && ( isCpuChanged || isMemoryChanged ) ) {
360
+ if (
361
+ isRunning &&
362
+ ( isCpuChanged || isMemoryChanged || isAutoscalingCanceled )
363
+ ) {
359
364
await this . application . updateState ( appid , ApplicationState . Restarting )
360
365
}
361
366
Original file line number Diff line number Diff line change @@ -29,7 +29,7 @@ export class ApplicationConfigurationService {
29
29
try {
30
30
await session . withTransaction ( async ( ) => {
31
31
const coll = db . collection ( CN_PUBLISHED_CONF )
32
- await coll . deleteOne ( { appid : conf . appid } , { session } )
32
+ await coll . deleteMany ( { } , { session } )
33
33
await coll . insertOne ( conf , { session } )
34
34
} )
35
35
} finally {
You can’t perform that action at this time.
0 commit comments