# Scroll api：How to understand “Keeping the search context alive”？

**URL:** <https://discuss.elastic.co/t/scroll-api-how-to-understand-keeping-the-search-context-alive/142051>\
**Category:** Elasticsearch\
**Created:** [July 29, 2018, 1:55am UTC](https://discuss.elastic.co/t/scroll-api-how-to-understand-keeping-the-search-context-alive/142051 "2018-07-29T01:55:01Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![xyx](https://avatars.discourse-cdn.com/v4/letter/x/eb8c5e/32.png) [@xyx](https://discuss.elastic.co/u/xyx)\
**Post date:** [July 29, 2018, 1:55am UTC](https://discuss.elastic.co/t/scroll-api-how-to-understand-keeping-the-search-context-alive/142051/1 "2018-07-29T01:55:01Z")

</div>

scroll api：How to understand “Keeping the search context alive”？

---

<div class="post-metadata">

**Author:** ![Mark\_Harwood](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mark_harwood/32/10538_2.png) [@Mark\_Harwood](https://discuss.elastic.co/u/Mark_Harwood)\
**Post date:** [July 29, 2018, 7:54am UTC](https://discuss.elastic.co/t/scroll-api-how-to-understand-keeping-the-search-context-alive/142051/2 "2018-07-29T07:54:40Z")

</div>

Returning for the next batch of results before your locked point-in-time view of the data times out

---

<div class="post-metadata">

**Author:** ![xyx](https://avatars.discourse-cdn.com/v4/letter/x/eb8c5e/32.png) [@xyx](https://discuss.elastic.co/u/xyx)\
**Post date:** [August 1, 2018, 1:50am UTC](https://discuss.elastic.co/t/scroll-api-how-to-understand-keeping-the-search-context-alive/142051/3 "2018-08-01T01:50:37Z")

</div>

First scroll search,I got the response,then I calculate the datas using 10 seconds.And then I do the secound scroll search,,,,,,  
Hypothesis:Every time,using 10 seconds to calculate the datas.

So,"Keeping the search context alive" must gr 10 seconds?

---

<div class="post-metadata">

**Author:** ![Mark\_Harwood](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mark_harwood/32/10538_2.png) [@Mark\_Harwood](https://discuss.elastic.co/u/Mark_Harwood)\
**Post date:** [August 1, 2018, 5:46am UTC](https://discuss.elastic.co/t/scroll-api-how-to-understand-keeping-the-search-context-alive/142051/4 "2018-08-01T05:46:42Z")

</div>

> [@xyx](#):
>
> Keeping the search context alive" must gr 10 seconds?

Yes. You must return before the deadline you set for yourself expires. If you said you’d be back in 10 seconds but took 12 then that ship has already sailed.

---

<div class="post-metadata">

**Author:** ![xyx](https://avatars.discourse-cdn.com/v4/letter/x/eb8c5e/32.png) [@xyx](https://discuss.elastic.co/u/xyx)\
**Post date:** [August 2, 2018, 9:33am UTC](https://discuss.elastic.co/t/scroll-api-how-to-understand-keeping-the-search-context-alive/142051/5 "2018-08-02T09:33:59Z")

</div>

Thanks,It is relly helps me.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [August 30, 2018, 9:34am UTC](https://discuss.elastic.co/t/scroll-api-how-to-understand-keeping-the-search-context-alive/142051/6 "2018-08-30T09:34:09Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
