You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If a user has say 500 friends, calling the foursquare api to get his friends list will result in 500 user objects being loaded into memory... can there be a better way in which the objects could be streamed to the api caller? I dont know much ruby, but am thinking something like yield a object at every iteration from the stream or maybe store the stream to disk and yield objects from the disk based stream ... My use case is checking for users who are foursquare friends and auto-friending them on my service. If a few popular users decide to signup at pretty much the same time, my 512mb linode vps might run out of memory...
It would be great if the foursquare gem could handle that transparently for me...
The text was updated successfully, but these errors were encountered:
If a user has say 500 friends, calling the foursquare api to get his friends list will result in 500 user objects being loaded into memory... can there be a better way in which the objects could be streamed to the api caller? I dont know much ruby, but am thinking something like yield a object at every iteration from the stream or maybe store the stream to disk and yield objects from the disk based stream ... My use case is checking for users who are foursquare friends and auto-friending them on my service. If a few popular users decide to signup at pretty much the same time, my 512mb linode vps might run out of memory...
It would be great if the foursquare gem could handle that transparently for me...
The text was updated successfully, but these errors were encountered: