This website uses cookies to ensure you get the best experience. By clicking or navigating the site you agree to allow our collection of information through cookies. More info

2 minutes to read Posted on Friday July 27, 2018

Updated on Monday November 6, 2023

portrait of Paul Keller

Paul Keller

Policy , Open Future

portrait of Richard Doe

Richard Doe

Lead Developer , Europeana Foundation

GLAM tech: Making viewing items on Europeana Collections seamless with the Europeana Media Proxy

There’s always some construction going on behind the scenes of Europeana Collections. We're constantly making improvements to make searching for and viewing cultural heritage seamless. One of our tools is the Europeana Media Proxy. In this GLAM tech series post, we tell you all about it.

Large construction works with figures standing on scaffolding
Title:
Construction of the 1862 International Exhibition Building at South Kensington (Scaffolding at Main Entrance)
Creator:
Tachet, Claude Francois
Date:
1861-2
Institution:
Rijksmuseum
Country:
The Netherlands

Europeana Collections displays images, videos and audio files through a standardised viewer. A piece of software called the Europeana Media Proxy (or EMP for short) helps display millions of media objects on the individual item pages of the Europeana Collections website in a consistent manner.

How it works

When you request a record that has a direct link to a supported media object, it is displayed on a page of the Collections website itself, as opposed to requiring you to first navigate to the data provider’s website to view it.

Europeana does not store media objects. We instead display them from the address provided by the data partner. This is where the EMP comes in: instead of including direct references to the media on the partner’s web systems in the HTML of the item page, we include a reference to the URL of the EMP configured to indicate which record and media object you want to view.

Why it’s valuable

This has a number of advantages over directly linking to the item. Most importantly, it allows us to display media objects hosted on hundreds of different systems operated by our data providers in a uniform way. In addition, it also allows us to ensure that the entire user session is secured via SSL so that we can offer you  a maximum level of security and privacy.

The EMP allows us to provide a state-of-the-art user experience without Europeana having to store the media objects. As a result, our data partners continue to have full control over all of the digital content that they make available on Europeana.

If you want to learn more about how the Europeana Media Proxy works on a technical level, please continue below where we have reproduced the section of the Europeana infrastructure documentation that describes the EMP service.

Getting technical

Europeana Media Proxy architecture

Europeana Media Proxy architecture, Europeana, CC BY-SA.

Purpose

The EMP serves media such as images, audio and video from data providers’ web systems to end-users. The diagram above shows its high-level architecture.

The need for the EMP arose from the fact that Europeana Collections presents media from many different third-party systems and strives to do so as consistently as is practical. These third-party systems run a variety of web server software, resulting in a variety of HTTP headers being included in, and omitted from, responses, and a variety of error-handling strategies. The Media Proxy aims to normalise these various upstream HTTP responses to support consistent presentation in Europeana Collections.

Functionality

The EMP receives HTTP requests for media objects associated with the cultural heritage objects published by Europeana, either in the 'edm:isShownBy' or one of the' edm:hasViews' of the record.

To prevent abuse as a general-purpose proxy, incoming requests are validated against the Search API to verify that the requested remote media object is in fact one ingested into Europeana. If not, the request is rejected.

The EMP then requests the media object from the provider’s web systems, normalises response headers, and proxies the media to the client. In the case of encountering errors from the provider, normalised error responses are sent to the client.

Structure

The Media Proxy is a simple Rack web application with one endpoint.

Tools

  • Puma is used as the web server.

  • Code library dependencies are managed with Bundler.

  • Automated testing uses RSpec.

Usage

Where the Europeana Collections item pages display media hosted on provider’s websites, they do so via the Media Proxy, with some exceptions for embedded media such as IIIF and iFrames.

Given a Europeana record with ID '/09102/_GNM_693983', and one of its media objects having the URL  http://www.mimo-db.eu/media/GNM/IMAGE/MIR1097_1279787057222_2.jpg, the Europeana Collections page for this item will display this media object from the Media Proxy URL: https://proxy.europeana.eu/09102/_GNM_693983?view=http%3A%2F%2Fwww.mimo-db.eu%2Fmedia%2FGNM%2FIMAGE%2FMIR1097_1279787057222_2.jpg.

The URL path for the request to the media proxy is the Europeana record ID. The view parameter in the URL query indicates an 'edm:hasView' of the record to proxy. If the view parameter is omitted, then the media object for the record’s 'edm:isShownBy' will be proxied.

For more articles like these, view the entire GLAM tech series on Pro News.

top