{"record":{"id":"647d484cbf972d24","repo":"apache/flink","slug":"interrupted-647d48","errorCode":null,"errorMessage":"Interrupted","messagePattern":"Interrupted","errorType":"exception","errorClass":"IOException","httpStatus":null,"severity":"error","filePath":"flink-formats/flink-parquet/src/main/java/org/apache/flink/formats/parquet/ParquetVectorizedInputFormat.java","lineNumber":475,"sourceCode":"                if (metaData.getRowCount() > rowCount) {\n                    break;\n                } else {\n                    reader.skipNextRowGroup();\n                    rowsReturned += metaData.getRowCount();\n                    totalCountLoadedSoFar += metaData.getRowCount();\n                    rowCount -= metaData.getRowCount();\n                }\n            }\n\n            this.recordsToSkip = rowCount;\n        }\n\n        private ParquetReaderBatch<T> getCachedEntry() throws IOException {\n            try {\n                return pool.pollEntry();\n            } catch (InterruptedException e) {\n                Thread.currentThread().interrupt();\n                throw new IOException(\"Interrupted\");\n            }\n        }\n\n        private void skipRecord(RecordIterator<T> records) {\n            while (recordsToSkip > 0 && records.next() != null) {\n                recordsToSkip--;\n            }\n        }\n\n        @Override\n        public void close() throws IOException {\n            if (reader != null) {\n                reader.close();\n                reader = null;\n            }\n        }\n    }\n","sourceCodeStart":457,"sourceCodeEnd":493,"githubUrl":"https://github.com/apache/flink/blob/2f3c205e9266cb30240eb7f4fdab15cad629a70f/flink-formats/flink-parquet/src/main/java/org/apache/flink/formats/parquet/ParquetVectorizedInputFormat.java#L457-L493","documentation":"While getting a recycled reader batch from the pool, the calling thread was interrupted. The code restores the interrupt flag and wraps the InterruptedException in an IOException with the message 'Interrupted'. This surfaces during job cancellation or thread interruption while the reader waits for a pooled ParquetReaderBatch.","triggerScenarios":"getCachedEntry() -> pool.pollEntry() blocking on an ObjectPool of ParquetReaderBatch objects when the TaskManager thread is interrupted (job cancellation, timeout-driven cancellation, or custom thread management).","commonSituations":"Cancelling a Flink job while the parquet reader is blocked waiting for a free batch, or shutting down an embedded/mini-cluster that interrupts reader threads mid-read.","solutions":["Treat this as a cancellation signal: stop reading and let the operator shut down cleanly","Check Thread.currentThread().isInterrupted() / cancellation flag in your read loop and exit instead of continuing","If it happens outside cancellation, look for code calling Thread.interrupt() on task threads and fix that"],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":"try { batch = reader.getCachedEntry(); } catch (IOException e) { if (Thread.currentThread().isInterrupted()) { /* cancellation: stop cleanly */ return; } throw e; }","preventionTips":["Check the operator cancellation flag in read loops and exit promptly","Do not interrupt TaskManager task threads from user code","Treat 'Interrupted' IOException as a shutdown signal, not a data error"],"tags":["parquet","interruption","cancellation","concurrency"],"backgroundTag":null,"analyzedSha":"2f3c205e9266cb30240eb7f4fdab15cad629a70f","analyzedAt":"2026-08-14T08:48:24.518Z","schemaVersion":2},"datasetVersion":"2026-08-14T10:17:34.591Z"}