Fix sentry

This commit is contained in:
md_5 2016-02-19 19:44:30 +11:00
parent d3d22bbec9
commit d575266522
3 changed files with 23 additions and 11 deletions

View File

@ -30,7 +30,7 @@
</dependency>
<dependency>
<groupId>net.kencochrane.raven</groupId>
<artifactId>raven-log4j2</artifactId>
<artifactId>raven</artifactId>
</dependency>
<dependency>
<groupId>net.md-5</groupId>

View File

@ -7,20 +7,26 @@ import mineplex.bungee.motd.MotdManager;
import mineplex.bungee.playerCount.PlayerCount;
import mineplex.bungee.playerStats.PlayerStats;
import mineplex.bungee.playerTracker.PlayerTracker;
import mineplex.bungee.status.InternetStatus;
import net.kencochrane.raven.RavenFactory;
import net.kencochrane.raven.DefaultRavenFactory;
import net.kencochrane.raven.dsn.Dsn;
import net.kencochrane.raven.jul.SentryHandler;
import net.md_5.bungee.api.plugin.Plugin;
public class Mineplexer extends Plugin
{
@Override
public void onEnable()
{
public void onEnable() {
getProxy().getScheduler().runAsync(this, new Runnable() {
@Override
public void run() {
// Sentry setup
Handler sentry = new SentryHandler(RavenFactory.ravenInstance("https://470f12378af3453ba089e0c0a0c9aae6:292516b722594784807aebb06db8ec38@app.getsentry.com/66323"));
Handler sentry = new SentryHandler(new DefaultRavenFactory().createRavenInstance(
new Dsn("https://470f12378af3453ba089e0c0a0c9aae6:292516b722594784807aebb06db8ec38@app.getsentry.com/66323"
)));
sentry.setLevel(Level.WARNING);
getProxy().getLogger().addHandler(sentry);
}
});
new MotdManager(this);
new LobbyBalancer(this);

View File

@ -77,6 +77,12 @@
<version>1.4.7</version>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>net.kencochrane.raven</groupId>
<artifactId>raven</artifactId>
<version>6.0.0</version>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>net.kencochrane.raven</groupId>
<artifactId>raven-log4j2</artifactId>