Giter VIP home page Giter VIP logo

container-object-storage-interface-api's Introduction

version apiVersion

Container Object Storage Interface API

This repository hosts the API defintion of the Custom Resource Definitions (CRD) used for the Container Object Storage Interface (COSI) project. The provisioned unit of storage is a Bucket. The following CRDs are defined for managing the lifecycle of Buckets:

  • BucketClaim - Represents a request to provision a Bucket
  • BucketClass - Represents a class of Buckets with similar characteristics
  • Bucket - Represents a Bucket or its equivalent in the storage backend

The following CRDs are defined for managing the lifecycle of workloads accessing the Bucket:

  • BucketAccessClass - Represents a class of accessors with similar access requirements
  • BucketAccess - Represents a access token or service account in the storage backend

NOTE: All of the APIs are defined under the API group objectstorage.k8s.io.

For more information about COSI, visit our documentation.

Developer Guide

All API definitions are in apis/objectstorage.k8s.io/. All API changes MUST satisfy the following requirements:

Build and Test

  1. Test and Build the project
make all
  1. Generate CRDs
make codegen

Adding new fields to protocols

  1. Create a new issue raising a RFC for the changes following this format:

Title: [RFC] Changes to protocol xyz

Info:

  1. Protocol:
  2. Fields Added:
  3. Why is this change neccessary? ...(describe why here)...
  4. Which other COSI projects are affected by this change?
  5. Upgrade plan (ignore if it doesn't apply)

References

Community, discussion, contribution, and support

You can reach the maintainers of this project at:

Code of conduct

Participation in the Kubernetes community is governed by the Kubernetes Code of Conduct.

container-object-storage-interface-api's People

Contributors

brahmaroutu avatar cyb70289 avatar gregnsk avatar k8s-ci-robot avatar krishchow avatar mukhoakash avatar nicolast avatar nikhita avatar shanduur avatar somersbmatthews avatar thotz avatar tparikh avatar wlan0 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

container-object-storage-interface-api's Issues

Update README.md

The current readme.md is out of date, and does not give guidelines for new persons interested in the project to easily get started and contribute.

Found a broken link at /docs/index.md

The link is present under the

  • Links section:
    - user guide
    - How to write a COSI driver
    - How to make your application COSI-compatible
  • Advanced section:
    - Protocols
    - Architecture
    - Internals
  • Other:
    - Weekly Meetings

DOCS request

  • Getting started
  • COSI concepts, architecture and user guide

[03/24] - Client library for parsing COSI secrets

Enhancement

Is your feature request related to a problem?/Why is this needed
It would be nice if we could have a library that end-users could import to make it easier for them to parse credentials in the mounted secret.

Describe the solution you'd like in detail
Some utility methods to load secret data into a struct that can be consumed by Go-lang clients of COSI provisioned buckets.

Describe alternatives you've considered
Users could (and probably will) create their own versions of these utility methods, but the idea is to make it easier to switch over to using COSI. If end-users currently use Secrets or environment variables to pass credentials to their applications, we can create a similar DX for COSI.

Additional context

N/A

Move clientset creation to consumers of this library

It's a bit odd for a library like this to depend on viper and have code like NewObjectStorageController which then parses command-line arguments and/or grabs environment variable settings to construct a K8s clientset object.

It's up to consumers of the library to decide which command-line flag parsing library they want to use, how they want to call the flag to point to a KubeConfig file (if any), to maybe read KUBECONFIG from the environment,...

I suggest to change the API to (only) take a clientset which is (somehow) configured correctly by API consumers.

Admission Controller

Enhancement

Is your feature request related to a problem?/Why is this needed
Validation for BR to ensure the BC exists
Validation for BAR to ensure the BAC exists
Validation on B/BA for brownfield use cases
Validation for default BC (duplicate defaults should be rejected)

Describe the solution you'd like in detail
An admission controller for the COSI controller

Describe alternatives you've considered
Kubebuilder validation - this works for validating fields in the API, however, we are not able to handle deeper validation e.g., object references.

Additional context

Is it possible to avoid specification of protocol twice?

// +kubebuilder:validation:Enum:={s3,azureBlob,gcs}
Name ProtocolName `json:"name"`
// +optional
Version string `json:"version,omitempty"`
// +optional
S3 *S3Protocol `json:"s3,omitempty"`
// +optional
AzureBlob *AzureProtocol `json:"azureBlob,omitempty"`
// +optional
GCS *GCSProtocol `json:"gcs,omitempty"`

Do we need to include Name as well as the different protocol options? This makes it so that whenever options are included, users must specify their choice twice: once in Name and once implicitly in the protocol spec. E.g.,

protocol:
  name: s3
  s3:
     blah: stuff

K8s volume claims use a syntax where the option itself implicitly specifies the option desired. E.g.,

volumes:
  - name: myDir
    emptyDir: {}

Does it make sense to follow that pattern for the protocol also? Like below would be an S3 config with no options set.

protocol:
  s3: {}

KEP partity with code:

  • API parity: container-object-storage-interface-api and KEP definitions need to be in sync

[2021-04-16] - CRDs are created with api-approved annotation, but did not complete API review

Bug Report

https://github.com/kubernetes-sigs/container-object-storage-interface-api/blob/master/kustomization.yaml#L10 adds an api-approved annotation to all loaded CRDs

The APIs in question have not actually been approved via the k8s API review process

Additionally, using a mixin to automatically add the annotation to all CRDs is not appropriate... it confers approval status on any newly introduced CRDs or updates to CRD manifests without actual review / approve.

As noted in https://github.com/kubernetes/enhancements/blob/master/keps/sig-api-machinery/2337-k8s.io-group-protection/README.md#proposal, until the API is approved, a string starting with unapproved can be used as a placeholder

cc @thockin

[2023-03-10] - Additional protocol in the API

Enhancement

Is your feature request related to a problem?/Why is this needed

In the future, there might be a need of including additional protocols. There are existing users of object storage platforms that rely on some proprietary protocols:

Describe the solution you'd like in detail

I would like additional protocols to be introduced to API.

Describe alternatives you've considered

Alternative way is to not have the protocols hardcoded into API and follow the same workflow as CSI drivers.

Additional context

This was firstly discussed on SIG Storage COSI meeting on 2023-03-09.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.