Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change the data type for metadata and content fields in v1alpha1.CacheSizeSettings #2237

Merged
merged 9 commits into from
Aug 31, 2023

Conversation

kale-amruta
Copy link
Contributor

@kale-amruta kale-amruta commented Aug 3, 2023

Change Overview

// CacheSizeSettings are the metadata/content cache size details
// that can be used while establishing connection to the kopia repository
type CacheSizeSettings struct {
	Metadata string `json:"metadata"`
	Content  string `json:"content"`
}

Currently the Metadata and Content fields in CacheSizeSettings have string as a data type whereas kopia CLI accepts the values for these fields as integer.

It would be better if the CRD accepts the fields in Integer format since that would reduce the number of conversions required in the GO code

This PR changes the field types to *int for metadata and content fields

Pull request type

Please check the type of change your PR introduces:

  • 🚧 Work in Progress
  • 🌈 Refactoring (no functional changes, no api changes)
  • 🐹 Trivial/Minor
  • 🐛 Bugfix
  • 🌻 Feature
  • 🗺️ Documentation
  • 🤖 Test

Issues

Test Plan

  • 💪 Manual
  • ⚡ Unit test
  • 💚 E2E

@github-actions
Copy link
Contributor

github-actions bot commented Aug 3, 2023

Thanks for submitting this pull request 🎉. The team will review it soon and get back to you.

If you haven't already, please take a moment to review our project contributing guideline and Code of Conduct document.

@infraq infraq added this to In Progress in Kanister Aug 3, 2023
@kale-amruta kale-amruta changed the title [WIP] Change the data type for metadata and content fields in v1alpha1.CacheSizeSettings Change the data type for metadata and content fields in v1alpha1.CacheSizeSettings Aug 4, 2023
@kale-amruta kale-amruta force-pushed the changeDataTypeForRepositoryServerCRD branch from c524f05 to 0fc0def Compare August 4, 2023 07:42
@kale-amruta kale-amruta requested review from PrasadG193 and removed request for viveksinghggits August 4, 2023 07:43
@kale-amruta kale-amruta force-pushed the changeDataTypeForRepositoryServerCRD branch 2 times, most recently from ede7edf to c7dbf5b Compare August 4, 2023 12:12
Copy link
Contributor

@ankitjain235 ankitjain235 left a comment

Choose a reason for hiding this comment

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

Added minor comment, looks good otherwise.

pkg/customresource/repositoryserver.yaml Show resolved Hide resolved
@kale-amruta kale-amruta force-pushed the changeDataTypeForRepositoryServerCRD branch from 8559b19 to 6b2b63c Compare August 25, 2023 07:36
Copy link
Contributor

@ankitjain235 ankitjain235 left a comment

Choose a reason for hiding this comment

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

LGTM.

Kanister automation moved this from In Progress to Reviewer approved Aug 30, 2023
@mergify mergify bot merged commit a52fa96 into master Aug 31, 2023
15 checks passed
Kanister automation moved this from Reviewer approved to Done Aug 31, 2023
@mergify mergify bot deleted the changeDataTypeForRepositoryServerCRD branch August 31, 2023 12:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Development

Successfully merging this pull request may close these issues.

Change the data type from string to *int in cacheSizeSettings field of repositoryserver CRD
3 participants