mirror of https://github.com/dapr/cli.git
Merge branch 'release-1.15' into release/matrix
This commit is contained in:
commit
2960ef2df4
|
|
@ -49,6 +49,7 @@ const (
|
||||||
|
|
||||||
numHAPodsWithScheduler = 16
|
numHAPodsWithScheduler = 16
|
||||||
numHAPodsOld = 13
|
numHAPodsOld = 13
|
||||||
|
numNonHAPodsWithHAScheduler = 8
|
||||||
numNonHAPodsWithScheduler = 6
|
numNonHAPodsWithScheduler = 6
|
||||||
numNonHAPodsOld = 5
|
numNonHAPodsOld = 5
|
||||||
|
|
||||||
|
|
@ -57,7 +58,10 @@ const (
|
||||||
devZipkinReleaseName = "dapr-dev-zipkin"
|
devZipkinReleaseName = "dapr-dev-zipkin"
|
||||||
)
|
)
|
||||||
|
|
||||||
var VersionWithScheduler = semver.MustParse("1.14.0-rc.1")
|
var (
|
||||||
|
VersionWithScheduler = semver.MustParse("1.14.0-rc.1")
|
||||||
|
VersionWithHAScheduler = semver.MustParse("1.15.0-rc.1")
|
||||||
|
)
|
||||||
|
|
||||||
type VersionDetails struct {
|
type VersionDetails struct {
|
||||||
RuntimeVersion string
|
RuntimeVersion string
|
||||||
|
|
@ -1232,24 +1236,27 @@ func getVersionedNumberOfPods(isHAEnabled bool, details VersionDetails) (int, er
|
||||||
return 0, err
|
return 0, err
|
||||||
}
|
}
|
||||||
|
|
||||||
if rv.LessThan(VersionWithScheduler) {
|
if rv.GreaterThanEqual(VersionWithScheduler) {
|
||||||
return numHAPodsOld, nil
|
|
||||||
}
|
|
||||||
return numHAPodsWithScheduler, nil
|
return numHAPodsWithScheduler, nil
|
||||||
|
}
|
||||||
|
return numHAPodsOld, nil
|
||||||
} else {
|
} else {
|
||||||
if details.UseDaprLatestVersion {
|
if details.UseDaprLatestVersion {
|
||||||
return numNonHAPodsWithScheduler, nil
|
return numNonHAPodsWithHAScheduler, nil
|
||||||
}
|
}
|
||||||
rv, err := semver.NewVersion(details.RuntimeVersion)
|
rv, err := semver.NewVersion(details.RuntimeVersion)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return 0, err
|
return 0, err
|
||||||
}
|
}
|
||||||
|
|
||||||
if rv.LessThan(VersionWithScheduler) {
|
if rv.GreaterThanEqual(VersionWithHAScheduler) {
|
||||||
return numNonHAPodsOld, nil
|
return numNonHAPodsWithHAScheduler, nil
|
||||||
}
|
}
|
||||||
|
if rv.GreaterThanEqual(VersionWithScheduler) {
|
||||||
return numNonHAPodsWithScheduler, nil
|
return numNonHAPodsWithScheduler, nil
|
||||||
}
|
}
|
||||||
|
return numNonHAPodsOld, nil
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
func exportCurrentCertificate(daprPath string) error {
|
func exportCurrentCertificate(daprPath string) error {
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue