Migrate to klog v2
This commit is contained in:
		
							parent
							
								
									b0fcd7d1f1
								
							
						
					
					
						commit
						655b4081f4
					
				| 
						 | 
					@ -20,7 +20,7 @@ import (
 | 
				
			||||||
	"fmt"
 | 
						"fmt"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/alicloud/alibaba-cloud-sdk-go/sdk/requests"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/alicloud/alibaba-cloud-sdk-go/sdk/requests"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/alicloud/alibaba-cloud-sdk-go/services/ess"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/alicloud/alibaba-cloud-sdk-go/services/ess"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	"time"
 | 
						"time"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -21,7 +21,7 @@ import (
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	apiv1 "k8s.io/api/core/v1"
 | 
						apiv1 "k8s.io/api/core/v1"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
						schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -21,7 +21,7 @@ import (
 | 
				
			||||||
	"time"
 | 
						"time"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"k8s.io/apimachinery/pkg/util/wait"
 | 
						"k8s.io/apimachinery/pkg/util/wait"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
type autoScalingGroups struct {
 | 
					type autoScalingGroups struct {
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -18,7 +18,7 @@ package alicloud
 | 
				
			||||||
 | 
					
 | 
				
			||||||
import (
 | 
					import (
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/alicloud/metadata"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/alicloud/metadata"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	"os"
 | 
						"os"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -27,7 +27,7 @@ import (
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/config"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/config"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/config/dynamic"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/config/dynamic"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/utils/errors"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/utils/errors"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const (
 | 
					const (
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -20,7 +20,7 @@ import (
 | 
				
			||||||
	"fmt"
 | 
						"fmt"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/alicloud/alibaba-cloud-sdk-go/services/ecs"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/alicloud/alibaba-cloud-sdk-go/services/ecs"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/alicloud/alibaba-cloud-sdk-go/services/ess"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/alicloud/alibaba-cloud-sdk-go/services/ess"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	"time"
 | 
						"time"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -26,7 +26,7 @@ import (
 | 
				
			||||||
	metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
 | 
						metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/alicloud/alibaba-cloud-sdk-go/services/ess"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/alicloud/alibaba-cloud-sdk-go/services/ess"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	kubeletapis "k8s.io/kubernetes/pkg/kubelet/apis"
 | 
						kubeletapis "k8s.io/kubernetes/pkg/kubelet/apis"
 | 
				
			||||||
	"math/rand"
 | 
						"math/rand"
 | 
				
			||||||
	"time"
 | 
						"time"
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -26,7 +26,7 @@ import (
 | 
				
			||||||
	"k8s.io/apimachinery/pkg/util/clock"
 | 
						"k8s.io/apimachinery/pkg/util/clock"
 | 
				
			||||||
	"k8s.io/apimachinery/pkg/util/rand"
 | 
						"k8s.io/apimachinery/pkg/util/rand"
 | 
				
			||||||
	"k8s.io/client-go/tools/cache"
 | 
						"k8s.io/client-go/tools/cache"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const (
 | 
					const (
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -26,7 +26,7 @@ import (
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"github.com/aws/aws-sdk-go/aws"
 | 
						"github.com/aws/aws-sdk-go/aws"
 | 
				
			||||||
	"github.com/aws/aws-sdk-go/service/autoscaling"
 | 
						"github.com/aws/aws-sdk-go/service/autoscaling"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const (
 | 
					const (
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -28,7 +28,7 @@ import (
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/config"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/config"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/utils/errors"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/utils/errors"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
						schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -40,7 +40,7 @@ import (
 | 
				
			||||||
	metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
 | 
						metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/utils/gpu"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/utils/gpu"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	kubeletapis "k8s.io/kubernetes/pkg/kubelet/apis"
 | 
						kubeletapis "k8s.io/kubernetes/pkg/kubelet/apis"
 | 
				
			||||||
	provider_aws "k8s.io/legacy-cloud-providers/aws"
 | 
						provider_aws "k8s.io/legacy-cloud-providers/aws"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -22,7 +22,7 @@ import (
 | 
				
			||||||
	"fmt"
 | 
						"fmt"
 | 
				
			||||||
	"github.com/aws/aws-sdk-go/aws/endpoints"
 | 
						"github.com/aws/aws-sdk-go/aws/endpoints"
 | 
				
			||||||
	"io/ioutil"
 | 
						"io/ioutil"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	"net/http"
 | 
						"net/http"
 | 
				
			||||||
	"os"
 | 
						"os"
 | 
				
			||||||
	"regexp"
 | 
						"regexp"
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -22,7 +22,7 @@ import (
 | 
				
			||||||
	"flag"
 | 
						"flag"
 | 
				
			||||||
	"html/template"
 | 
						"html/template"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/aws"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/aws"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	"os"
 | 
						"os"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -33,7 +33,7 @@ import (
 | 
				
			||||||
	utilerrors "k8s.io/apimachinery/pkg/util/errors"
 | 
						utilerrors "k8s.io/apimachinery/pkg/util/errors"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/config/dynamic"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/config/dynamic"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
						schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
				
			||||||
	"k8s.io/legacy-cloud-providers/azure/retry"
 | 
						"k8s.io/legacy-cloud-providers/azure/retry"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -23,7 +23,7 @@ import (
 | 
				
			||||||
	"sync"
 | 
						"sync"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
var (
 | 
					var (
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -30,7 +30,7 @@ import (
 | 
				
			||||||
	"github.com/Azure/go-autorest/autorest/adal"
 | 
						"github.com/Azure/go-autorest/autorest/adal"
 | 
				
			||||||
	"github.com/Azure/go-autorest/autorest/azure"
 | 
						"github.com/Azure/go-autorest/autorest/azure"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	"k8s.io/legacy-cloud-providers/azure/clients/diskclient"
 | 
						"k8s.io/legacy-cloud-providers/azure/clients/diskclient"
 | 
				
			||||||
	"k8s.io/legacy-cloud-providers/azure/clients/interfaceclient"
 | 
						"k8s.io/legacy-cloud-providers/azure/clients/interfaceclient"
 | 
				
			||||||
	"k8s.io/legacy-cloud-providers/azure/clients/storageaccountclient"
 | 
						"k8s.io/legacy-cloud-providers/azure/clients/storageaccountclient"
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -25,7 +25,7 @@ import (
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/config"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/config"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/utils/errors"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/utils/errors"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const (
 | 
					const (
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -28,7 +28,7 @@ import (
 | 
				
			||||||
	"strings"
 | 
						"strings"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/azure"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/azure"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
var packageTemplate = template.Must(template.New("").Parse(`/*
 | 
					var packageTemplate = template.Must(template.New("").Parse(`/*
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -23,7 +23,7 @@ import (
 | 
				
			||||||
	"time"
 | 
						"time"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"github.com/Azure/azure-sdk-for-go/services/containerservice/mgmt/2018-03-31/containerservice"
 | 
						"github.com/Azure/azure-sdk-for-go/services/containerservice/mgmt/2018-03-31/containerservice"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	apiv1 "k8s.io/api/core/v1"
 | 
						apiv1 "k8s.io/api/core/v1"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -30,7 +30,7 @@ import (
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/config/dynamic"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/config/dynamic"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	providerazure "k8s.io/legacy-cloud-providers/azure"
 | 
						providerazure "k8s.io/legacy-cloud-providers/azure"
 | 
				
			||||||
	azclients "k8s.io/legacy-cloud-providers/azure/clients"
 | 
						azclients "k8s.io/legacy-cloud-providers/azure/clients"
 | 
				
			||||||
	"k8s.io/legacy-cloud-providers/azure/retry"
 | 
						"k8s.io/legacy-cloud-providers/azure/retry"
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -32,7 +32,7 @@ import (
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/config/dynamic"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/config/dynamic"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/utils/gpu"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/utils/gpu"
 | 
				
			||||||
	cloudvolume "k8s.io/cloud-provider/volume"
 | 
						cloudvolume "k8s.io/cloud-provider/volume"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	kubeletapis "k8s.io/kubernetes/pkg/kubelet/apis"
 | 
						kubeletapis "k8s.io/kubernetes/pkg/kubelet/apis"
 | 
				
			||||||
	schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
						schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
				
			||||||
	"k8s.io/legacy-cloud-providers/azure/retry"
 | 
						"k8s.io/legacy-cloud-providers/azure/retry"
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -38,7 +38,7 @@ import (
 | 
				
			||||||
	"golang.org/x/crypto/pkcs12"
 | 
						"golang.org/x/crypto/pkcs12"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/version"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/version"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	"k8s.io/legacy-cloud-providers/azure/retry"
 | 
						"k8s.io/legacy-cloud-providers/azure/retry"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -22,7 +22,7 @@ import (
 | 
				
			||||||
	"fmt"
 | 
						"fmt"
 | 
				
			||||||
	"strconv"
 | 
						"strconv"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/baiducloud/baiducloud-sdk-go/bce"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/baiducloud/baiducloud-sdk-go/bce"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/baiducloud/baiducloud-sdk-go/util"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/baiducloud/baiducloud-sdk-go/util"
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -42,7 +42,7 @@ import (
 | 
				
			||||||
	"strings"
 | 
						"strings"
 | 
				
			||||||
	"time"
 | 
						"time"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
// GetURL gets the full URL for a http request.
 | 
					// GetURL gets the full URL for a http request.
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -21,7 +21,7 @@ import (
 | 
				
			||||||
	"sync"
 | 
						"sync"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/baiducloud/baiducloud-sdk-go/cce"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/baiducloud/baiducloud-sdk-go/cce"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
type autoScalingGroups struct {
 | 
					type autoScalingGroups struct {
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -28,7 +28,7 @@ import (
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/config"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/config"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/config/dynamic"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/config/dynamic"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/utils/errors"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/utils/errors"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
						schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -32,7 +32,7 @@ import (
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/baiducloud/baiducloud-sdk-go/bce"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/baiducloud/baiducloud-sdk-go/bce"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/baiducloud/baiducloud-sdk-go/cce"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/baiducloud/baiducloud-sdk-go/cce"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/utils/gpu"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/utils/gpu"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const (
 | 
					const (
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -21,7 +21,7 @@ import (
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/config"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/config"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/context"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/context"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
// NewCloudProvider builds a cloud provider from provided parameters.
 | 
					// NewCloudProvider builds a cloud provider from provided parameters.
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -35,7 +35,7 @@ import (
 | 
				
			||||||
	kubeinformers "k8s.io/client-go/informers"
 | 
						kubeinformers "k8s.io/client-go/informers"
 | 
				
			||||||
	kubeclient "k8s.io/client-go/kubernetes"
 | 
						kubeclient "k8s.io/client-go/kubernetes"
 | 
				
			||||||
	"k8s.io/client-go/tools/cache"
 | 
						"k8s.io/client-go/tools/cache"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	"k8s.io/utils/pointer"
 | 
						"k8s.io/utils/pointer"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -24,7 +24,7 @@ import (
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
 | 
						metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
 | 
				
			||||||
	"k8s.io/apimachinery/pkg/apis/meta/v1/unstructured"
 | 
						"k8s.io/apimachinery/pkg/apis/meta/v1/unstructured"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	"k8s.io/utils/pointer"
 | 
						"k8s.io/utils/pointer"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -24,7 +24,7 @@ import (
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
 | 
						metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
 | 
				
			||||||
	"k8s.io/apimachinery/pkg/apis/meta/v1/unstructured"
 | 
						"k8s.io/apimachinery/pkg/apis/meta/v1/unstructured"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	"k8s.io/utils/pointer"
 | 
						"k8s.io/utils/pointer"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -28,7 +28,7 @@ import (
 | 
				
			||||||
	"k8s.io/client-go/dynamic"
 | 
						"k8s.io/client-go/dynamic"
 | 
				
			||||||
	"k8s.io/client-go/kubernetes"
 | 
						"k8s.io/client-go/kubernetes"
 | 
				
			||||||
	"k8s.io/client-go/tools/clientcmd"
 | 
						"k8s.io/client-go/tools/clientcmd"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const (
 | 
					const (
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -27,7 +27,7 @@ import (
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/config"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/config"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/utils/errors"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/utils/errors"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
var _ cloudprovider.CloudProvider = (*digitaloceanCloudProvider)(nil)
 | 
					var _ cloudprovider.CloudProvider = (*digitaloceanCloudProvider)(nil)
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -26,7 +26,7 @@ import (
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"github.com/digitalocean/godo"
 | 
						"github.com/digitalocean/godo"
 | 
				
			||||||
	"golang.org/x/oauth2"
 | 
						"golang.org/x/oauth2"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
var (
 | 
					var (
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -30,7 +30,7 @@ import (
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/utils/glogx"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/utils/glogx"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	gce "google.golang.org/api/compute/v1"
 | 
						gce "google.golang.org/api/compute/v1"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const (
 | 
					const (
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -25,7 +25,7 @@ import (
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	gce "google.golang.org/api/compute/v1"
 | 
						gce "google.golang.org/api/compute/v1"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
// MachineTypeKey is used to identify MachineType.
 | 
					// MachineTypeKey is used to identify MachineType.
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -27,7 +27,7 @@ import (
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/config"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/config"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/utils/errors"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/utils/errors"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
						schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -39,7 +39,7 @@ import (
 | 
				
			||||||
	"golang.org/x/oauth2/google"
 | 
						"golang.org/x/oauth2/google"
 | 
				
			||||||
	gce "google.golang.org/api/compute/v1"
 | 
						gce "google.golang.org/api/compute/v1"
 | 
				
			||||||
	gcfg "gopkg.in/gcfg.v1"
 | 
						gcfg "gopkg.in/gcfg.v1"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const (
 | 
					const (
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -18,7 +18,7 @@ package gce
 | 
				
			||||||
 | 
					
 | 
				
			||||||
import (
 | 
					import (
 | 
				
			||||||
	"fmt"
 | 
						"fmt"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	"sync"
 | 
						"sync"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -16,7 +16,7 @@ limitations under the License.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
package gce
 | 
					package gce
 | 
				
			||||||
 | 
					
 | 
				
			||||||
import "k8s.io/klog"
 | 
					import klog "k8s.io/klog/v2"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
// There should be no imports as it is used standalone in e2e tests
 | 
					// There should be no imports as it is used standalone in e2e tests
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -31,7 +31,7 @@ import (
 | 
				
			||||||
	kubeletapis "k8s.io/kubernetes/pkg/kubelet/apis"
 | 
						kubeletapis "k8s.io/kubernetes/pkg/kubelet/apis"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"github.com/ghodss/yaml"
 | 
						"github.com/ghodss/yaml"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
// GceTemplateBuilder builds templates for GCE nodes.
 | 
					// GceTemplateBuilder builds templates for GCE nodes.
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -37,7 +37,7 @@ import (
 | 
				
			||||||
	"k8s.io/kubernetes/pkg/kubemark"
 | 
						"k8s.io/kubernetes/pkg/kubemark"
 | 
				
			||||||
	schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
						schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const (
 | 
					const (
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -26,7 +26,7 @@ import (
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/config"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/config"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/utils/errors"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/utils/errors"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const (
 | 
					const (
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -27,7 +27,7 @@ import (
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/config"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/config"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/config/dynamic"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/config/dynamic"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/utils/errors"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/utils/errors"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const (
 | 
					const (
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -37,7 +37,7 @@ import (
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/config"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/config"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/version"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/version"
 | 
				
			||||||
	certutil "k8s.io/client-go/util/cert"
 | 
						certutil "k8s.io/client-go/util/cert"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
						schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -23,7 +23,7 @@ import (
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	apiv1 "k8s.io/api/core/v1"
 | 
						apiv1 "k8s.io/api/core/v1"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
						schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -27,7 +27,7 @@ import (
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/config"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/config"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/config/dynamic"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/config/dynamic"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/utils/errors"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/utils/errors"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const (
 | 
					const (
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -33,7 +33,7 @@ import (
 | 
				
			||||||
	"gopkg.in/gcfg.v1"
 | 
						"gopkg.in/gcfg.v1"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/config"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/config"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
						schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -23,7 +23,7 @@ import (
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	apiv1 "k8s.io/api/core/v1"
 | 
						apiv1 "k8s.io/api/core/v1"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
						schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -36,7 +36,7 @@ import (
 | 
				
			||||||
	"k8s.io/apimachinery/pkg/util/sets"
 | 
						"k8s.io/apimachinery/pkg/util/sets"
 | 
				
			||||||
	schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
						schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const (
 | 
					const (
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -23,7 +23,7 @@ import (
 | 
				
			||||||
	"k8s.io/apimachinery/pkg/util/wait"
 | 
						"k8s.io/apimachinery/pkg/util/wait"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const (
 | 
					const (
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -29,7 +29,7 @@ import (
 | 
				
			||||||
	kube_client "k8s.io/client-go/kubernetes"
 | 
						kube_client "k8s.io/client-go/kubernetes"
 | 
				
			||||||
	"k8s.io/client-go/tools/record"
 | 
						"k8s.io/client-go/tools/record"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const (
 | 
					const (
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -27,7 +27,7 @@ import (
 | 
				
			||||||
	kube_util "k8s.io/autoscaler/cluster-autoscaler/utils/kubernetes"
 | 
						kube_util "k8s.io/autoscaler/cluster-autoscaler/utils/kubernetes"
 | 
				
			||||||
	kube_client "k8s.io/client-go/kubernetes"
 | 
						kube_client "k8s.io/client-go/kubernetes"
 | 
				
			||||||
	kube_record "k8s.io/client-go/tools/record"
 | 
						kube_record "k8s.io/client-go/tools/record"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
// AutoscalingContext contains user-configurable constant and configuration-related objects passed to
 | 
					// AutoscalingContext contains user-configurable constant and configuration-related objects passed to
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -27,7 +27,7 @@ import (
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/simulator"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/simulator"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	apiv1 "k8s.io/api/core/v1"
 | 
						apiv1 "k8s.io/api/core/v1"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	"k8s.io/kubernetes/pkg/api/v1/pod"
 | 
						"k8s.io/kubernetes/pkg/api/v1/pod"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -48,7 +48,7 @@ import (
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/utils/gpu"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/utils/gpu"
 | 
				
			||||||
	kube_client "k8s.io/client-go/kubernetes"
 | 
						kube_client "k8s.io/client-go/kubernetes"
 | 
				
			||||||
	kube_record "k8s.io/client-go/tools/record"
 | 
						kube_record "k8s.io/client-go/tools/record"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const (
 | 
					const (
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -45,7 +45,7 @@ import (
 | 
				
			||||||
	kube_client "k8s.io/client-go/kubernetes"
 | 
						kube_client "k8s.io/client-go/kubernetes"
 | 
				
			||||||
	"k8s.io/client-go/kubernetes/fake"
 | 
						"k8s.io/client-go/kubernetes/fake"
 | 
				
			||||||
	core "k8s.io/client-go/testing"
 | 
						core "k8s.io/client-go/testing"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"strconv"
 | 
						"strconv"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -43,7 +43,7 @@ import (
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/utils/gpu"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/utils/gpu"
 | 
				
			||||||
	schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
						schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
type scaleUpResourcesLimits map[string]int64
 | 
					type scaleUpResourcesLimits map[string]int64
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -45,7 +45,7 @@ import (
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/utils/taints"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/utils/taints"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/utils/tpu"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/utils/tpu"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const (
 | 
					const (
 | 
				
			||||||
| 
						 | 
					@ -484,7 +484,7 @@ func (a *StaticAutoscaler) RunOnce(currentTime time.Time) errors.AutoscalerError
 | 
				
			||||||
 | 
					
 | 
				
			||||||
		metrics.UpdateDurationFromStart(metrics.FindUnneeded, unneededStart)
 | 
							metrics.UpdateDurationFromStart(metrics.FindUnneeded, unneededStart)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
		if klog.V(4) {
 | 
							if klog.V(4).Enabled() {
 | 
				
			||||||
			for key, val := range scaleDown.unneededNodes {
 | 
								for key, val := range scaleDown.unneededNodes {
 | 
				
			||||||
				klog.Infof("%s is unneeded since %s duration %s", key, val.String(), currentTime.Sub(val).String())
 | 
									klog.Infof("%s is unneeded since %s duration %s", key, val.String(), currentTime.Sub(val).String())
 | 
				
			||||||
			}
 | 
								}
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -47,7 +47,7 @@ import (
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"github.com/stretchr/testify/assert"
 | 
						"github.com/stretchr/testify/assert"
 | 
				
			||||||
	"github.com/stretchr/testify/mock"
 | 
						"github.com/stretchr/testify/mock"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
type podListerMock struct {
 | 
					type podListerMock struct {
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -18,7 +18,7 @@ package utils
 | 
				
			||||||
 | 
					
 | 
				
			||||||
import (
 | 
					import (
 | 
				
			||||||
	apiv1 "k8s.io/api/core/v1"
 | 
						apiv1 "k8s.io/api/core/v1"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
// FilterOutExpendableAndSplit filters out expendable pods and splits into:
 | 
					// FilterOutExpendableAndSplit filters out expendable pods and splits into:
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -35,7 +35,7 @@ import (
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/utils/taints"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/utils/taints"
 | 
				
			||||||
	schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
						schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
// GetNodeInfosForGroups finds NodeInfos for all node groups used to manage the given nodes. It also returns a node group to sample node mapping.
 | 
					// GetNodeInfosForGroups finds NodeInfos for all node groups used to manage the given nodes. It also returns a node group to sample node mapping.
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -24,7 +24,7 @@ import (
 | 
				
			||||||
	apiv1 "k8s.io/api/core/v1"
 | 
						apiv1 "k8s.io/api/core/v1"
 | 
				
			||||||
	"k8s.io/apimachinery/pkg/api/resource"
 | 
						"k8s.io/apimachinery/pkg/api/resource"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/simulator"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/simulator"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
						schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -30,7 +30,7 @@ import (
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/utils/units"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/utils/units"
 | 
				
			||||||
	schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
						schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
// *************
 | 
					// *************
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -30,7 +30,7 @@ import (
 | 
				
			||||||
	apiv1 "k8s.io/api/core/v1"
 | 
						apiv1 "k8s.io/api/core/v1"
 | 
				
			||||||
	v1lister "k8s.io/client-go/listers/core/v1"
 | 
						v1lister "k8s.io/client-go/listers/core/v1"
 | 
				
			||||||
	"k8s.io/client-go/tools/record"
 | 
						"k8s.io/client-go/tools/record"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
						schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -21,7 +21,7 @@ import (
 | 
				
			||||||
	"k8s.io/apimachinery/pkg/api/resource"
 | 
						"k8s.io/apimachinery/pkg/api/resource"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/expander"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/expander"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/expander/random"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/expander/random"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
						schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -56,7 +56,7 @@ import (
 | 
				
			||||||
	kube_flag "k8s.io/component-base/cli/flag"
 | 
						kube_flag "k8s.io/component-base/cli/flag"
 | 
				
			||||||
	componentbaseconfig "k8s.io/component-base/config"
 | 
						componentbaseconfig "k8s.io/component-base/config"
 | 
				
			||||||
	"k8s.io/component-base/metrics/legacyregistry"
 | 
						"k8s.io/component-base/metrics/legacyregistry"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	"k8s.io/kubernetes/pkg/client/leaderelectionconfig"
 | 
						"k8s.io/kubernetes/pkg/client/leaderelectionconfig"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -25,7 +25,7 @@ import (
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	k8smetrics "k8s.io/component-base/metrics"
 | 
						k8smetrics "k8s.io/component-base/metrics"
 | 
				
			||||||
	"k8s.io/component-base/metrics/legacyregistry"
 | 
						"k8s.io/component-base/metrics/legacyregistry"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
// NodeScaleDownReason describes reason for removing node
 | 
					// NodeScaleDownReason describes reason for removing node
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -24,7 +24,7 @@ import (
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/utils/errors"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/utils/errors"
 | 
				
			||||||
	schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
						schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
// BalancingNodeGroupSetProcessor tries to keep similar node groups balanced on scale-up.
 | 
					// BalancingNodeGroupSetProcessor tries to keep similar node groups balanced on scale-up.
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -20,7 +20,7 @@ import (
 | 
				
			||||||
	"reflect"
 | 
						"reflect"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	apiv1 "k8s.io/api/core/v1"
 | 
						apiv1 "k8s.io/api/core/v1"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/context"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/context"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/utils"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/utils"
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -20,7 +20,7 @@ import (
 | 
				
			||||||
	"fmt"
 | 
						"fmt"
 | 
				
			||||||
	"strings"
 | 
						"strings"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	apiv1 "k8s.io/api/core/v1"
 | 
						apiv1 "k8s.io/api/core/v1"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -22,7 +22,7 @@ import (
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/context"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/context"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/simulator"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/simulator"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/utils/drain"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/utils/drain"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
// ScaleDownStatus represents the state of scale down.
 | 
					// ScaleDownStatus represents the state of scale down.
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -34,7 +34,7 @@ import (
 | 
				
			||||||
	"k8s.io/apimachinery/pkg/api/resource"
 | 
						"k8s.io/apimachinery/pkg/api/resource"
 | 
				
			||||||
	schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
						schedulerframework "k8s.io/kubernetes/pkg/scheduler/framework/v1alpha1"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
var (
 | 
					var (
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -25,7 +25,7 @@ import (
 | 
				
			||||||
	"k8s.io/client-go/informers"
 | 
						"k8s.io/client-go/informers"
 | 
				
			||||||
	kube_client "k8s.io/client-go/kubernetes"
 | 
						kube_client "k8s.io/client-go/kubernetes"
 | 
				
			||||||
	v1listers "k8s.io/client-go/listers/core/v1"
 | 
						v1listers "k8s.io/client-go/listers/core/v1"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
	volume_scheduling "k8s.io/kubernetes/pkg/controller/volume/scheduling"
 | 
						volume_scheduling "k8s.io/kubernetes/pkg/controller/volume/scheduling"
 | 
				
			||||||
	scheduler_apis_config "k8s.io/kubernetes/pkg/scheduler/apis/config"
 | 
						scheduler_apis_config "k8s.io/kubernetes/pkg/scheduler/apis/config"
 | 
				
			||||||
	scheduler_plugins "k8s.io/kubernetes/pkg/scheduler/framework/plugins"
 | 
						scheduler_plugins "k8s.io/kubernetes/pkg/scheduler/framework/plugins"
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -28,7 +28,7 @@ import (
 | 
				
			||||||
	kube_client "k8s.io/client-go/kubernetes"
 | 
						kube_client "k8s.io/client-go/kubernetes"
 | 
				
			||||||
	kube_record "k8s.io/client-go/tools/record"
 | 
						kube_record "k8s.io/client-go/tools/record"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const (
 | 
					const (
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -16,7 +16,7 @@ limitations under the License.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
package glogx
 | 
					package glogx
 | 
				
			||||||
 | 
					
 | 
				
			||||||
import "k8s.io/klog"
 | 
					import klog "k8s.io/klog/v2"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const (
 | 
					const (
 | 
				
			||||||
	// MaxPodsLogged is the maximum number of pods for which we will
 | 
						// MaxPodsLogged is the maximum number of pods for which we will
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -17,7 +17,7 @@ limitations under the License.
 | 
				
			||||||
package glogx
 | 
					package glogx
 | 
				
			||||||
 | 
					
 | 
				
			||||||
import (
 | 
					import (
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
type quota struct {
 | 
					type quota struct {
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -20,7 +20,7 @@ import (
 | 
				
			||||||
	"testing"
 | 
						"testing"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"github.com/stretchr/testify/assert"
 | 
						"github.com/stretchr/testify/assert"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
// Left, UpTo and Over should work as expected.
 | 
					// Left, UpTo and Over should work as expected.
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -22,7 +22,7 @@ import (
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/utils/errors"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/utils/errors"
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/utils/kubernetes"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/utils/kubernetes"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const (
 | 
					const (
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -19,7 +19,7 @@ package kubernetes
 | 
				
			||||||
import (
 | 
					import (
 | 
				
			||||||
	clientv1 "k8s.io/api/core/v1"
 | 
						clientv1 "k8s.io/api/core/v1"
 | 
				
			||||||
	"k8s.io/client-go/tools/record"
 | 
						"k8s.io/client-go/tools/record"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
type eventSinkLoggingWrapper struct {
 | 
					type eventSinkLoggingWrapper struct {
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -24,7 +24,7 @@ import (
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/utils/deletetaint"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/utils/deletetaint"
 | 
				
			||||||
	cloudproviderapi "k8s.io/cloud-provider/api"
 | 
						cloudproviderapi "k8s.io/cloud-provider/api"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const (
 | 
					const (
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -18,7 +18,7 @@ package utils
 | 
				
			||||||
 | 
					
 | 
				
			||||||
import (
 | 
					import (
 | 
				
			||||||
	apiv1 "k8s.io/api/core/v1"
 | 
						apiv1 "k8s.io/api/core/v1"
 | 
				
			||||||
	"k8s.io/klog"
 | 
						klog "k8s.io/klog/v2"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
						"k8s.io/autoscaler/cluster-autoscaler/cloudprovider"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in New Issue