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

Windows: Fix camelCase inconsistencies #859

Merged
merged 1 commit into from
May 31, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions config-windows.md
Original file line number Diff line number Diff line change
Expand Up @@ -106,8 +106,8 @@ The following parameters can be specified:

## <a name="configWindowsCredentialSpec" />Credential Spec

You can configure a container's group Managed Service Account (gMSA) via the OPTIONAL `credentialspec` field of the Windows configuration.
The `credentialspec` is a JSON object whose properties are implementation-defined.
You can configure a container's group Managed Service Account (gMSA) via the OPTIONAL `credentialSpec` field of the Windows configuration.
The `credentialSpec` is a JSON object whose properties are implementation-defined.
For more information about gMSAs, see [Active Directory Service Accounts for Windows Containers][gMSAOverview].
For more information about tooling to generate a gMSA, see [Deployment Overview][gMSATooling].

Expand All @@ -130,13 +130,13 @@ You can indicate that a container should be started in a mode to apply pending s

## <a name="configWindowsIgnoreFlushesDuringBoot" />IgnoreFlushesDuringBoot

You can indicate that a container should be started in an a mode where disk flushes are not performed during container boot via the OPTIONAL `ignoreflushesduringboot` field of the Windows configuration.
You can indicate that a container should be started in an a mode where disk flushes are not performed during container boot via the OPTIONAL `ignoreFlushesDuringBoot` field of the Windows configuration.

### Example

```json
"windows": {
"ignoreflushesduringboot": true
"ignoreFlushesDuringBoot": true
}
```

Expand All @@ -146,14 +146,14 @@ You can indicate that a container should be started in an a mode where disk flus

The following parameters can be specified:

* **`utilityvmpath`** *(string, OPTIONAL)* - specifies the path to the image used for the utility VM. This would be specified if using a base image which does not contain a utility VM image. If not supplied, the runtime will search the container filesystem layers from the bottom-most layer upwards, until it locates "UtilityVM", and default to that path.
* **`utilityVMPath`** *(string, OPTIONAL)* - specifies the path to the image used for the utility VM. This would be specified if using a base image which does not contain a utility VM image. If not supplied, the runtime will search the container filesystem layers from the bottom-most layer upwards, until it locates "UtilityVM", and default to that path.

### Example

```json
"windows": {
"hyperv": {
"utilityvmpath": "C:\\path\\to\\utilityvm"
"utilityVMPath": "C:\\path\\to\\utilityvm"
}
}
```
12 changes: 6 additions & 6 deletions schema/config-windows.json
Original file line number Diff line number Diff line change
Expand Up @@ -78,24 +78,24 @@
}
}
},
"credentialspec": {
"id": "https://opencontainers.org/schema/bundle/windows/credentialspec",
"credentialSpec": {
"id": "https://opencontainers.org/schema/bundle/windows/credentialSpec",
"type": "object"
},
"servicing": {
"id": "https://opencontainers.org/schema/bundle/windows/servicing",
"type": "boolean"
},
"ignoreflushesduringboot": {
"id": "https://opencontainers.org/schema/bundle/windows/ignoreflushesduringboot",
"ignoreFlushesDuringBoot": {
"id": "https://opencontainers.org/schema/bundle/windows/ignoreFlushesDuringBoot",
"type": "boolean"
},
"hyperv": {
"id": "https://opencontainers.org/schema/bundle/windows/hyperv",
"type": "object",
"properties": {
"utilityvmpath": {
"id": "https://opencontainers.org/schema/bundle/windows/hyperv/utilityvmpath",
"utilityVMPath": {
"id": "https://opencontainers.org/schema/bundle/windows/hyperv/utilityVMPath",
"type": "string"
}
}
Expand Down
6 changes: 3 additions & 3 deletions specs-go/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -433,11 +433,11 @@ type Windows struct {
// Resources contains information for handling resource constraints for the container.
Resources *WindowsResources `json:"resources,omitempty"`
// CredentialSpec contains a JSON object describing a group Managed Service Account (gMSA) specification.
CredentialSpec interface{} `json:"credentialspec,omitempty"`
CredentialSpec interface{} `json:"credentialSpec,omitempty"`
// Servicing indicates if the container is being started in a mode to apply a Windows Update servicing operation.
Servicing bool `json:"servicing,omitempty"`
// IgnoreFlushesDuringBoot indicates if the container is being started in a mode where disk writes are not flushed during its boot process.
IgnoreFlushesDuringBoot bool `json:"ignoreflushesduringboot,omitempty"`
IgnoreFlushesDuringBoot bool `json:"ignoreFlushesDuringBoot,omitempty"`
// HyperV contains information for running a container with Hyper-V isolation.
HyperV *WindowsHyperV `json:"hyperv,omitempty"`
// Network restriction configuration.
Expand Down Expand Up @@ -495,7 +495,7 @@ type WindowsNetwork struct {
// WindowsHyperV contains information for configuring a container to run with Hyper-V isolation.
type WindowsHyperV struct {
// UtilityVMPath is an optional path to the image used for the Utility VM.
UtilityVMPath string `json:"utilityvmpath,omitempty"`
UtilityVMPath string `json:"utilityVMPath,omitempty"`
Copy link
Contributor

Choose a reason for hiding this comment

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

On the unabbreviation front, this could be utilityVirtualMachinePath. I don't see a way to draw a hard line for this, and it's orthogonal to camelCasing, but I thought I'd point out that defdefault style expansion is something of a slippery slope. My own fuzzy possition is that I like defdefault but am less enthusiastic about VMVirtualMachine. And while I think blkioThrottleWriteIOPSDevice is a bit hard to read, it may be a better choice than throttleWriteOperationsPerSecondPerDevice. But if anyone does see a way to draw a good line, it would be nice to document that line in style.md.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes, I agree it's a fine line, but IMO, I would say VM is a very common abbreviation for 'Virtual Machine' and think it's OK as is.

Copy link
Contributor

Choose a reason for hiding this comment

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

FYI, I no longer work on containers, I will find a point of contact from Solaris for you guys.
Sorry about this.

Copy link
Contributor

Choose a reason for hiding this comment

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

hey @wking and @jhowardmsft. i'll be taking over responsibility for the solaris containers work from @anuthan. i did an audit of our use of camel case and i'd prefer not to change it. in general we've tried to have our property names map to zonecfg.1m properties. "defrouter" being a good example. the places where we have used camel case is for zonecfg properties that have hyphens in them. so for example the zonecfg "allowed-address" property has been mapped to allowedAddress. hopefully this seems sensible to folks.

that said, john correctly noted that some of our doc links are broken so i filed issue #864 on that.

}

// LinuxSeccomp represents syscall restrictions
Expand Down