Giter VIP home page Giter VIP logo

overops-event-generator's Introduction

OverOps Event Generator

This project is a simple Spring Boot application that generates a variety of OverOps event types useful for testing OverOps installations and highlighting features. This application is similar in purpose the JavaJam error generating jar which is often referenced in OverOps docs and samples, but expands upon its usefulness. This application includes the following features:

  • easy to understand events which correlate to all supported OverOps event types including:
    • Caught and Uncaught Exceptions
    • Logged ERROR and WARN statements
    • Swallowed Exceptions
    • Custom Events via OverOps SDK
    • HTTP Errors
    • Timers
  • logging statements at various levels to highlight log view capabilities
  • application name and deployment name specified in MANIFEST.MF

Building & Running

Execute the following commands clean and package the jar:

./mvnw clean package -DskipTests

To start and monitor this application with OverOps you can execute the following commands. Full documentation on installing and configuring OverOps can be found here.

java -agentlib:TakipiAgent -jar overops-event-generator-2.1.3.jar

or

nohup java -agentlib:TakipiAgent -jar overops-event-generator-2.1.3.jar &

DB Console

You can view the H2 web console at /console for example http://localhost:8080/console. Use the following connection properties:

Field Value
Driver Class org.h2.Driver
JDBC URL jdbc:h2:mem:overops
User Name sa
Password

Timer Configuration

This application includes a class called SlowService which contains a method called longRunningMethod. This method will always take 5 seconds to execute. You can easily add this method to the OverOps Timer's dialog with a threshold below 5 seconds to test the Timer capability.

Pivotal Cloud Foundry (PCF) Example

Deploying to PCF is a trivial exercise with OverOps. The OverOps agent is available as part of the PCF Java Buildpack under our original name Takipi. More details can be found here.

To deploy this error generator on PCF you can execute the following commands from the root of this project. It is assumed you have the PCF CLI installed and an active OverOps SaaS account.

# clean and package the error generator
mvn clean package

# register "takipi" service using CUPS
cf cups takipi -p '{ "secret_key": "<YOUR_KEY>" }'

# push the generator to PCF
cf push overops-event-generator -p target/overops-event-generator-2.1.3.jar

# bind the "takipi" service to the generator
cf bind-service overops-event-generator takipi

# re-stage the generator and enjoy
cf restage overops-event-generator

overops-event-generator's People

Contributors

daverted avatar timveil avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.