Simplify a little bit the ExcelLoader code#2103
Merged
norberttech merged 3 commits intoflow-php:1.xfrom Dec 26, 2025
Merged
Conversation
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## 1.x #2103 +/- ##
==========================================
+ Coverage 82.71% 82.95% +0.24%
==========================================
Files 1171 1171
Lines 41400 41376 -24
==========================================
+ Hits 34243 34323 +80
+ Misses 7157 7053 -104
🚀 New features to boost your workflow:
|
Contributor
Flow PHP - BenchmarksResults of the benchmarks from this PR are compared with the results from 1.x branch. Extractors+--------------------------+--------------------------------+------+-----+-----------------+--------------------+-----------------+
| benchmark | subject | revs | its | mem_peak | mode | rstdev |
+--------------------------+--------------------------------+------+-----+-----------------+--------------------+-----------------+
| CSVExtractorBench | bench_extract_10k | 1 | 1 | 5.799mb -0.02% | 609.355ms +104.13% | ±0.00% -100.00% |
| DbalExtractorBench | bench_extract_10k_keyset | 1 | 1 | 35.120mb +0.03% | 510.493ms +142.77% | ±0.00% -100.00% |
| DbalExtractorBench | bench_extract_10k_limit_offset | 1 | 1 | 35.123mb -0.04% | 568.094ms +226.81% | ±0.00% -100.00% |
| ExcelExtractorBench | bench_extract_10k_ods | 1 | 1 | 48.751mb -0.00% | 2.163s +133.11% | ±0.00% -100.00% |
| ExcelExtractorBench | bench_extract_10k_xlsx | 1 | 1 | 49.614mb -0.00% | 2.882s +83.13% | ±0.00% -100.00% |
| JsonExtractorBench | bench_extract_10k | 1 | 1 | 6.524mb -0.02% | 2.061s +88.57% | ±0.00% -100.00% |
| ParquetExtractorBench | bench_extract_10k | 1 | 1 | 11.777mb -0.17% | 15.957s +35.37% | ±0.00% -100.00% |
| PostgreSqlExtractorBench | bench_extract_10k_cursor | 1 | 1 | 37.605mb -0.03% | 256.707ms +14.77% | ±0.00% -100.00% |
| PostgreSqlExtractorBench | bench_extract_10k_keyset | 1 | 1 | 37.613mb -0.06% | 435.356ms +5.36% | ±0.00% -100.00% |
| PostgreSqlExtractorBench | bench_extract_10k_limit_offset | 1 | 1 | 37.600mb +0.03% | 368.978ms +0.08% | ±0.00% -100.00% |
| TextExtractorBench | bench_extract_10k | 1 | 1 | 5.798mb -0.02% | 54.695ms -0.56% | ±0.00% -100.00% |
| XmlExtractorBench | bench_extract_10k | 1 | 1 | 5.818mb -0.02% | 667.394ms +1.99% | ±0.00% -100.00% |
+--------------------------+--------------------------------+------+-----+-----------------+--------------------+-----------------+
Transformers+---------------------------------+--------------------------+------+-----+------------------+--------------------+-----------------+
| benchmark | subject | revs | its | mem_peak | mode | rstdev |
+---------------------------------+--------------------------+------+-----+------------------+--------------------+-----------------+
| RenameEntryTransformerBench | bench_transform_10k_rows | 1 | 1 | 124.670mb -0.00% | 161.778ms +130.17% | ±0.00% -100.00% |
| RenameEachEntryTransformerBench | bench_transform_10k_rows | 1 | 1 | 19.864mb -0.01% | 137.953ms +91.32% | ±0.00% -100.00% |
+---------------------------------+--------------------------+------+-----+------------------+--------------------+-----------------+
Loaders+-----------------------+---------------------+------+-----+------------------+-------------------+-----------------+
| benchmark | subject | revs | its | mem_peak | mode | rstdev |
+-----------------------+---------------------+------+-----+------------------+-------------------+-----------------+
| CSVLoaderBench | bench_load_10k | 1 | 1 | 47.953mb -0.00% | 116.680ms +68.83% | ±0.00% -100.00% |
| DbalLoaderBench | bench_load_10k | 1 | 1 | 35.098mb -0.02% | 2.502s +125.96% | ±0.00% -100.00% |
| ExcelLoaderBench | bench_load_10k_ods | 1 | 1 | 6.736mb -0.12% | 2.921s +95.42% | ±0.00% -100.00% |
| ExcelLoaderBench | bench_load_10k_xlsx | 1 | 1 | 11.404mb -0.07% | 4.468s +92.32% | ±0.00% -100.00% |
| JsonLoaderBench | bench_load_10k | 1 | 1 | 82.785mb -0.00% | 173.227ms +67.22% | ±0.00% -100.00% |
| ParquetLoaderBench | bench_load_10k | 1 | 1 | 794.693mb +0.01% | 18.926s -26.81% | ±0.00% -100.00% |
| PostgreSqlLoaderBench | bench_load_10k | 1 | 1 | 37.599mb +0.02% | 849.134ms +1.15% | ±0.00% -100.00% |
| TextLoaderBench | bench_load_10k | 1 | 1 | 19.253mb -0.01% | 35.133ms -0.63% | ±0.00% -100.00% |
+-----------------------+---------------------+------+-----+------------------+-------------------+-----------------+
Building Blocks+-------------------+----------------------------+------+-----+------------------+--------------------+-----------------+
| benchmark | subject | revs | its | mem_peak | mode | rstdev |
+-------------------+----------------------------+------+-----+------------------+--------------------+-----------------+
| EntryFactoryBench | bench_entry_factory | 1 | 1 | 107.266mb -0.00% | 1.126s +115.48% | ±0.00% -100.00% |
| EntryFactoryBench | bench_entry_factory | 1 | 1 | 56.663mb -0.00% | 623.029ms +128.63% | ±0.00% -100.00% |
| EntryFactoryBench | bench_entry_factory | 1 | 1 | 16.345mb -0.01% | 126.612ms +109.09% | ±0.00% -100.00% |
| RowsBench | bench_chunk_10_on_10k | 2 | 1 | 95.165mb -0.00% | 6.775ms +83.21% | ±0.00% -100.00% |
| RowsBench | bench_diff_left_1k_on_10k | 2 | 1 | 112.559mb -0.00% | 531.559ms +110.86% | ±0.00% -100.00% |
| RowsBench | bench_diff_right_1k_on_10k | 2 | 1 | 95.279mb -0.00% | 83.338ms +230.10% | ±0.00% -100.00% |
| RowsBench | bench_drop_1k_on_10k | 2 | 1 | 96.040mb -0.00% | 3.181ms +107.18% | ±0.00% -100.00% |
| RowsBench | bench_drop_right_1k_on_10k | 2 | 1 | 96.040mb -0.00% | 6.303ms +304.97% | ±0.00% -100.00% |
| RowsBench | bench_entries_on_10k | 2 | 1 | 94.201mb -0.00% | 5.195ms +48.75% | ±0.00% -100.00% |
| RowsBench | bench_filter_on_10k | 2 | 1 | 94.730mb -0.00% | 32.367ms +98.74% | ±0.00% -100.00% |
| RowsBench | bench_find_on_10k | 2 | 1 | 94.730mb -0.00% | 32.335ms +95.30% | ±0.00% -100.00% |
| RowsBench | bench_find_one_on_10k | 10 | 1 | 93.418mb -0.00% | 2.600μs +52.40% | ±0.00% -100.00% |
| RowsBench | bench_first_on_10k | 10 | 1 | 93.418mb -0.00% | 0.400μs 0.00% | ±0.00% -100.00% |
| RowsBench | bench_flat_map_on_1k | 2 | 1 | 102.479mb -0.00% | 28.454ms +88.49% | ±0.00% -100.00% |
| RowsBench | bench_map_on_10k | 2 | 1 | 131.906mb -0.00% | 131.019ms +80.07% | ±0.00% -100.00% |
| RowsBench | bench_merge_1k_on_10k | 2 | 1 | 95.249mb -0.00% | 2.259ms +58.43% | ±0.00% -100.00% |
| RowsBench | bench_partition_by_on_10k | 2 | 1 | 98.641mb -0.00% | 110.239ms +77.89% | ±0.00% -100.00% |
| RowsBench | bench_remove_on_10k | 2 | 1 | 96.302mb -0.00% | 6.473ms +69.26% | ±0.00% -100.00% |
| RowsBench | bench_sort_asc_on_1k | 2 | 1 | 93.803mb -0.00% | 81.392ms +97.30% | ±0.00% -100.00% |
| RowsBench | bench_sort_by_on_1k | 2 | 1 | 93.803mb -0.00% | 81.963ms +101.06% | ±0.00% -100.00% |
| RowsBench | bench_sort_desc_on_1k | 2 | 1 | 93.803mb -0.00% | 82.896ms +94.80% | ±0.00% -100.00% |
| RowsBench | bench_sort_entries_on_1k | 2 | 1 | 95.861mb -0.00% | 16.103ms +90.10% | ±0.00% -100.00% |
| RowsBench | bench_sort_on_1k | 2 | 1 | 93.611mb -0.00% | 65.596ms +107.08% | ±0.00% -100.00% |
| RowsBench | bench_take_1k_on_10k | 10 | 1 | 93.418mb -0.00% | 26.200μs +92.19% | ±0.00% -100.00% |
| RowsBench | bench_take_right_1k_on_10k | 10 | 1 | 93.418mb -0.00% | 34.700μs +112.02% | ±0.00% -100.00% |
| RowsBench | bench_unique_on_1k | 2 | 1 | 112.560mb -0.00% | 489.297ms +97.90% | ±0.00% -100.00% |
| TypeDetectorBench | bench_type_detector | 1 | 1 | 43.526mb -0.00% | 683.689ms +104.57% | ±0.00% -100.00% |
| TypeDetectorBench | bench_type_detector | 1 | 1 | 12.584mb -0.01% | 138.163ms +103.11% | ±0.00% -100.00% |
+-------------------+----------------------------+------+-----+------------------+--------------------+-----------------+
Parquet Library+--------------------+---------------------------------+------+-----+------------------+--------------------+-----------------+
| benchmark | subject | revs | its | mem_peak | mode | rstdev |
+--------------------+---------------------------------+------+-----+------------------+--------------------+-----------------+
| ParquetWriterBench | bench_write_batch | 1 | 1 | 12.696mb -12.72% | 391.436ms +74.48% | ±0.00% -100.00% |
| ParquetWriterBench | bench_write_gzip | 1 | 1 | 11.356mb +0.01% | 469.265ms +113.82% | ±0.00% -100.00% |
| ParquetWriterBench | bench_write_row_by_row | 1 | 1 | 12.696mb -12.72% | 333.095ms +47.97% | ±0.00% -100.00% |
| ParquetWriterBench | bench_write_snappy | 1 | 1 | 12.696mb -12.72% | 344.465ms +53.27% | ±0.00% -100.00% |
| ParquetWriterBench | bench_write_uncompressed | 1 | 1 | 11.080mb +0.01% | 360.391ms +89.21% | ±0.00% -100.00% |
| ParquetReaderBench | bench_page_headers | 1 | 1 | 7.823mb -0.01% | 4.170s +121.83% | ±0.00% -100.00% |
| ParquetReaderBench | bench_read_metadata | 1 | 1 | 6.518mb -0.02% | 15.336ms +87.28% | ±0.00% -100.00% |
| ParquetReaderBench | bench_read_schema | 1 | 1 | 6.518mb -0.02% | 15.398ms +85.67% | ±0.00% -100.00% |
| ParquetReaderBench | bench_read_values_all_columns | 1 | 1 | 10.094mb -0.20% | 10.712s +38.00% | ±0.00% -100.00% |
| ParquetReaderBench | bench_read_values_single_column | 1 | 1 | 7.391mb -0.27% | 383.462ms -14.34% | ±0.00% -100.00% |
| ParquetReaderBench | bench_read_values_with_limit | 1 | 1 | 7.919mb -0.41% | 31.740ms +34.45% | ±0.00% -100.00% |
+--------------------+---------------------------------+------+-----+------------------+--------------------+-----------------+
|
norberttech
approved these changes
Dec 25, 2025
src/adapter/etl-adapter-excel/src/Flow/ETL/Adapter/Excel/RowsNormalizer/ExcelRowsNormalizer.php
Outdated
Show resolved
Hide resolved
src/adapter/etl-adapter-excel/src/Flow/ETL/Adapter/Excel/RowsNormalizer/ExcelRowsNormalizer.php
Show resolved
Hide resolved
src/adapter/etl-adapter-excel/src/Flow/ETL/Adapter/Excel/ExcelExtractor.php
Show resolved
Hide resolved
src/adapter/etl-adapter-excel/src/Flow/ETL/Adapter/Excel/WorkbookManager.php
Show resolved
Hide resolved
...ter-excel/tests/Flow/ETL/Adapter/Excel/Tests/Unit/RowsNormalizer/ExcelRowsNormalizerTest.php
Outdated
Show resolved
Hide resolved
f137078 to
f9ba95f
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Resolves: #xxx
Change Log
Added
Fixed
Changed
Removed
Deprecated
Security