Go 1.17 and dependencies update (#2381)
* Update Go version to 1.17 and dependencies * Changes in ProbeHandler and LifeCycleHandler * Update CRD definitions * Update Go version to 1.17 in Github Actions Signed-off-by: Sanket Sudake <sanketsudake@gmail.com>
This commit is contained in:
@@ -261,7 +261,7 @@ func (cfg *Config) addFetcherToPodSpecWithCommand(podSpec *apiv1.PodSpec, mainCo
|
||||
InitialDelaySeconds: 1,
|
||||
PeriodSeconds: 1,
|
||||
FailureThreshold: 30,
|
||||
Handler: apiv1.Handler{
|
||||
ProbeHandler: apiv1.ProbeHandler{
|
||||
HTTPGet: &apiv1.HTTPGetAction{
|
||||
Path: "/readiness-healthz",
|
||||
Port: intstr.IntOrString{
|
||||
@@ -274,7 +274,7 @@ func (cfg *Config) addFetcherToPodSpecWithCommand(podSpec *apiv1.PodSpec, mainCo
|
||||
LivenessProbe: &apiv1.Probe{
|
||||
InitialDelaySeconds: 1,
|
||||
PeriodSeconds: 5,
|
||||
Handler: apiv1.Handler{
|
||||
ProbeHandler: apiv1.ProbeHandler{
|
||||
HTTPGet: &apiv1.HTTPGetAction{
|
||||
Path: "/healthz",
|
||||
Port: intstr.IntOrString{
|
||||
@@ -295,7 +295,7 @@ func (cfg *Config) addFetcherToPodSpecWithCommand(podSpec *apiv1.PodSpec, mainCo
|
||||
// https://github.com/kubernetes/kubernetes/issues/47576#issuecomment-308900172
|
||||
if podSpec.TerminationGracePeriodSeconds != nil {
|
||||
c.Lifecycle = &apiv1.Lifecycle{
|
||||
PreStop: &apiv1.Handler{
|
||||
PreStop: &apiv1.LifecycleHandler{
|
||||
Exec: &apiv1.ExecAction{
|
||||
Command: []string{
|
||||
"/bin/sleep",
|
||||
|
||||
@@ -43,7 +43,6 @@ import (
|
||||
typedcorev1 "k8s.io/client-go/kubernetes/typed/core/v1"
|
||||
"k8s.io/client-go/tools/record"
|
||||
"k8s.io/client-go/tools/reference"
|
||||
"k8s.io/klog"
|
||||
|
||||
fv1 "github.com/fission/fission/pkg/apis/core/v1"
|
||||
"github.com/fission/fission/pkg/crd"
|
||||
@@ -767,7 +766,7 @@ func (fetcher *Fetcher) WsStartHandler(w http.ResponseWriter, r *http.Request) {
|
||||
}
|
||||
rec, err := eventRecorder(fetcher.kubeClient)
|
||||
if err != nil {
|
||||
klog.Errorf("Error creating recorder %s", err)
|
||||
logger.Error("Error creating recorder", zap.Error(err))
|
||||
http.Error(w, err.Error(), http.StatusInternalServerError)
|
||||
}
|
||||
pods, err := fetcher.kubeClient.CoreV1().Pods(fetcher.Info.Namespace).List(ctx, metav1.ListOptions{
|
||||
@@ -801,7 +800,7 @@ func (fetcher *Fetcher) WsEndHandler(w http.ResponseWriter, r *http.Request) {
|
||||
}
|
||||
rec, err := eventRecorder(fetcher.kubeClient)
|
||||
if err != nil {
|
||||
klog.Errorf("Error creating recorder %s", err)
|
||||
logger.Error("Error creating recorder", zap.Error(err))
|
||||
http.Error(w, err.Error(), http.StatusInternalServerError)
|
||||
}
|
||||
pods, err := fetcher.kubeClient.CoreV1().Pods(fetcher.Info.Namespace).List(ctx, metav1.ListOptions{
|
||||
|
||||
Reference in New Issue
Block a user