From c15f2d502cc796162c4a9dbe0eca01f5d3af50d7 Mon Sep 17 00:00:00 2001 From: Alexey Shekhirin Date: Tue, 12 Mar 2024 21:01:00 +0000 Subject: [PATCH] chore(primitives): remove static file stage (#7116) --- crates/primitives/src/stage/id.rs | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/crates/primitives/src/stage/id.rs b/crates/primitives/src/stage/id.rs index df92bd112c..bfd6e20fee 100644 --- a/crates/primitives/src/stage/id.rs +++ b/crates/primitives/src/stage/id.rs @@ -4,6 +4,9 @@ #[derive(Clone, Copy, Debug, PartialEq, Eq, Hash)] pub enum StageId { /// Static File stage in the process. + #[deprecated( + note = "Static Files are generated outside of the pipeline and do not require a separate stage" + )] StaticFile, /// Header stage in the process. Headers, @@ -35,8 +38,7 @@ pub enum StageId { impl StageId { /// All supported Stages - pub const ALL: [StageId; 13] = [ - StageId::StaticFile, + pub const ALL: [StageId; 12] = [ StageId::Headers, StageId::Bodies, StageId::SenderRecovery, @@ -54,6 +56,7 @@ impl StageId { /// Return stage id formatted as string. pub fn as_str(&self) -> &str { match self { + #[allow(deprecated)] StageId::StaticFile => "StaticFile", StageId::Headers => "Headers", StageId::Bodies => "Bodies", @@ -94,7 +97,6 @@ mod tests { #[test] fn stage_id_as_string() { - assert_eq!(StageId::StaticFile.to_string(), "StaticFile"); assert_eq!(StageId::Headers.to_string(), "Headers"); assert_eq!(StageId::Bodies.to_string(), "Bodies"); assert_eq!(StageId::SenderRecovery.to_string(), "SenderRecovery");