bServerSide + Scroller

bServerSide + Scroller

valenpovalenpo Posts: 13Questions: 0Answers: 0
edited February 2012 in General
Hello Allan!

thanks for great table!!! it is one of the best.

I started working with Scroller, it is working very well, speed is fantastic. My taks is make view 10 millions records on table

1st approach (Scroller): On this approach we get from serverside script 10k records (limit by server script), after that load it on table and scrolling is smooth and fast, but we dont have next 9 millions on records (just on server). And next step is enable bServerSide. If we try load all 10m records i suggest it can kill browser ;)

2nd approach (Scroller + bServerSide): on this approach we enable both. My thinking is how it must working (like you Scroller example) we load all records from server let it be 10k records, put it to aaData, and all other work will made by Scroller. When i enable bServerSide = true i get just 69 records from serverside script, because iDisplayStart = 0 and iDisplayLength = 69 (only 20 rows visible on screen). Is it possible to increase somethere iDisplayLength and iDisplayStart to make same smooth scrolling like on 1st approach?

Thanks



I'm new to JS but try go deep to source code and make some investigations, if i find somthing i will repost it here

Regards, and thanks for any clue.

Replies

  • valenpovalenpo Posts: 13Questions: 0Answers: 0
    I used [code]this.s.dt._iDisplayLength = this.s.viewportRows * 10; [/code] change 3 to 10, and now it is looks much nicer. Other quistio is it possible just popelate aaData array with new records and take the aaData array size of some value (like 50k), for better perfomance when you scroll back and scroll forward.

    Regards
  • allanallan Posts: 63,542Questions: 1Answers: 10,476 Site admin
    The change you have made in Scroller is exactly the one I would suggest. I'll look at making this a configuration option in future.

    > Other quistio is it possible just popelate aaData array with new records and take the aaData array size of some value (like 50k), for better perfomance when you scroll back and scroll forward.

    You could try implementing something like the server-side pipelining example: http://datatables.net/release-datatables/examples/server_side/pipeline.html . That would effectively cache the responses from the server - my example does have a limit, but if your data is unlikely to change, then you could just implement a full buffer there.

    Regards,
    Allan
  • valenpovalenpo Posts: 13Questions: 0Answers: 0
    Allan, thank you!! If i have a luck with modifications i send you patch ;)
This discussion has been closed.