Skip to main content

Migrating Apache Impala

If you are running Apache Impala and are looking to migrate it to Amazon EMR, we recommend that you use Amazon Athena or Trino (formerly PrestoSQL).

AWS now recommends Trino over PrestoDB for new deployments. Trino is the open-source successor to PrestoSQL and is actively maintained by the community and will receive new features and performant updates. Amazon Athena engine version 3 is built on Trino, providing the same performance foundation with a fully managed, serverless experience.

See the "Considerations for Presto" section earlier in this guide for detailed guidance on choosing between Amazon Athena and Trino/PrestoDB on Amazon EMR.

If You Must Use Impala

If you must use Impala due to a use case that is not covered by Trino or Athena, you have three options to install Impala:

  1. Manually install Impala on Amazon EC2 instances and manage the infrastructure yourself.

  2. Use a bootstrap action to install Impala on Amazon EMR clusters during cluster launch.

  3. Use a third-party cloud provider that installs and manages Impala as a managed service.

Important Support Limitation

Because Impala is not a managed application on Amazon EMR, AWS Support and Amazon EMR service teams are not able to support an Impala installation. You will be responsible for troubleshooting, maintenance, upgrades, and operational support if you choose to run Impala on AWS infrastructure.

SQL Compatibility Considerations

Most Impala SQL queries are compatible with Trino and Athena with minimal modifications. Both Trino and Athena support ANSI SQL syntax, which Impala also follows. Key differences to be aware of during migration include:

Impala SQL FeatureTrino/Athena EquivalentNotes
INVALIDATE METADATAAutomatic (Glue)Not required, Athena/Trino see Glue Catalog changes instantly.
REFRESH [table]MSCK REPAIR TABLEUse only to register new partitions added directly to S3
COMPUTE STATSANALYZEEssential for Trino’s Cost-Based Optimizer to handle large joins
UPSERTMERGERequires Apache Iceberg or Delta Lake table formats on S3
C++ UDFs (User Defined Functions)Lambda/Java UDFs (Athena) or custom Trino UDFsRequires rewriting in Java/Python
Impala-specific data typesARRAY, MAP, ROWStandardized in Trino; highly compatible with Impala’s nested types; Minor type mapping required

For detailed SQL migration guidance, see:

Migration Decision Framework

Use the following framework to determine the best path forward:

Your RequirementRecommended SolutionRationale
Serverless, fully managed SQL queries with minimal operational overheadAmazon AthenaNo infrastructure management, pay-per-query pricing, automatic scaling
Need custom configurations, fine-tuned performance, or features not in AthenaTrino on Amazon EMRFull control over cluster configuration, custom connectors, dedicated resources
Require Impala-specific features with no Trino/Athena equivalentSelf-managed Impala on EC2Full compatibility but highest operational burden
Legacy applications with deep Impala dependenciesThird-party managed Impala serviceReduces operational burden while maintaining compatibility

Documentation References: