Skip to content

Commit 2a82082

Browse files
Merge pull request #733 from swimos/rust-1.82
Upgrade to Rust 1.82
2 parents 3ac0c70 + 803e2e1 commit 2a82082

File tree

6 files changed

+30
-29
lines changed

6 files changed

+30
-29
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ on:
55

66
name: Continuous integration
77
env:
8-
latest_version: "1.81.0"
8+
latest_version: "1.82.0"
99

1010
jobs:
1111
test:

example_apps/console/src/model/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,7 @@ pub enum AppCommand {
160160
Quit,
161161
Clear,
162162
Help { command_name: Option<String> },
163-
Controller(ControllerCommand),
163+
Controller(Box<ControllerCommand>),
164164
}
165165

166166
#[derive(Debug)]

example_apps/console/src/model/parse/mod.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -103,9 +103,9 @@ pub fn parse_app_command(command: &str) -> Result<AppCommand, Cow<'static, str>>
103103
}),
104104
["quit"] => Ok(AppCommand::Quit),
105105
["clear"] => Ok(AppCommand::Clear),
106-
_ => Ok(AppCommand::Controller(parse_controller_command(
106+
_ => Ok(AppCommand::Controller(Box::new(parse_controller_command(
107107
command_parts.as_slice(),
108-
)?)),
108+
)?))),
109109
}
110110
}
111111

example_apps/console/src/model/parse/tests.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ fn mixed_tokens3() {
105105

106106
fn to_controller(cmd: AppCommand) -> ControllerCommand {
107107
if let AppCommand::Controller(c) = cmd {
108-
c
108+
*c
109109
} else {
110110
panic!("Unexpected command kind.");
111111
}

example_apps/console/src/ui/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -434,7 +434,7 @@ fn on_command(
434434
Ok(AppCommand::Clear) => None,
435435
Ok(AppCommand::Controller(command)) => Some(
436436
controller
437-
.perform_action(command)
437+
.perform_action(*command)
438438
.into_iter()
439439
.map(|msg| format!("{}\n", msg))
440440
.map(Cow::Owned)

server/swimos_connector_fluvio/src/ingress/mod.rs

Lines changed: 24 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ where
112112
let relays = relays.clone();
113113

114114
Ok(unfold(
115-
ConnectorState::Uninit(configuration.clone(), factory.clone()),
115+
ConnectorState::Uninit(Box::new(configuration.clone()), factory.clone()),
116116
move |state: ConnectorState<F::Client, F>| {
117117
let topic = topic.clone();
118118
let key_deser = key_deser.clone();
@@ -122,28 +122,29 @@ where
122122

123123
let fut = async move {
124124
match state {
125-
ConnectorState::Uninit(config, factory) => match factory.open(config).await
126-
{
127-
Ok(consumer) => {
128-
let (key, value) =
129-
match load_deserializers(key_deser, value_deser).await {
130-
Ok((key, value)) => (key, value),
131-
Err(e) => {
132-
return Some((
133-
Err(FluvioConnectorError::Configuration(e)),
134-
ConnectorState::Failed,
135-
))
136-
}
137-
};
138-
poll_dispatch(
139-
consumer,
140-
topic,
141-
MessageSelector::new(key, value, lanes, relays),
142-
)
143-
.await
125+
ConnectorState::Uninit(config, factory) => {
126+
match factory.open(*config).await {
127+
Ok(consumer) => {
128+
let (key, value) =
129+
match load_deserializers(key_deser, value_deser).await {
130+
Ok((key, value)) => (key, value),
131+
Err(e) => {
132+
return Some((
133+
Err(FluvioConnectorError::Configuration(e)),
134+
ConnectorState::Failed,
135+
))
136+
}
137+
};
138+
poll_dispatch(
139+
consumer,
140+
topic,
141+
MessageSelector::new(key, value, lanes, relays),
142+
)
143+
.await
144+
}
145+
Err(e) => Some((Err(e), ConnectorState::Failed)),
144146
}
145-
Err(e) => Some((Err(e), ConnectorState::Failed)),
146-
},
147+
}
147148
ConnectorState::Running {
148149
topic,
149150
consumer,
@@ -185,7 +186,7 @@ where
185186
}
186187

187188
enum ConnectorState<C, F> {
188-
Uninit(FluvioIngressConfiguration, F),
189+
Uninit(Box<FluvioIngressConfiguration>, F),
189190
Running {
190191
topic: String,
191192
consumer: C,

0 commit comments

Comments
 (0)