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
94b0bd89
Commit
94b0bd89
authored
Feb 21, 2019
by
luhualin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix dynamic informer tweakListOptions
parent
59beb8c3
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
1 deletion
+3
-1
informer.go
.../src/k8s.io/client-go/dynamic/dynamicinformer/informer.go
+3
-1
No files found.
staging/src/k8s.io/client-go/dynamic/dynamicinformer/informer.go
View file @
94b0bd89
...
...
@@ -45,6 +45,7 @@ func NewFilteredDynamicSharedInformerFactory(client dynamic.Interface, defaultRe
namespace
:
metav1
.
NamespaceAll
,
informers
:
map
[
schema
.
GroupVersionResource
]
informers
.
GenericInformer
{},
startedInformers
:
make
(
map
[
schema
.
GroupVersionResource
]
bool
),
tweakListOptions
:
tweakListOptions
,
}
}
...
...
@@ -58,6 +59,7 @@ type dynamicSharedInformerFactory struct {
// startedInformers is used for tracking which informers have been started.
// This allows Start() to be called multiple times safely.
startedInformers
map
[
schema
.
GroupVersionResource
]
bool
tweakListOptions
TweakListOptionsFunc
}
var
_
DynamicSharedInformerFactory
=
&
dynamicSharedInformerFactory
{}
...
...
@@ -72,7 +74,7 @@ func (f *dynamicSharedInformerFactory) ForResource(gvr schema.GroupVersionResour
return
informer
}
informer
=
NewFilteredDynamicInformer
(
f
.
client
,
gvr
,
f
.
namespace
,
f
.
defaultResync
,
cache
.
Indexers
{
cache
.
NamespaceIndex
:
cache
.
MetaNamespaceIndexFunc
},
nil
)
informer
=
NewFilteredDynamicInformer
(
f
.
client
,
gvr
,
f
.
namespace
,
f
.
defaultResync
,
cache
.
Indexers
{
cache
.
NamespaceIndex
:
cache
.
MetaNamespaceIndexFunc
},
f
.
tweakListOptions
)
f
.
informers
[
key
]
=
informer
return
informer
...
...
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