Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.
Sign upPerformance merged #191
Performance merged #191
Conversation
This comment has been minimized.
This comment has been minimized.
This Pull Request does not respect our Coding Standards, please, see the report below:
|
@@ -0,0 +1,421 @@ | |||
<?php | |||
/** | |||
* File containing the Content Type Handler class |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
patrickallaert
Dec 13, 2012
Author
Contributor
Damn, I forgot creating a Sniff for checking that ;-)
} | ||
|
||
/** | ||
* Adds a new field definition to an existing Type. |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
patrickallaert
Dec 13, 2012
Author
Contributor
The thing is that documentation tools behaves differently. Some supports inheritance with a dedicated flag, some inherit by default,... We should probably decide what to do based on some research in this regard.
I am personally in favour of not documenting anything if there is no doc change, and use {@inheritdoc}
in the case we have something that is changed and use it for copy/paste parent doc. Like in:
/**
* Wrapper for in-memory cache. {@inheritdoc}
*/
The following shouldn't be used IMHO as it should be documentation tool's default behaviour:
/**
* {@inheritdoc}
*/
This comment has been minimized.
This comment has been minimized.
gggeek
Dec 13, 2012
Contributor
-1 for "standalone" {@inheritdoc} tags. Line noise (as in: makes reading the actual code harder, and for the generated doc, well, let's improve doc generators instead)
This comment has been minimized.
This comment has been minimized.
bdunogier
Dec 14, 2012
Member
The fact that @inheritdoc reduces readability is an argument. But honestly,
I'd rather have to jump to ther parent method, rather than having outdated
documentation due to copy/paste + entropy.
I think that we can require that our users, at least those who have
interest in reading our code will rely either on the generated
documentation OR on a feature-rich IDE rather than on reading code only.
This assumption makes it really easier to provide, accurate, up-to-date
documentation.
In any case, I think we at least all agree that if we choose not to
copy/paste parent documentation when it is identical, it is useless to add
@inheritdoc. This should be automatically handled by IDEs and doc
generators. And actually, it is.
I have checked support on sami (http://ezsystems.github.com/ezp-next/sami),
and it indeed isn't perfect. I have also checked PhpStorm 5. There are
the results with a validate function, in the Image\Type class, inheriting
from FieldType.
No phpdoc at all:
- sami: documentation from parent is re-used
- phpstorm: documentation from parent is re-used
Inline {@inheritdoc} with extra documentation
/**
* Overridden documentation.
* {@inheritdoc}
*/
- sami: Prints out {@inheritdoc}
- phpstorm: Doesn't take the local changes into account
Override short description in the child method
This comment has been minimized.
This comment has been minimized.
This Pull Request does not respect our Coding Standards, please, see the report below:
|
Should be sane, even limited compared to what zetacomponents offer. But with the limited set of table and column names, this should be fast enough.
Only requests in one single request.
Especially mind: We need to clear internal caches during rollback.
Made code readable again and removed unused bits
This comment has been minimized.
This comment has been minimized.
This Pull Request does not respect our Coding Standards, please, see the report below:
|
This comment has been minimized.
This comment has been minimized.
Tested on a real life website and those patches make a big difference :-) Still not perfect, but way better. |
This comment has been minimized.
This comment has been minimized.
All unit and integration tests are now passing. |
This comment has been minimized.
This comment has been minimized.
Only thing would be that I think "eZ/Publish/Core/Persistence/Legacy/Content/Type/MemoryCachingHandler.php" is probably unneeded when SPI cache is introduced. But given this is pr instance it does not hurt, and refactoring needed to de couple handlers to be able to inject outer spi persistence cache handler is to high. So: +1 as is |
This comment has been minimized.
This comment has been minimized.
Thanks for your comment @andrerom, I second your opinion. |
2880245
into
ezsystems:master
This comment has been minimized.
This comment has been minimized.
gggeek
commented on eZ/Publish/Core/Persistence/Legacy/Content/Search/Gateway/EzcDatabase.php
in c9b7ad6
Jun 4, 2013
BUG - you need an array_unique here, or different SQL, as you can get back duplicate object ids |
This comment has been minimized.
This comment has been minimized.
OPTIMIZATION: if there is no offset and limit set, just execute 1 query instead of 2, and do a php count() on the resulting array. It makes db happier |
This comment has been minimized.
This comment has been minimized.
Use issue tracker please. |
This comment has been minimized.
This comment has been minimized.
Ref EZP-21906 |
patrickallaert commentedDec 13, 2012
Pull request merging the changes made by Kore in performance branch.