{"record":{"id":"32bd388a1d8092d6","repo":"prestodb/presto","slug":"invalid-retry-execution-strategy","errorCode":"INVALID_RETRY_EXECUTION_STRATEGY","errorMessage":"Execution strategy not supported: ","messagePattern":"Execution strategy not supported: ","errorType":"error_code","errorClass":"PrestoException","httpStatus":null,"severity":"error","filePath":"presto-spark-base/src/main/java/com/facebook/presto/spark/util/PrestoSparkExecutionUtils.java","lineNumber":66,"sourceCode":"        for (ExecutionStrategy strategy : executionStrategies) {\n            log.info(String.format(\"Applying execution strategy: %s. Query Id: %s\", strategy.name(), session.getQueryId().getId()));\n            switch (strategy) {\n                case DISABLE_BROADCAST_JOIN:\n                    prestoSessionProperties.put(JOIN_DISTRIBUTION_TYPE, FeaturesConfig.JoinDistributionType.PARTITIONED.name());\n                    break;\n\n                case INCREASE_CONTAINER_SIZE:\n                    sparkConfigProperties.putAll(getOutOfMemoryRetrySparkConfigs(session));\n                    prestoSessionProperties.putAll(getOutOfMemoryRetryPrestoSessionProperties(session));\n                    break;\n\n                case INCREASE_HASH_PARTITION_COUNT:\n                    long updatedPartitionCount = Math.round(getHashPartitionCount(session) *\n                            getHashPartitionCountScalingFactorOnOutOfMemory(session));\n                    prestoSessionProperties.put(HASH_PARTITION_COUNT, Long.toString(updatedPartitionCount));\n                    break;\n                default:\n                    throw new PrestoException(INVALID_RETRY_EXECUTION_STRATEGY, \"Execution strategy not supported: \" + executionStrategies);\n            }\n        }\n\n        return new PrestoSparkExecutionSettings(sparkConfigProperties.build(), prestoSessionProperties.build());\n    }\n}\n","sourceCodeStart":48,"sourceCodeEnd":73,"githubUrl":"https://github.com/prestodb/presto/blob/55bb57d202de3b926896fa966c2c4a44c779634e/presto-spark-base/src/main/java/com/facebook/presto/spark/util/PrestoSparkExecutionUtils.java#L48-L73","documentation":"Presto on Spark builds execution settings from the session's retry execution strategy. Only ATTEMPT and (via scaling) INCREASE_HASH_PARTITION_COUNT strategies are implemented; any other configured retry-execution-strategy value falls through the switch's default arm and is rejected with this INVALID_RETRY_EXECUTION_STRATEGY PrestoException.","triggerScenarios":"Setting session property retry-execution-strategy (query max-run-time/retry config) to a value other than ATTEMPT or INCREASE_HASH_PARTITION_COUNT when running queries on Presto over Spark via getExecutionSettings.","commonSituations":"Typos or unsupported values in coordinator/session config for presto-spark; copying session property values from vanilla Presto that are not supported by the Spark execution path; upgrading Presto while reusing an old strategy value.","solutions":["Set retry-execution-strategy session/config property to ATTEMPT or INCREASE_HASH_PARTITION_COUNT","Check for typos/case in the configured strategy value","Consult the presto-spark documentation for supported retry strategies before reusing values from non-Spark deployments"],"exampleFix":"// before\nSET SESSION retry_execution_strategy = PARTIAL_RESULTS;\n// after\nSET SESSION retry_execution_strategy = ATTEMPT;","handlingStrategy":"validation","validationCode":"if (!strategy.equals(\"ATTEMPT\") && !strategy.equals(\"INCREASE_HASH_PARTITION_COUNT\")) { throw new IllegalArgumentException(\"Unsupported retry-execution-strategy: \" + strategy); }","typeGuard":null,"tryCatchPattern":"try { settings = PrestoSparkExecutionUtils.getExecutionSettings(session); } catch (PrestoException e) { if (e.getErrorCode().getCode() == ErrorType.USER_ERROR.toErrorCode().getCode()) { /* fix strategy config */ } throw e; }","preventionTips":["Only set supported values ATTEMPT or INCREASE_HASH_PARTITION_COUNT for retry-execution-strategy","Validate session properties at cluster config review time","Do not copy retry strategy values from non-Spark Presto deployments"],"tags":["presto","spark","configuration","invalid-enum"],"backgroundTag":"unsupported-execution-strategy","analyzedSha":"55bb57d202de3b926896fa966c2c4a44c779634e","analyzedAt":"2026-09-04T12:50:26.162Z","contentChangedAt":"2026-09-04T12:50:26.162Z","schemaVersion":2},"datasetVersion":"2026-09-11T21:17:09.523Z"}