def get_series_graph_png_cached( series, age, operation, metric, expires, invalidate):
    host = socket.gethostname()
    end_timestamp = int(time.time())
    start_timestamp = max(0, end_timestamp - int(age))
    graphURL = "http://" + host + construct_series_graph_url( series, start_timestamp, end_timestamp, operation, metric )
    def loader():
        return screenshot.get_graph_png(graphURL, x_crop=900, y_crop=750)

    cache_key = series + "/" + age + "/" + operation + "/" + metric
    return stupid_cache.stupid_cache_get("/tmp", cache_key, loader, expires, invalidate)
dataset/ETHPy150Open datastax/cstar_perf/frontend/cstar_perf/frontend/server/controllers.py/get_series_graph_png_cached/original