Skip to content
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

ActiveRecord is slow when use where condition. #11

Open
dmitriybelyy opened this issue May 8, 2015 · 1 comment
Open

ActiveRecord is slow when use where condition. #11

dmitriybelyy opened this issue May 8, 2015 · 1 comment
Labels
type:enhancement Enhancement

Comments

@dmitriybelyy
Copy link

ActiveRecord is very flat and slow (if we have many records at redis hash) when we try get with where condition.
For example:

RedisModelAR::find()
->where(['login' => $login])
->one();

Because when go to findByPk use HGETALL.

What about rewrite logic at ActiveQuery with HMGET etc. for best performance ?
And fields(AR attributes) store as hash field redis(hmset) not json or serialize.

@samdark
Copy link
Member

samdark commented May 25, 2015

Any idea on how to do it? If yes, would you mind working on a pull request?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:enhancement Enhancement
Projects
None yet
Development

No branches or pull requests

3 participants