rabbit.proxy
Interface ClientTrafficLogger

All Known Implementing Classes:
StandardOutTrafficLogger

public interface ClientTrafficLogger

A logger that gets notified about client traffic usage.

Author:
Robert Olofsson

Method Summary
 void logTraffic(String user, HttpHeader request, TrafficLogger client, TrafficLogger network, TrafficLogger cache, TrafficLogger proxy)
          Log the traffic usage for the given user and request.
 void setup(SProperties properties, HttpProxy proxy)
          Setup this logger
 

Method Detail

logTraffic

void logTraffic(String user,
                HttpHeader request,
                TrafficLogger client,
                TrafficLogger network,
                TrafficLogger cache,
                TrafficLogger proxy)
Log the traffic usage for the given user and request.

Parameters:
user - the authenticated user, may be null if user is not authenticated
request - the actual http request header
client - the traffic between the client and the proxy
network - the traffic between the proxy and the network
cache - the traffic between the proxy and the cache
proxy - the traffic generated by the proxy

setup

void setup(SProperties properties,
           HttpProxy proxy)
Setup this logger

Parameters:
properties - the SProperties to get the settings from.
proxy - the HttpProxy that is using this logger