Skip to content

provide a basic operator v1 API#125

Merged
openshift-merge-robot merged 3 commits intoopenshift:masterfrom
deads2k:operator-v1
Nov 14, 2018
Merged

provide a basic operator v1 API#125
openshift-merge-robot merged 3 commits intoopenshift:masterfrom
deads2k:operator-v1

Conversation

@deads2k
Copy link
Copy Markdown
Contributor

@deads2k deads2k commented Nov 8, 2018

Provides a basic operator v1 API based on operator API design principles (available separately, addition charges may apply) and lessons learned from the first few attempts.

/assign @jwforres

@openshift-ci-robot openshift-ci-robot added do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. approved Indicates a PR has been approved by an approver from all required OWNERS files. labels Nov 8, 2018
@jwforres
Copy link
Copy Markdown
Member

jwforres commented Nov 9, 2018

some comment updates here deads2k#1

// PrereqsSatisfied indicates that the things this operator depends on are present and at levels compatible with the
// current and desired states.
OperatorStatusTypePrereqsSatisfied = "PrereqsSatisfied"
// Upgradeable indicates that the operator configuration itself (not prereqs) can be auto-upgraded by the CVO
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

PrereqsSatisfied could be False, but Upgradeable could be True, but only if i've set ManagementState to Force?

PrereqsSatisfied could be True, but Upgradeable can be False if I've done something to make my configuration invalid?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

PrereqsSatisfied could be False, but Upgradeable could be True, but only if i've set ManagementState to Force?

I would not adjust these based on Force. I would say that Force just makes you ignore them.

PrereqsSatisfied could be True, but Upgradeable can be False if I've done something to make my configuration invalid?

make your configuration unsupportable, not invalid. I think any patch makes it unsupportable and therefore unupgradeable, but doesn't affect prereqs being satisfied (apiserver version for instance)

type OperandSpec struct {
// name is the name of this unit. The operator must be aware of it.
Name string `json:"name"`

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Should we have replicas on OperandSpec

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Should we have replicas on OperandSpec

I'd rather not unless we have to. I'd like to think that the HPA could manage that for us. Any evidence one way or the other?

@deads2k deads2k changed the title [WIP] provide a basic operator v1 API provide a basic operator v1 API Nov 13, 2018
@openshift-ci-robot openshift-ci-robot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Nov 13, 2018
@deads2k
Copy link
Copy Markdown
Contributor Author

deads2k commented Nov 13, 2018

@jwforres I think this is up to date with our current thinking.


var (
GroupName = "operator.openshift.io"
GroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1alpha1"}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

v1alpha1 ?

@jwforres
Copy link
Copy Markdown
Member

/lgtm
/hold
need to fix the one typo for v1alpha1

@openshift-ci-robot openshift-ci-robot added lgtm Indicates that a PR is ready to be merged. do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. labels Nov 14, 2018
@openshift-ci-robot
Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: deads2k, jwforres

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci-robot openshift-ci-robot removed the lgtm Indicates that a PR is ready to be merged. label Nov 14, 2018
@openshift-ci-robot
Copy link
Copy Markdown

New changes are detected. LGTM label has been removed.

@deads2k deads2k added lgtm Indicates that a PR is ready to be merged. and removed do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. labels Nov 14, 2018
@deads2k
Copy link
Copy Markdown
Contributor Author

deads2k commented Nov 14, 2018

/lgtm
/hold
need to fix the one typo for v1alpha1

fixed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants