class_docstr: This handler handles connection and execution of the Impala statements.
class_docstr_tok: ["This","handler","handles","connection","and","execution","of","the","Impala","statements","."]
code: def connect(self):
      if self.is_connected is True:
          return self.connection
  
      config = {
          "host": self.connection_data.get("host"),
          "port": self.connection_data.get("port", 21050),
          "user": self.connection_data.get("user"),
          "password": self.connection_data.get("password"),
          "database": self.connection_data.get("database"),
      }
  
      connection = db.connect(**config)
      self.is_connected = True
      self.connection = connection
      return self.connection
  
imports: from collections import OrderedDict
  from typing import Optional
  import pandas
  from impala import dbapi, sqlalchemy
  from mindsdb_sql import parse_sql
  from mindsdb_sql.render.sqlalchemy_render import SqlalchemyRender
  from mindsdb_sql.parser.ast.base import ASTNode
  from mindsdb.utilities import log
  from mindsdb.integrations.libs.base import DatabaseHandler
  from mindsdb.integrations.libs.response import HandlerStatusResponse, HandlerResponse, RESPONSE_TYPE
  from mindsdb.integrations.libs.const import HANDLER_CONNECTION_ARG_TYPE
label_desc: Use image node_id 2 for calling the ImpalaHandler obj's underlying member method code with example usage: obj.connect() and returns: self, self