package com.capgemini.reports.execution.posting;

import javax.jms.JMSException;
import javax.naming.NamingException;

import com.capgemini.reports.execution.AbstractExecutionReport;
import com.capgemini.reports.queuing.EmbeddedServer;

/** This strategy posts the job immediately in the queue for execution. */
public class ImmediatePostingStrategy implements IPostingStrategy {

    @Override
    public void handleRequest(final AbstractExecutionReport<?, ?> report) throws JMSException, NamingException {
        // Simply post the report into the queues
        EmbeddedServer.produce(report);
    }

}
