-
Notifications
You must be signed in to change notification settings - Fork 736
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implemented index template support #905
Conversation
* | ||
* @var string Index pattern | ||
*/ | ||
protected $name = ''; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I know that symfony has the naming standard without the underline, but as the Elastica project everywhere use $_* for protected variables, please adjust it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I just made it like that because in contributing notes is mentioned that code must be in PSR-2 code style, but exactly PSR-2 says that:
Property names SHOULD NOT be prefixed with a single underscore to indicate protected or private visibility.
https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-2-coding-style-guide.md#42-properties
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep, we take the SHOULD part here ;-) I fixed it and pushed it to master. Thanks for the contribution.
In general this looks good to me. It would be good to have 1-2 more functional tests. This would also discover in case the API changes in the future. |
@torinaki I'm happy to merge the pull request if you adjust the coding styles above so FriendsOfSymfony/FOSElasticaBundle#916 can be pushed forward. |
Another awsome feature! I will use it. Thanks. |
@torinaki I made the adjustments here and merged it: f64e8ae It would be nice if you could add some more integration tests later. |
@ruflin thank you for quick response. I'll prepare more functional tests with another PR soon |
👍 |
Initial implemtation of elastica index templates support:
https://www.elastic.co/guide/en/elasticsearch/reference/current/indices-templates.html
Required for FriendsOfSymfony/FOSElasticaBundle#916