diff --git a/src/cmd_all/src/common.rs b/src/cmd_all/src/common.rs index c7df4e5821360..c0e5c10dde5a7 100644 --- a/src/cmd_all/src/common.rs +++ b/src/cmd_all/src/common.rs @@ -24,7 +24,6 @@ pub enum RisingWaveService { Frontend(Vec), #[allow(dead_code)] Compactor(Vec), - ConnectorNode(Vec), } impl RisingWaveService { @@ -34,10 +33,7 @@ impl RisingWaveService { RisingWaveService::Compute(args0) | RisingWaveService::Meta(args0) | RisingWaveService::Frontend(args0) - | RisingWaveService::Compactor(args0) - | RisingWaveService::ConnectorNode(args0) => { - args0.extend(args.iter().map(|s| s.into())) - } + | RisingWaveService::Compactor(args0) => args0.extend(args.iter().map(|s| s.into())), } } } diff --git a/src/cmd_all/src/playground.rs b/src/cmd_all/src/playground.rs index 76ca89be17c76..bb3f3d8726680 100644 --- a/src/cmd_all/src/playground.rs +++ b/src/cmd_all/src/playground.rs @@ -21,8 +21,6 @@ use std::sync::LazyLock; use anyhow::Result; use clap::Parser; use tempfile::TempPath; -use tokio::io::{AsyncBufReadExt, BufReader}; -use tokio::process::Command; use tokio::signal; use crate::common::{osstrs as common_osstrs, RisingWaveService}; @@ -62,7 +60,6 @@ fn get_services(profile: &str) -> (Vec, bool) { ])), RisingWaveService::Compute(osstrs([])), RisingWaveService::Frontend(osstrs([])), - RisingWaveService::ConnectorNode(osstrs([])), ], "playground-3cn" => vec![ RisingWaveService::Meta(osstrs([ @@ -120,7 +117,6 @@ fn get_services(profile: &str) -> (Vec, bool) { "--advertise-addr", "127.0.0.1:4566", ])), - RisingWaveService::ConnectorNode(osstrs([])), ], _ => { tracing::warn!("Unknown playground profile. All components will be started using the default command line options."); @@ -196,44 +192,6 @@ pub async fn playground(opts: PlaygroundOpts) -> Result<()> { let _compactor_handle = tokio::spawn(async move { risingwave_compactor::start(opts).await }); } - // connector node only supports in docker-playground profile - RisingWaveService::ConnectorNode(_) => { - let prefix_bin = match profile.as_str() { - "docker-playground" | "online-docker-playground" => { - "/risingwave/bin".to_string() - } - "playground" => std::env::var("PREFIX_BIN").unwrap_or_default(), - _ => "".to_string(), - }; - let cmd_path = Path::new(&prefix_bin) - .join("connector-node") - .join("start-service.sh"); - if cmd_path.exists() { - tracing::info!("start connector-node with prefix_bin {}", prefix_bin); - let mut child = Command::new(cmd_path) - .arg("-p") - .arg("50051") - .stderr(std::process::Stdio::piped()) - .spawn()?; - let stderr = child.stderr.take().unwrap(); - - let _child_handle = tokio::spawn(async move { - signal::ctrl_c().await.unwrap(); - let _ = child.start_kill(); - }); - let _stderr_handle = tokio::spawn(async move { - let mut reader = BufReader::new(stderr).lines(); - while let Ok(Some(line)) = reader.next_line().await { - tracing::info!(target: "risingwave_connector_node", "{}", line); - } - }); - } else { - tracing::warn!( - "Will not start connector node since `{}` does not exist.", - cmd_path.display() - ); - } - } } }