Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
K
k3s
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jacklull
k3s
Commits
f2378a2d
Commit
f2378a2d
authored
Sep 23, 2015
by
markturansky
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
shortened annotation key name, improved comments
parent
09600095
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
5 deletions
+4
-5
types.go
pkg/controller/persistentvolume/types.go
+4
-5
No files found.
pkg/controller/persistentvolume/types.go
View file @
f2378a2d
...
@@ -27,9 +27,9 @@ import (
...
@@ -27,9 +27,9 @@ import (
const
(
const
(
// A PV created specifically for one claim must contain this annotation in order to bind to the claim.
// A PV created specifically for one claim must contain this annotation in order to bind to the claim.
// The value must be the name
of the claim being bound to.
// The value must be the name
space and name of the claim being bound to (i.e, claim.Namespace/claim.Name)
// This is an experimental feature and likely to change in the future.
// This is an experimental feature and likely to change in the future.
createdForKey
=
"
persistent-volume-provisioning.experimental.kubernetes.io/creat
ed-for"
createdForKey
=
"
volume.experimental.kubernetes.io/provision
ed-for"
)
)
// persistentVolumeOrderedIndex is a cache.Store that keeps persistent volumes indexed by AccessModes and ordered by storage capacity.
// persistentVolumeOrderedIndex is a cache.Store that keeps persistent volumes indexed by AccessModes and ordered by storage capacity.
...
@@ -115,10 +115,9 @@ func (pvIndex *persistentVolumeOrderedIndex) Find(searchPV *api.PersistentVolume
...
@@ -115,10 +115,9 @@ func (pvIndex *persistentVolumeOrderedIndex) Find(searchPV *api.PersistentVolume
if
createdFor
!=
searchPV
.
Annotations
[
createdForKey
]
{
if
createdFor
!=
searchPV
.
Annotations
[
createdForKey
]
{
// the volume is pre-bound and does not match the search criteria.
// the volume is pre-bound and does not match the search criteria.
continue
continue
}
else
{
// exact annotation match! No search required.
return
volume
,
nil
}
}
// exact annotation match! No search required.
return
volume
,
nil
}
}
// volume isn't currently bound or pre-bound.
// volume isn't currently bound or pre-bound.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment