summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoraustin <me@austbot.com>2018-05-11 16:40:22 -0700
committeraustin <me@austbot.com>2018-05-11 17:49:41 -0700
commitc63e62b58e791fb2fdbc048182674ee9b2a4b152 (patch)
tree868cc999c52ac41fd741e353dfeab0e385f53e92
parenta787732d8c663262d112248a9f202da92c742e7f (diff)
Corrects location of core defaults.go based on current kubernetes/kubernetes repo.
-rw-r--r--contributors/devel/api_changes.md12
1 files changed, 8 insertions, 4 deletions
diff --git a/contributors/devel/api_changes.md b/contributors/devel/api_changes.md
index 2440902e..3c457f25 100644
--- a/contributors/devel/api_changes.md
+++ b/contributors/devel/api_changes.md
@@ -365,10 +365,14 @@ being required otherwise.
### Edit defaults.go
If your change includes new fields for which you will need default values, you
-need to add cases to `pkg/apis/<group>/<version>/defaults.go` (the core v1 API
-is special, its defaults.go is at `pkg/api/v1/defaults.go`. For simplicity, we
-will not mention this special case in the rest of the article). Of course, since
-you have added code, you have to add a test:
+need to add cases to `pkg/apis/<group>/<version>/defaults.go`
+
+*Note:* In the past the core v1 API
+was special. Its `defaults.go` used to live at `pkg/api/v1/defaults.go`.
+If you see code referencing that path, you can be sure its outdated. Now the core v1 api lives at
+`pkg/apis/core/v1/defaults.go` which follows the above convention.
+
+Of course, since you have added code, you have to add a test:
`pkg/apis/<group>/<version>/defaults_test.go`.
Do use pointers to scalars when you need to distinguish between an unset value