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

Load large set of data #20

Merged
merged 12 commits into from
Jul 22, 2018

Conversation

Prakriti-nith
Copy link
Contributor

This PR runs in parallel with daru-view#104.

@Prakriti-nith
Copy link
Contributor Author

Now, DataTables can work with a large dataset too (~5000000, above it may cause problems). This much of data can not loaded using client-side processing as browser hangs. Here are the screenshots for the implemented code:

Including this in controller:
datatable_ajax_controller

We can see that it is generating the datatable for 2000000 rows.
datatable_ajax

@Prakriti-nith Prakriti-nith changed the title Added attr_accessor data and fix rubocop offences [WIP] Load large set of data Jul 6, 2018
@Prakriti-nith
Copy link
Contributor Author

Prakriti-nith commented Jul 12, 2018

I have kept client-side processing (using data option and providing js array) for below 50000 rows and server-side above that. It is because, in server-side processing, the searching option is not working properly.

@Prakriti-nith
Copy link
Contributor Author

I have updated the API, done some refactoring, added docs and tests along with the feature to load large set of data(above 50000 rows). For small dataset, client-side processing is used with data being provided as js array rather than HTML table (HTML table supports only 5000 rows).

@Prakriti-nith Prakriti-nith changed the title [WIP] Load large set of data Load large set of data Jul 14, 2018
@Prakriti-nith
Copy link
Contributor Author

Rails examples added in this PR screenshots:
rails1
rails2
rails3
rails4

@Prakriti-nith
Copy link
Contributor Author

@Shekharrajak can you please review this PR?

Copy link
Owner

@Shekharrajak Shekharrajak left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some methods are not documented. We should do it in other PRs.

@@ -50,6 +52,8 @@ def typecast(value, type=nil)
value
end
end
end # module ParamHelpers end
# rubocop:enable Metrics/PerceivedComplexity, Metrics/MethodLength
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will try to fix these in other PRs

@Shekharrajak Shekharrajak merged commit e47615f into Shekharrajak:master Jul 22, 2018
@Shekharrajak
Copy link
Owner

Thanks!

@Prakriti-nith
Copy link
Contributor Author

closes #19

@Shekharrajak Shekharrajak mentioned this pull request Aug 23, 2018
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.

2 participants