-
Notifications
You must be signed in to change notification settings - Fork 4.7k
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
Add flag to disable dynamic provisioning #8426
Add flag to disable dynamic provisioning #8426
Conversation
shouldn't that already be expressable with |
// MasterVolumeConfig contains options for configuring volumes on the node. | ||
type MasterVolumeConfig struct { | ||
// EnableDynamicProvisioning is a boolean that toggles the dynamic provisioning feature on/off | ||
EnableDynamicProvisioning bool |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't really want a one-off flag for a particular controller, I'd rather work to make the controllers
config param effective for disabling a subset of controllers
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We don't have time for the broader refactor. It's too risky a change for
1.2. DynamicProvisioning as a feature flag is ok.
On Fri, Apr 8, 2016 at 11:14 AM, Jordan Liggitt [email protected]
wrote:
In pkg/cmd/server/api/types.go
#8426 (comment):// LocalQuota contains options for controlling local volume quota on the node. LocalQuota LocalQuota
}
+// MasterVolumeConfig contains options for configuring volumes on the node.
+type MasterVolumeConfig struct {
- // EnableDynamicProvisioning is a boolean that toggles the dynamic provisioning feature on/off
- EnableDynamicProvisioning bool
I don't really want a one-off flag for a particular controller, I'd rather
work to make the controllers config param effective for disabling a
subset of controllers—
You are receiving this because you were mentioned.
Reply to this email directly or view it on GitHub
https://github.com/openshift/origin/pull/8426/files/e58a75d0de05e59a0b4fe05a06e20adc90aec313#r59040426
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As a general rule, controllers enablement is about sharding controllers
(admin operational performance concern). Disabling dynamic provisioning is
an operational admin feature.
On Fri, Apr 8, 2016 at 11:20 AM, Clayton Coleman [email protected]
wrote:
We don't have time for the broader refactor. It's too risky a change for
1.2. DynamicProvisioning as a feature flag is ok.On Fri, Apr 8, 2016 at 11:14 AM, Jordan Liggitt [email protected]
wrote:In pkg/cmd/server/api/types.go
#8426 (comment):// LocalQuota contains options for controlling local volume quota on the node.
LocalQuota LocalQuota
}+// MasterVolumeConfig contains options for configuring volumes on the node.
+type MasterVolumeConfig struct {
- // EnableDynamicProvisioning is a boolean that toggles the dynamic provisioning feature on/off
- EnableDynamicProvisioning bool
I don't really want a one-off flag for a particular controller, I'd
rather work to make the controllers config param effective for disabling
a subset of controllers—
You are receiving this because you were mentioned.
Reply to this email directly or view it on GitHub
https://github.com/openshift/origin/pull/8426/files/e58a75d0de05e59a0b4fe05a06e20adc90aec313#r59040426
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jsafrane @swagiaal The new consolidated controller coming in Kube 1.3 will need a constructor arg to enable/disable only one piece/subset of your overall controller. We can then use this proposed flag for that arg. A similar flag can be added to kube-controller-manager as well.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
in the external version, this has to be a *bool
so we can tell the difference between unspecified (which needs to default to true
for backwards compatibility with current configs) and false
Approved for 1.2 or 1.2.x? |
@deads2k 1.2 so we can get this into OSE. OSO Ops would then update and configure this new flag. |
019d74a
to
b5a4964
Compare
@liggitt boolean pointer added to external types along with conversions funcs and fuzzer. |
@@ -68,6 +69,11 @@ func fuzzInternalObject(t *testing.T, forVersion unversioned.GroupVersion, item | |||
// The final value of OAuthConfig.MasterCA should never be nil | |||
obj.OAuthConfig.MasterCA = &s | |||
} | |||
if time.Now().Second()%2 == 0 { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if all the iterations happen in a second you'll only exercise one path
use c.RandBool()
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
actually, the FuzzNoCustom above should be doing that already
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You're right. I tested without this and the serialization test works. Removed.
@liggitt as discussed in IRC, i inverted the opt-in to opt-out by changing to "Disable..." and removing the pointer from the bool. Since I got to remove code to make this change, it's the right way to go and it preserves current behavior. |
@@ -71,13 +71,19 @@ type NodeConfig struct { | |||
IPTablesSyncPeriod string `json:"iptablesSyncPeriod"` | |||
|
|||
// VolumeConfig contains options for configuring volumes on the node. | |||
VolumeConfig VolumeConfig `json:"volumeConfig"` | |||
VolumeConfig NodeVolumeConfig |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
don't remove json tags
@liggitt all json tags added. |
// LocalQuota contains options for controlling local volume quota on the node. | ||
LocalQuota LocalQuota `json:"localQuota"` | ||
LocalQuota LocalQuota |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
json tag
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
added
bc96c95
to
d55997e
Compare
@@ -767,6 +767,6 @@ var map_VolumeConfig = map[string]string{ | |||
"localQuota": "LocalQuota contains options for controlling local volume quota on the node.", | |||
} | |||
|
|||
func (VolumeConfig) SwaggerDoc() map[string]string { | |||
func (NodeVolumeConfig) SwaggerDoc() map[string]string { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hack/update-generated-swagger-descriptions.sh should create one like this for MasterVolumeConfig
@liggitt I added code for I am not familiar with these configs, so I am probably missing something obvious. Can you help me figure out how to get the test correct? I feel it's close, but something is missing.... |
I think you just put it in the wrong place... needs to be at the end of the master config, alphabetically |
@liggitt and that was it :) |
[test] |
cbaabb9
to
b2d75d7
Compare
@liggitt squashed. thanks! |
lgtm |
Explain to me why we are using |
@smarterclayton @liggitt I reverted back to *bool. PTAL. I'll squash that 2nd commit after you've had a chance to review it. |
de85f98
to
03e7959
Compare
API docs need be updated. On Mon, Apr 11, 2016 at 12:30 PM, OpenShift Bot [email protected]
|
Unrelated failure? Both builds worked but the "conformance build" had a failure:
|
Approved but needs re-review |
@@ -307,6 +307,23 @@ func addConversionFuncs(scheme *runtime.Scheme) { | |||
out.Location = in.Location | |||
return nil | |||
}, | |||
func(in *MasterVolumeConfig, out *internal.MasterVolumeConfig, s conversion.Scope) error { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
simplify to
out.DynamicProvisioningEnabled = (in.DynamicProvisioningEnabled == nil) || (*in.DynamicProvisioningEnabled)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
changed. this is more succinct.
[test] On Mon, Apr 11, 2016 at 6:05 PM, OpenShift Bot [email protected]
|
f51240a
to
e056714
Compare
squashed |
Unrelated flake:
|
[test] |
Tests passed except for the deployment flake |
@smarterclayton @liggitt Anything else I can do to get this PR merged? |
@abhgupta @smarterclayton @liggitt do we want to cherry pick this into 3.2 so Online can use it for the Dev Preview? |
LGTM [test] |
Evaluated for origin test up to e056714 |
continuous-integration/openshift-jenkins/test FAILURE (https://ci.openshift.redhat.com/jenkins/job/test_pr_origin/3012/) |
Flake from conformance test. Two other Jenkins jobs both passed.
|
[merge] |
continuous-integration/openshift-jenkins/merge SUCCESS (https://ci.openshift.redhat.com/jenkins/job/merge_pull_requests_origin/5599/) (Image: devenv-rhel7_3978) |
Evaluated for origin merge up to e056714 |
@liggitt issue created openshift/openshift-ansible#1759 |
OpenShift Online would like to disable the default dynamic provisioning inherent in Kube. We're implementing our own provisioning controller that will run in a pod on the cluster.
@liggitt @deads2k @ironcladlou @abhgupta
@smarterclayton approved this new boolean config item.