t8y2/dbx · error

TDengine connection timed out after {} seconds

Error message

TDengine connection timed out after {} seconds

What it means

Bailed by TdengineDriver.connect when establishing the WebSocket connection (including any handshake/login) did not complete within the configured connect timeout seconds. The DSN was built and the connector configured, but the server did not answer in time — network latency, unreachable host, or an overloaded taosAdapter.

Source

Thrown at agents/drivers/tdengine/src/driver.rs:79

            connection: None,
            params: ConnectParams::default(),
            server_version: None,
            session_timezone: None,
            current_database: String::new(),
            query_sessions: HashMap::new(),
            table_cache: None,
        }
    }

    pub async fn connect(&mut self, params: ConnectParams) -> Result<()> {
        self.disconnect().await;
        let dsn = build_dsn(&params)?;
        let builder =
            TaosBuilder::from_dsn(&dsn.value).with_context(|| "failed to configure TDengine WebSocket connector")?;
        let connect_timeout = connect_timeout(&params);
        let connection = timeout(connect_timeout, builder.build())
            .await
            .map_err(|_| anyhow!("TDengine connection timed out after {} seconds", connect_timeout.as_secs()))??;
        let token = CancellationToken::new();
        let server_version = query_scalar_string(&connection, "SELECT server_version()", &token, 5).await.ok();
        let session_timezone = query_scalar_string(&connection, "SELECT timezone()", &token, 5)
            .await
            .ok()
            .and_then(|value| parse_server_timezone(&value));
        self.current_database = dsn.database;
        self.server_version = server_version;
        self.session_timezone = session_timezone;
        self.params = params;
        self.connection = Some(connection);
        Ok(())
    }

    pub async fn test_connection(params: ConnectParams) -> Result<DatabaseConnectionInfo> {
        let mut driver = Self::new();
        driver.connect(params).await?;
        let token = CancellationToken::new();

View on GitHub (pinned to c0390bff16)

Solutions

  1. Verify the TDengine host/port (taosAdapter WebSocket port, typically 6041) is reachable
  2. Increase the connect timeout in connection parameters
  3. Check taosAdapter health and load; restart it if wedged
  4. Rule out firewall/proxy idle or SYN drops between agent and server
Defensive patterns

Strategy: retry

When it happens

Trigger: Thrown at agents/drivers/tdengine/src/driver.rs:79 when the library encounters an invalid state.

Common situations: See trigger scenarios.

Understand the failure class


AI-assisted analysis of t8y2/dbx@c0390bff16 (2026-09-05). Data as JSON: /api/errors/30c36142ecd8b678. Report an issue: GitHub.