(Translated by https://www.hiragana.jp/)
Overhead in pull-attr-datoms by gersak · Pull Request #221 · tonsky/datascript · GitHub
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

Overhead in pull-attr-datoms #221

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

gersak
Copy link

@gersak gersak commented May 8, 2017

Hi,

For one of our projects we are using Datascript in combination with Om/next for rendering our frontend. Using DB on frontend is really nice for rendering DOM elements. We are working with quite big datasets on frontend that have alot of relations between them.

As our project grows dataset is getting larger and larger and we are pulling more and more data for rendering. IE. in one part of application we are pulling about 520 entites that represent user tasks. Each of this task is linked to a project and to the person that assinged task, group and so on... So we have about 3-5 references to other entities.

This pull takes about ~0.5-7 seconds and feels slowish.

--
When going through dev tools in Chrome we've noticed that clojure.core/into is taking alot of "Total Time" when calling datascript.core/pull so we've modified datascript.pull-api/pull-attr-datoms to see what will happen.

Results are that execution time was cut down for ~100-150 ms.

Can you please check out changes and comment?

Tnx


This change is Reviewable

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

Successfully merging this pull request may close these issues.

1 participant