Skip to content

Figure out how to load all thumbnails in a single request #2

@jmalczyk

Description

@jmalczyk

Loading all these thumbnails individually is blocking available http threads for other things (like the static maps). This is an issue in the browser and in mobile. We need a way to deliver them in larger batches or all at once, such as via image sprites or maybe base64 encapsulated in json, and client-side components that inject these into the DOM where needed. The json packaged base64 approach could potentially work better within angular, since we can bind the values to species objects that we can keep track of in the browser cache. Images fetched via sprites are apparently harder to cache.

The first step to implementation will be to create a thumbnails api that accepts a list of scientific names and rolls the images together with one of the above methods.

Potential issues:

  • It may be difficult to efficiently resize to thumbnail from what is in the blobstore -- Google is currently doing that for us using the getServingUrl method, but that would mean then pulling images through AppEngine using urlfetch rpcs, which are also thread limited. We will have to experiment with that vs pulling from blobstore directly and resizing using the Images api.
  • We are not actively caching species-level information on the client. In order to avoid always asking for all thumbnails needed, we will want to start doing that, which means coming up with ways to invalidate those cached items.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions