I have an application that needs many, many markers....just under 10
million. So, I have two questions:
1) I realize that 10M is an absurd number to try to load at once;
however, I would like to do more than 10k at a time and still have a
good user experience. Does anyone have any tips or advice on how to
best do this?
2) I have seen other (non-Flex/Flash) sites that load a subset of
markers at intervals. This way the user progressively gets more data
to visually consume as the page loads. In addition, the user knows
that the application is still active and working. Any advice on how I
can do this in Flex?
1.) make sure to use some sort of caching system for the markers. IE Dont re-instantiate 10k markers every time you load more data. 2.) do a limit test and see how much memory your application consumes at 1k / 5k/ 10k markers. I have a feeling 10k markers is way too many. (and totally unnecessary given #3) 3.) only load and display markers that are visible based on the bounds of the map and the zoom level. Unless your maps is huge 10k markers will be a jumbled unusable mess.
On May 22, 2008, at 1:27 PM, Michael Hansen wrote:
> I have an application that needs many, many markers....just under 10 > million. So, I have two questions:
> 1) I realize that 10M is an absurd number to try to load at once; > however, I would like to do more than 10k at a time and still have a > good user experience. Does anyone have any tips or advice on how to > best do this?
> 2) I have seen other (non-Flex/Flash) sites that load a subset of > markers at intervals. This way the user progressively gets more data > to visually consume as the page loads. In addition, the user knows > that the application is still active and working. Any advice on how I > can do this in Flex?
Regarding #3 - we have an extension for the Maps API called
MarkerManager that helps you do exactly that - once you determine
appropriate markers/cluster markers per zoom level, it will only
display the markers for a certain viewport/zoom. I'd be willing to
port that to AS3 if there's interest.
> 1.) make sure to use some sort of caching system for the markers. IE
> Dont re-instantiate 10k markers every time you load more data.
> 2.) do a limit test and see how much memory your application consumes
> at 1k / 5k/ 10k markers. I have a feeling 10k markers is way too many.
> (and totally unnecessary given #3)
> 3.) only load and display markers that are visible based on the bounds
> of the map and the zoom level. Unless your maps is huge 10k markers
> will be a jumbled unusable mess.
> On May 22, 2008, at 1:27 PM, Michael Hansen wrote:
> > I have an application that needs many, many markers....just under 10
> > million. So, I have two questions:
> > 1) I realize that 10M is an absurd number to try to load at once;
> > however, I would like to do more than 10k at a time and still have a
> > good user experience. Does anyone have any tips or advice on how to
> > best do this?
> > 2) I have seen other (non-Flex/Flash) sites that load a subset of
> > markers at intervals. This way the user progressively gets more data
> > to visually consume as the page loads. In addition, the user knows
> > that the application is still active and working. Any advice on how I
> > can do this in Flex?
Do you need to load them all, or is a subset of the 10M acceptable For example, return and display points relevant only to the viewport (which would be a small subset of the entire world). Or perhaps, return points based on other non-spatial criteria (eg. only POI that are tagged with "X").
If so, you can use any database that supports spatial queries. There's a fair bit of application-level work to get it all to work, though.
A small plug: our company Pentura Solutions has a product called the "Spatial DataBox". It can handle 10s of millions of points and perform queries on this set with a best-case response time of 1 / 10,000 second. I'm currently writing a connector for ActionScript 3 clients such as Google Maps for Flash.
----- Original Message ----- From: Joseph Bernstein <joe.bernst...@gmail.com> To: google-maps-api-for-flash@googlegroups.com Sent: Thursday, May 22, 2008 4:41:41 PM GMT-0500 US/Eastern Subject: Re: Tips for large amounts of markers
1.) make sure to use some sort of caching system for the markers. IE Dont re-instantiate 10k markers every time you load more data. 2.) do a limit test and see how much memory your application consumes at 1k / 5k/ 10k markers. I have a feeling 10k markers is way too many. (and totally unnecessary given #3) 3.) only load and display markers that are visible based on the bounds of the map and the zoom level. Unless your maps is huge 10k markers will be a jumbled unusable mess.
On May 22, 2008, at 1:27 PM, Michael Hansen wrote:
> I have an application that needs many, many markers....just under 10 > million. So, I have two questions:
> 1) I realize that 10M is an absurd number to try to load at once; > however, I would like to do more than 10k at a time and still have a > good user experience. Does anyone have any tips or advice on how to > best do this?
> 2) I have seen other (non-Flex/Flash) sites that load a subset of > markers at intervals. This way the user progressively gets more data > to visually consume as the page loads. In addition, the user knows > that the application is still active and working. Any advice on how I > can do this in Flex?
On 22 Mai, 23:21, "pamela (Google Employee)" <pamela....@gmail.com>
wrote:
> appropriate markers/cluster markers per zoom level, it will only
> display the markers for a certain viewport/zoom. I'd be willing to
> port that to AS3 if there's interest.
If I add 400 markers, the map gets useless, since each move (drag the
map) takes seconds to complete.
Back from the long weekend. Thanks for all the feedback. Here is
what I am thinking will be typical map behavior:
The map will cover nearly all of California with 10M + markers. So,
at the lowest zoom level there is no way to make sense of 10M markers
that are all receiving real-time data feeds...even if it was possible
to load them in a timely manner. So, I will have to use polygones
that summarize the markers statistics. As the zoom level increases
then the size of the polygones will have to change also. Eventually,
the polygones will be replaced by markers once the marker density is
<
2000 or so. I have found that I can efficiently pan and zoom at this
density of markers if I clear the markers before the pan/zoom and re-
render them at the end of the pan/zoom. My only concern is that I am
wondering how in the Flash API to make this perform the bast. Is
there
something that I am missing here in the FlashAPI other than creating
markers with Lat and Lon and adding them to the overlay? Is there a
way to load them in batches or collections?
- Michael
On May 25, 5:20 pm, justRIA <seaside...@mac.com> wrote:
> On 22 Mai, 23:21, "pamela (Google Employee)" <pamela....@gmail.com>
> wrote:
> > appropriate markers/cluster markers per zoom level, it will only
> > display the markers for a certain viewport/zoom. I'd be willing to
> > port that to AS3 if there's interest.
> If I add 400 markers, the map gets useless, since each move (drag the
> map) takes seconds to complete.
> Regarding #3 - we have an extension for the Maps API called
> MarkerManager that helps you do exactly that - once you determine
> appropriate markers/cluster markers per zoom level, it will only
> display the markers for a certain viewport/zoom. I'd be willing to
> port that to AS3 if there's interest.
> Another option for large amount of markers is to render them into a
> tile layer, and only turn them into clickable markers at a high zoom
> level.
> - pamela
> On May 22, 1:41 pm, Joseph Bernstein <joe.bernst...@gmail.com> wrote:
> > 1.) make sure to use some sort of caching system for the markers. IE
> > Dont re-instantiate 10k markers every time you load more data.
> > 2.) do a limit test and see how much memory your application consumes
> > at 1k / 5k/ 10k markers. I have a feeling 10k markers is way too many.
> > (and totally unnecessary given #3)
> > 3.) only load and display markers that are visible based on the bounds
> > of the map and the zoom level. Unless your maps is huge 10k markers
> > will be a jumbled unusable mess.
> > On May 22, 2008, at 1:27 PM, Michael Hansen wrote:
> > > I have an application that needs many, many markers....just under 10
> > > million. So, I have two questions:
> > > 1) I realize that 10M is an absurd number to try to load at once;
> > > however, I would like to do more than 10k at a time and still have a
> > > good user experience. Does anyone have any tips or advice on how to
> > > best do this?
> > > 2) I have seen other (non-Flex/Flash) sites that load a subset of
> > > markers at intervals. This way the user progressively gets more data
> > > to visually consume as the page loads. In addition, the user knows
> > > that the application is still active and working. Any advice on how I
> > > can do this in Flex?
> I'm have the same problem and I'd love to see it ported to AS3.
> Thanks!
> On May 22, 2:21 pm, "pamela (Google Employee)" <pamela....@gmail.com>
> wrote:
> > Regarding #3 - we have an extension for the Maps API called
> > MarkerManager that helps you do exactly that - once you determine
> > appropriate markers/cluster markers per zoom level, it will only
> > display the markers for a certain viewport/zoom. I'd be willing to
> > port that to AS3 if there's interest.
> > Another option for large amount of markers is to render them into a
> > tile layer, and only turn them into clickable markers at a high zoom
> > level.
> > - pamela
> > On May 22, 1:41 pm, Joseph Bernstein <joe.bernst...@gmail.com> wrote:
> > > 1.) make sure to use some sort of caching system for the markers. IE
> > > Dont re-instantiate 10k markers every time you load more data.
> > > 2.) do a limit test and see how much memory your application consumes
> > > at 1k / 5k/ 10k markers. I have a feeling 10k markers is way too many.
> > > (and totally unnecessary given #3)
> > > 3.) only load and display markers that are visible based on the bounds
> > > of the map and the zoom level. Unless your maps is huge 10k markers
> > > will be a jumbled unusable mess.
> > > On May 22, 2008, at 1:27 PM, Michael Hansen wrote:
> > > > I have an application that needs many, many markers....just under 10
> > > > million. So, I have two questions:
> > > > 1) I realize that 10M is an absurd number to try to load at once;
> > > > however, I would like to do more than 10k at a time and still have a
> > > > good user experience. Does anyone have any tips or advice on how to
> > > > best do this?
> > > > 2) I have seen other (non-Flex/Flash) sites that load a subset of
> > > > markers at intervals. This way the user progressively gets more data
> > > > to visually consume as the page loads. In addition, the user knows
> > > > that the application is still active and working. Any advice on how I
> > > > can do this in Flex?
> On May 27, 4:08 pm, chris <cg...@netmanifold.com> wrote:
> > I'm have the same problem and I'd love to see it ported to AS3.
> > Thanks!
> > On May 22, 2:21 pm, "pamela (Google Employee)" <pamela....@gmail.com>
> > wrote:
> > > Regarding #3 - we have an extension for the Maps API called
> > > MarkerManager that helps you do exactly that - once you determine
> > > appropriate markers/cluster markers per zoom level, it will only
> > > display the markers for a certain viewport/zoom. I'd be willing to
> > > port that to AS3 if there's interest.
> > > Another option for large amount of markers is to render them into a
> > > tile layer, and only turn them into clickable markers at a high zoom
> > > level.
> > > - pamela
> > > On May 22, 1:41 pm, Joseph Bernstein <joe.bernst...@gmail.com> wrote:
> > > > 1.) make sure to use some sort of caching system for the markers. IE
> > > > Dont re-instantiate 10k markers every time you load more data.
> > > > 2.) do a limit test and see how much memory your application consumes
> > > > at 1k / 5k/ 10k markers. I have a feeling 10k markers is way too many.
> > > > (and totally unnecessary given #3)
> > > > 3.) only load and display markers that are visible based on the bounds
> > > > of the map and the zoom level. Unless your maps is huge 10k markers
> > > > will be a jumbled unusable mess.
> > > > On May 22, 2008, at 1:27 PM, Michael Hansen wrote:
> > > > > I have an application that needs many, many markers....just under 10
> > > > > million. So, I have two questions:
> > > > > 1) I realize that 10M is an absurd number to try to load at once;
> > > > > however, I would like to do more than 10k at a time and still have a
> > > > > good user experience. Does anyone have any tips or advice on how to
> > > > > best do this?
> > > > > 2) I have seen other (non-Flex/Flash) sites that load a subset of
> > > > > markers at intervals. This way the user progressively gets more data
> > > > > to visually consume as the page loads. In addition, the user knows
> > > > > that the application is still active and working. Any advice on how I
> > > > > can do this in Flex?
> Great! Thanks for all your hard work!!! How long does something
> like that take? ...no pressure, just curious :-)
> On May 27, 4:09 pm, "pamela (Google Employee)" <pamela....@gmail.com>
> wrote:
> > I'm working on porting it right now. :)
> > - pamela
> > On May 27, 4:08 pm, chris <cg...@netmanifold.com> wrote:
> > > I'm have the same problem and I'd love to see it ported to AS3.
> > > Thanks!
> > > On May 22, 2:21 pm, "pamela (Google Employee)" <pamela....@gmail.com>
> > > wrote:
> > > > Regarding #3 - we have an extension for the Maps API called
> > > > MarkerManager that helps you do exactly that - once you determine
> > > > appropriate markers/cluster markers per zoom level, it will only
> > > > display the markers for a certain viewport/zoom. I'd be willing to
> > > > port that to AS3 if there's interest.
> > > > Another option for large amount of markers is to render them into a
> > > > tile layer, and only turn them into clickable markers at a high zoom
> > > > level.
> > > > - pamela
> > > > On May 22, 1:41 pm, Joseph Bernstein <joe.bernst...@gmail.com> wrote:
> > > > > 1.) make sure to use some sort of caching system for the markers. IE
> > > > > Dont re-instantiate 10k markers every time you load more data.
> > > > > 2.) do a limit test and see how much memory your application consumes
> > > > > at 1k / 5k/ 10k markers. I have a feeling 10k markers is way too many.
> > > > > (and totally unnecessary given #3)
> > > > > 3.) only load and display markers that are visible based on the bounds
> > > > > of the map and the zoom level. Unless your maps is huge 10k markers
> > > > > will be a jumbled unusable mess.
> > > > > On May 22, 2008, at 1:27 PM, Michael Hansen wrote:
> > > > > > I have an application that needs many, many markers....just under 10
> > > > > > million. So, I have two questions:
> > > > > > 1) I realize that 10M is an absurd number to try to load at once;
> > > > > > however, I would like to do more than 10k at a time and still have a
> > > > > > good user experience. Does anyone have any tips or advice on how to
> > > > > > best do this?
> > > > > > 2) I have seen other (non-Flex/Flash) sites that load a subset of
> > > > > > markers at intervals. This way the user progressively gets more data
> > > > > > to visually consume as the page loads. In addition, the user knows
> > > > > > that the application is still active and working. Any advice on how I
> > > > > > can do this in Flex?