Skip to content

Commit

Permalink
Fixed build errors
Browse files Browse the repository at this point in the history
  • Loading branch information
nightkr committed Feb 26, 2020
1 parent 54f06cd commit 127da76
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 8 deletions.
2 changes: 1 addition & 1 deletion examples/event_informer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ async fn main() -> anyhow::Result<()> {
let client = APIClient::new(config);

let events = Api::v1Event(client);
let ei = Informer::new(events).init().await?;
let ei = Informer::new(events);

loop {
let mut events = ei.poll().await?.boxed();
Expand Down
4 changes: 1 addition & 3 deletions examples/node_informer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,8 @@ async fn main() -> anyhow::Result<()> {

let nodes = RawApi::v1Node();
let events = Api::v1Event(client.clone());
let ni = Informer::raw(client.clone(), nodes)
let ni = Informer::raw(client.clone(), nodes);
//.labels("beta.kubernetes.io/os=linux")
.init()
.await?;

loop {
let mut nodes = ni.poll().await?.boxed();
Expand Down
2 changes: 1 addition & 1 deletion examples/pod_informer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ async fn main() -> anyhow::Result<()> {
let namespace = env::var("NAMESPACE").unwrap_or("default".into());

let resource = Api::v1Pod(client.clone()).within(&namespace);
let inf = Informer::new(resource.clone()).init().await?;
let inf = Informer::new(resource.clone());

loop {
let mut pods = inf.poll().await?.boxed();
Expand Down
6 changes: 3 additions & 3 deletions src/runtime/informer.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
use crate::{
api::{
resource::{KubeObject, ObjectList, WatchEvent},
Api, ListParams, NotUsed, RawApi,
resource::{KubeObject, WatchEvent},
Api, ListParams, RawApi,
},
client::APIClient,
Result,
Expand Down Expand Up @@ -142,7 +142,7 @@ where
Delay::new(dur).await;
// If we are outside history, start over from latest
if *needs_resync {
self.reset().await?;
self.reset().await;
}
*needs_resync = false;
*needs_retry = false;
Expand Down

0 comments on commit 127da76

Please sign in to comment.