@@ -6,8 +6,8 @@ use crate::fluent_controller::fluentbit_config::exec::resource::*;
6
6
use crate :: fluent_controller:: fluentbit_config:: model:: reconciler as model_reconciler;
7
7
use crate :: fluent_controller:: fluentbit_config:: model:: resource as model_resource;
8
8
use crate :: fluent_controller:: fluentbit_config:: trusted:: { exec_types:: * , spec_types, step:: * } ;
9
- use crate :: kubernetes_api_objects:: exec:: resource:: ResourceWrapper ;
10
9
use crate :: kubernetes_api_objects:: exec:: prelude:: * ;
10
+ use crate :: kubernetes_api_objects:: exec:: resource:: ResourceWrapper ;
11
11
use crate :: reconciler:: exec:: { io:: * , reconciler:: * , resource_builder:: * } ;
12
12
use crate :: reconciler:: spec:: resource_builder:: ResourceBuilder as SpecResourceBuilder ;
13
13
use crate :: vstd_ext:: { string_map:: StringMap , string_view:: * } ;
@@ -20,14 +20,22 @@ pub struct FluentBitConfigReconciler {}
20
20
impl Reconciler <FluentBitConfig , FluentBitConfigReconcileState , EmptyType , EmptyType , EmptyAPIShimLayer > for FluentBitConfigReconciler {
21
21
open spec fn well_formed( fbc: & FluentBitConfig ) -> bool { fbc@. well_formed( ) }
22
22
23
- fn reconcile_init_state( ) -> FluentBitConfigReconcileState { reconcile_init_state( ) }
23
+ fn reconcile_init_state( ) -> FluentBitConfigReconcileState {
24
+ reconcile_init_state( )
25
+ }
24
26
25
- fn reconcile_core( fbc: & FluentBitConfig , resp_o: Option <Response <EmptyType >>, state: FluentBitConfigReconcileState )
26
- -> ( FluentBitConfigReconcileState , Option <Request <EmptyType >>) { reconcile_core( fbc, resp_o, state) }
27
+ fn reconcile_core( fbc: & FluentBitConfig , resp_o: Option <Response <EmptyType >>, state: FluentBitConfigReconcileState )
28
+ -> ( FluentBitConfigReconcileState , Option <Request <EmptyType >>) {
29
+ reconcile_core( fbc, resp_o, state)
30
+ }
27
31
28
- fn reconcile_done( state: & FluentBitConfigReconcileState ) -> bool { reconcile_done( state) }
32
+ fn reconcile_done( state: & FluentBitConfigReconcileState ) -> bool {
33
+ reconcile_done( state)
34
+ }
29
35
30
- fn reconcile_error( state: & FluentBitConfigReconcileState ) -> bool { reconcile_error( state) }
36
+ fn reconcile_error( state: & FluentBitConfigReconcileState ) -> bool {
37
+ reconcile_error( state)
38
+ }
31
39
}
32
40
33
41
impl Default for FluentBitConfigReconciler {
@@ -157,7 +165,11 @@ pub fn reconcile_helper<
157
165
let next_state = Builder :: state_after_create( fbc, resp_o. unwrap( ) . into_k_response( ) . into_create_response( ) . res. unwrap( ) , state. clone( ) ) ;
158
166
if next_state. is_ok( ) {
159
167
let ( state_prime, req) = next_state. unwrap( ) ;
160
- let req_o = if req. is_some( ) { Some ( Request :: KRequest ( req. unwrap( ) ) ) } else { None } ;
168
+ let req_o = if req. is_some( ) {
169
+ Some ( Request :: KRequest ( req. unwrap( ) ) )
170
+ } else {
171
+ None
172
+ } ;
161
173
return ( state_prime, req_o) ;
162
174
}
163
175
}
@@ -175,7 +187,11 @@ pub fn reconcile_helper<
175
187
let next_state = Builder :: state_after_update( fbc, resp_o. unwrap( ) . into_k_response( ) . into_update_response( ) . res. unwrap( ) , state. clone( ) ) ;
176
188
if next_state. is_ok( ) {
177
189
let ( state_prime, req) = next_state. unwrap( ) ;
178
- let req_o = if req. is_some( ) { Some ( Request :: KRequest ( req. unwrap( ) ) ) } else { None } ;
190
+ let req_o = if req. is_some( ) {
191
+ Some ( Request :: KRequest ( req. unwrap( ) ) )
192
+ } else {
193
+ None
194
+ } ;
179
195
return ( state_prime, req_o) ;
180
196
}
181
197
}
0 commit comments