[TYPO3-mvc] Extbase/FLOW3 Performance
claus at wildside.dk
Tue Feb 21 22:31:05 CET 2012
First off, thanks for opening the discussion. There's always room for improvement.
> This query was only the start to show indices are important.
They most certainly are. But as long as we still rely on TCA and ext_tables.sql, this
is the developer's responsibility.
I can say, however, that I will be thinking about optimal use of indices in the
reflection-based TCA-and-SQL-schema-generation feature I am working on for
Extbase. Hopefully this will make performance better with no effort from the dev.
So that's one way I can and will personally make that small area better.
You mention slow Fluid partials - again, this is something you can work to avoid.
Among other things you can make larger partials (each td/th in its own template is
way overkill imho). Or you could (should!) use sections. You may not be aware of
this, but Partials support using Sections and this should greatly increase your
performance if you re-use the same partial many times over. The biggest factor
here is that sections can be cached as native PHP code.
While I see your point that, yes, Extbase/Fluid should "just" allow the programmer
to be fast, it does not and probably never will excuse the programmer when he
makes really bad decisions such as single-cell Partials ;)
> $methodName = t3lib_div::lowerCamelCase($property);
> $key = $value->get$methodName;
Unless, of course, you wish to confirm with TYPO3 coding guidelines. Or haven't
properly sanitized your $property variable and made sure the property exists.
Faster isn't always better. Sometimes we have to weigh things like security and
error tolerance over speed.
Please keep in mind that I don't say this to reject the notion that Extbase can do
better. I only say this because it should always first and foremost be the
responsibility of the developer to make the right decisions in his code.
Once you as a developer have made all the right decisions, and if things are then
still slow, we will know exactly what _in Extbase_ is holding you back.
Please excuse my poor sense of diplomacy. No offense is intended.
More information about the TYPO3-project-typo3v4mvc