Skip to content

Commit 3c822a8

Browse files
committed
refactor: reorder struct fields in HdfsClusterConfig.
1 parent 5c309a2 commit 3c822a8

1 file changed

Lines changed: 16 additions & 16 deletions

File tree

  • rust/operator-binary/src/crd

rust/operator-binary/src/crd/mod.rs

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -200,12 +200,28 @@ pub mod versioned {
200200
#[derive(Clone, Debug, Deserialize, Eq, JsonSchema, PartialEq, Serialize)]
201201
#[serde(rename_all = "camelCase")]
202202
pub struct HdfsClusterConfig {
203+
/// Settings related to user [authentication](DOCS_BASE_URL_PLACEHOLDER/usage-guide/security).
204+
pub authentication: Option<AuthenticationConfig>,
205+
206+
/// Authorization options for HDFS.
207+
/// Learn more in the [HDFS authorization usage guide](DOCS_BASE_URL_PLACEHOLDER/hdfs/usage-guide/security#authorization).
208+
#[serde(skip_serializing_if = "Option::is_none")]
209+
pub authorization: Option<AuthorizationConfig>,
210+
203211
/// `dfsReplication` is the factor of how many times a file will be replicated to different data nodes.
204212
/// The default is 3.
205213
/// You need at least the same amount of data nodes so each file can be replicated correctly, otherwise a warning will be printed.
206214
#[serde(default = "default_dfs_replication_factor")]
207215
pub dfs_replication: u8,
208216

217+
// Scheduled for removal in v1alpha2, see https://github.com/stackabletech/issues/issues/504
218+
/// Deprecated, please use `.spec.nameNodes.config.listenerClass` and `.spec.dataNodes.config.listenerClass` instead.
219+
#[serde(default)]
220+
pub listener_class: DeprecatedClusterListenerClass,
221+
222+
/// Configuration to control HDFS topology (rack) awareness feature
223+
pub rack_awareness: Option<Vec<TopologyLabel>>,
224+
209225
/// Name of the Vector aggregator [discovery ConfigMap](DOCS_BASE_URL_PLACEHOLDER/concepts/service_discovery).
210226
/// It must contain the key `ADDRESS` with the address of the Vector aggregator.
211227
/// Follow the [logging tutorial](DOCS_BASE_URL_PLACEHOLDER/tutorials/logging-vector-aggregator)
@@ -216,22 +232,6 @@ pub mod versioned {
216232
/// Name of the [discovery ConfigMap](DOCS_BASE_URL_PLACEHOLDER/concepts/service_discovery)
217233
/// for a ZooKeeper cluster.
218234
pub zookeeper_config_map_name: String,
219-
220-
/// Settings related to user [authentication](DOCS_BASE_URL_PLACEHOLDER/usage-guide/security).
221-
pub authentication: Option<AuthenticationConfig>,
222-
223-
/// Authorization options for HDFS.
224-
/// Learn more in the [HDFS authorization usage guide](DOCS_BASE_URL_PLACEHOLDER/hdfs/usage-guide/security#authorization).
225-
#[serde(skip_serializing_if = "Option::is_none")]
226-
pub authorization: Option<AuthorizationConfig>,
227-
228-
// Scheduled for removal in v1alpha2, see https://github.com/stackabletech/issues/issues/504
229-
/// Deprecated, please use `.spec.nameNodes.config.listenerClass` and `.spec.dataNodes.config.listenerClass` instead.
230-
#[serde(default)]
231-
pub listener_class: DeprecatedClusterListenerClass,
232-
233-
/// Configuration to control HDFS topology (rack) awareness feature
234-
pub rack_awareness: Option<Vec<TopologyLabel>>,
235235
}
236236

237237
#[derive(Clone, Debug, Default, Deserialize, Eq, JsonSchema, Merge, PartialEq, Serialize)]

0 commit comments

Comments
 (0)