diff --git a/src/common/error/src/format.rs b/src/common/error/src/format.rs index 4113621cb0..87d8171ce0 100644 --- a/src/common/error/src/format.rs +++ b/src/common/error/src/format.rs @@ -34,7 +34,7 @@ impl<'a, E: ErrorExt + ?Sized> fmt::Debug for DebugFormat<'a, E> { write!(f, " Caused by: {:?}", source)?; } if let Some(backtrace) = self.0.backtrace_opt() { - // Add a newline to seperate causes and backtrace. + // Add a newline to separate causes and backtrace. write!(f, "\nBacktrace:\n{}", backtrace)?; } diff --git a/src/servers/src/prometheus.rs b/src/servers/src/prometheus.rs index 7e18b1d29a..48045b066e 100644 --- a/src/servers/src/prometheus.rs +++ b/src/servers/src/prometheus.rs @@ -12,7 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. -//! promethues protcol supportings +//! prometheus protocol supportings use std::cmp::Ordering; use std::collections::{BTreeMap, HashMap}; use std::hash::{Hash, Hasher}; @@ -77,7 +77,7 @@ pub fn query_to_sql(db: &str, q: &Query) -> Result<(String, String)> { let value = &m.value; let m_type = MatcherType::from_i32(m.r#type).context(error::InvalidPromRemoteRequestSnafu { - msg: format!("invaid LabelMatcher type: {}", m.r#type), + msg: format!("invalid LabelMatcher type: {}", m.r#type), })?; match m_type { @@ -87,11 +87,11 @@ pub fn query_to_sql(db: &str, q: &Query) -> Result<(String, String)> { MatcherType::Neq => { conditions.push(format!("{}!='{}'", name, value)); } - // Case senstive regexp match + // Case sensitive regexp match MatcherType::Re => { conditions.push(format!("{}~'{}'", name, value)); } - // Case senstive regexp not match + // Case sensitive regexp not match MatcherType::Nre => { conditions.push(format!("{}!~'{}'", name, value)); } diff --git a/src/sql/src/parser.rs b/src/sql/src/parser.rs index 796f9816af..a9103de5c4 100644 --- a/src/sql/src/parser.rs +++ b/src/sql/src/parser.rs @@ -158,7 +158,7 @@ impl<'a> ParserContext<'a> { })); } - // SHOW TABLES [in | FROM] [DATABSE] + // SHOW TABLES [in | FROM] [DATABASE] Token::Word(w) => match w.keyword { Keyword::IN | Keyword::FROM => { self.parser.next_token();