Skip to content

Conversation

@maltesander
Copy link
Member

No description provided.

src/client.rs Outdated
/// This is supported on crate feature jsonpatch only
/// 3) Merge (https://tools.ietf.org/html/rfc7386):
/// For example, if you want to update a list you have to specify the complete list and update everything
/// 4) Strategic
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe add a note that strategic merge is not available for custom resources

src/client.rs Outdated
S: Serialize,
{
let new_status = Patch::Merge(serde_json::json!({
"apiVersion": T::API_VERSION,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this really necessary?
The docs of the patch_status method doesn't have it.

Copy link
Member Author

@maltesander maltesander Feb 19, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You mean apiVersion? Yes. Without using spark operator:
source: KubeError { source: Api(ErrorResponse { status: "Failure", message: "Incorrect version specified in apply patch. Specified patch version: , expected: spark.stackable.tech/v1", reason: "BadRequest", code: 400

…tatus for the individual strategies based on non public patch_status.
@maltesander maltesander requested a review from lfrancke February 19, 2021 09:35
@lfrancke
Copy link
Member

Could you merge/fix the conflict? It's probably my documentation :(

lfrancke
lfrancke previously approved these changes Feb 19, 2021
src/client.rs Outdated
Comment on lines 140 to 141
"apiVersion": T::API_VERSION,
"kind": T::KIND,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm 99% certain that these two are only required for the apply patch but they don't seem to hurt either....

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes just tested you were right. Removed it! One last commit :)

@maltesander maltesander merged commit bc47996 into main Feb 19, 2021
@maltesander maltesander deleted the apply_patch_status branch February 19, 2021 16:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

3 participants