Skip to content

Removal of other content types while making the patch call in latest version #3214

@prashanthjos

Description

@prashanthjos

We were using a pretty old version of Kubernetes client 11.0.2 and trying to upgrade to the latest version , when we were using the patchNamespacedSecretCall in CoreV1Api we observed that the older one had support for the below content types

 final String[] localVarContentTypes = {
      "application/json-patch+json",
      "application/merge-patch+json",
      "application/strategic-merge-patch+json",
      "application/apply-patch+yaml"
    };

However, the latest jar version 20.0.0 is having the following piece of code

 final String[] localVarContentTypes = {
            "application/json"
        };

Our Kubernetes Version is 1.25 and we are getting below error because of the missing content type application/json-patch+json

Error: {"kind":"Status","apiVersion":"v1","metadata":{},"status":"Failure","message":"415: Unsupported Media Type","reason":"UnsupportedMediaType","details":{},"code":415}

Was this intentional or a miss? If this is a miss is there someone who is already working on it, If not I can create a PR.

Client Version
20.0.0

Kubernetes Version
1.25

Java Version
Java 8

Server (please complete the following information):

  • OS: Linux
  • Environment: Container
  • Cloud: AWS

Metadata

Metadata

Assignees

No one assigned

    Labels

    lifecycle/rottenDenotes an issue or PR that has aged beyond stale and will be auto-closed.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions