Skip to content

Commit

Permalink
update api dependency
Browse files Browse the repository at this point in the history
Signed-off-by: Thor-wl <13164644535@163.com>
  • Loading branch information
Thor-wl committed Dec 31, 2021
1 parent 2bb4eb1 commit 9166f1f
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 20 deletions.
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ require (
k8s.io/kubernetes v1.19.15
sigs.k8s.io/yaml v1.2.0
stathat.com/c/consistent v1.0.0
volcano.sh/apis v0.0.0-20211109104455-7e8d893a9f66
volcano.sh/apis v1.5.0-beta.0
)

replace (
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -1143,5 +1143,5 @@ sigs.k8s.io/yaml v1.2.0/go.mod h1:yfXDCHCao9+ENCvLSE62v9VSji2MKu5jeNfTrofGhJc=
stathat.com/c/consistent v1.0.0 h1:ezyc51EGcRPJUxfHGSgJjWzJdj3NiMU9pNfLNGiXV0c=
stathat.com/c/consistent v1.0.0/go.mod h1:QkzMWzcbB+yQBL2AttO6sgsQS/JSTapcDISJalmCDS0=
vbom.ml/util v0.0.0-20160121211510-db5cfe13f5cc/go.mod h1:so/NYdZXCz+E3ZpW0uAoCj6uzU2+8OWDFv/HxUSs7kI=
volcano.sh/apis v0.0.0-20211109104455-7e8d893a9f66 h1:vmCou3lcAeNSmyMXBVlfQnJYsQvhfS3mMv2FJrtACyg=
volcano.sh/apis v0.0.0-20211109104455-7e8d893a9f66/go.mod h1:UaeJ/s5Hyd+ZhFLc+Kw9YlgM8gRZ/5OzXqHa0yKOoXY=
volcano.sh/apis v1.5.0-beta.0 h1:INpucg/p8Q/6aw8nKB4YrRMIqhFQIWPujE5qbYp/QYQ=
volcano.sh/apis v1.5.0-beta.0/go.mod h1:UaeJ/s5Hyd+ZhFLc+Kw9YlgM8gRZ/5OzXqHa0yKOoXY=
2 changes: 1 addition & 1 deletion vendor/modules.txt
Original file line number Diff line number Diff line change
Expand Up @@ -855,7 +855,7 @@ sigs.k8s.io/yaml
# stathat.com/c/consistent v1.0.0
## explicit
stathat.com/c/consistent
# volcano.sh/apis v0.0.0-20211109104455-7e8d893a9f66
# volcano.sh/apis v1.5.0-beta.0
## explicit
volcano.sh/apis/pkg/apis/batch/v1alpha1
volcano.sh/apis/pkg/apis/bus/v1alpha1
Expand Down
20 changes: 4 additions & 16 deletions vendor/volcano.sh/apis/pkg/apis/helpers/helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -143,22 +143,10 @@ func CreateOrUpdateSecret(job *vcbatch.Job, kubeClients kubernetes.Interface, da

// DeleteConfigmap deletes the config map resource.
func DeleteConfigmap(job *vcbatch.Job, kubeClients kubernetes.Interface, cmName string) error {
if _, err := kubeClients.CoreV1().ConfigMaps(job.Namespace).Get(context.TODO(), cmName, metav1.GetOptions{}); err != nil {
if !apierrors.IsNotFound(err) {
klog.V(3).Infof("Failed to get Configmap for Job <%s/%s>: %v",
job.Namespace, job.Name, err)
return err
}
return nil

}

if err := kubeClients.CoreV1().ConfigMaps(job.Namespace).Delete(context.TODO(), cmName, metav1.DeleteOptions{}); err != nil {
if !apierrors.IsNotFound(err) {
klog.Errorf("Failed to delete Configmap of Job %v/%v: %v",
job.Namespace, job.Name, err)
return err
}
if err := kubeClients.CoreV1().ConfigMaps(job.Namespace).Delete(context.TODO(), cmName, metav1.DeleteOptions{}); err != nil && !apierrors.IsNotFound(err) {
klog.Errorf("Failed to delete Configmap of Job %v/%v: %v",
job.Namespace, job.Name, err)
return err
}

return nil
Expand Down
3 changes: 3 additions & 0 deletions vendor/volcano.sh/apis/pkg/apis/scheduling/v1beta1/labels.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,3 +46,6 @@ const JDBMaxUnavailable = "volcano.sh/jdb-max-unavailable"

// NumaPolicyKey is the key of pod nuam-topology policy
const NumaPolicyKey = "volcano.sh/numa-topology-policy"

// TopologyDecisionAnnotation is the key of topology decision about pod request resource
const TopologyDecisionAnnotation = "volcano.sh/topology-decision"

0 comments on commit 9166f1f

Please sign in to comment.