All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.mindscapehq.raygun4java.play2.RaygunPlayScalaRequestMessage Maven / Gradle / Ivy

Go to download

The official provider for the Raygun Crash Reporting service. This is the Play Framework provider module that sends errors caught from your Play Scala/Java application. Used in conjunction with raygun4java.core.

There is a newer version: 4.1.1
Show newest version
package com.mindscapehq.raygun4java.play2;

import java.util.logging.Logger;
import scala.collection.JavaConverters;
import play.api.mvc.Request;

public class RaygunPlayScalaRequestMessage extends RaygunPlayRequestMessage
{

  public RaygunPlayScalaRequestMessage(Request request)
  {
    try
    {
      httpMethod = request.method();
      ipAddress = request.remoteAddress();
      hostName = request.host();
      url = request.uri();

      headers = JavaConverters.mapAsJavaMapConverter(request.headers().toSimpleMap()).asJava();
      String rawQuery = request.rawQueryString();

      if (!rawQuery.isEmpty())
      {
        queryString = queryStringToMap(rawQuery);
      }
    }
    catch (NullPointerException e)
    {
      Logger.getLogger("Raygun4Java-Play2").info("Couldn't get all request params: " + e.getMessage());
    }
  }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy