diff --git a/.gitignore b/.gitignore index dff4636..c708f67 100644 --- a/.gitignore +++ b/.gitignore @@ -6,4 +6,6 @@ out .idea .settings plugin.xml - +target-eclipse +.project +.classpath diff --git a/.settings/org.codehaus.groovy.eclipse.preferences.prefs b/.settings/org.codehaus.groovy.eclipse.preferences.prefs deleted file mode 100644 index bf339c7..0000000 --- a/.settings/org.codehaus.groovy.eclipse.preferences.prefs +++ /dev/null @@ -1,3 +0,0 @@ -#Created by grails -eclipse.preferences.version=1 -groovy.dont.generate.class.files=true diff --git a/AirbrakeGrailsPlugin.groovy b/AirbrakeGrailsPlugin.groovy index b0caa1e..ec613a3 100644 --- a/AirbrakeGrailsPlugin.groovy +++ b/AirbrakeGrailsPlugin.groovy @@ -5,9 +5,9 @@ import grails.plugins.airbrake.Configuration class AirbrakeGrailsPlugin { // the plugin version - def version = '0.9.4' + def version = '0.9.5' // the version or versions of Grails the plugin is designed for - def grailsVersion = "2.0.0 > *" + def grailsVersion = "2.4.5 > *" def pluginExcludes = [ "grails-app/conf/**", "grails-app/views/**", @@ -25,7 +25,7 @@ class AirbrakeGrailsPlugin { def license = "APACHE" def developers = [ [ name: "Phuong LeCong", email: "phuong@reteltechnologies.com" ], [ name: "Jon Palmer", email: "jpalmer@care.com" ], - [name: 'Donal Murtagh']] + [name: 'Donal Murtagh'],[name: 'Mario Meltzow', email: 'meltzow@invencom.de']] def issueManagement = [ system: "GitHub", url: "https://github.com/cavneb/airbrake-grails/issues" ] def scm = [ url: AirbrakeNotifier.NOTIFIER_URL ] diff --git a/application.properties b/application.properties index 569915a..78c9670 100644 --- a/application.properties +++ b/application.properties @@ -1,4 +1,3 @@ #Grails Metadata file #Wed Nov 28 23:11:01 EST 2012 -app.grails.version=2.1.1 -plugins.tomcat=2.1.1 +app.grails.version=2.4.5 diff --git a/grails-app/conf/BuildConfig.groovy b/grails-app/conf/BuildConfig.groovy index ff99bbc..eda4b6f 100644 --- a/grails-app/conf/BuildConfig.groovy +++ b/grails-app/conf/BuildConfig.groovy @@ -1,20 +1,30 @@ grails.project.work.dir = "target" +grails.project.dependency.resolver = "maven" // or ivy grails.project.dependency.resolution = { // inherit Grails' default dependencies inherits("global") { + checksums true // Whether to verify checksums on resolve + legacyResolve false // uncomment to disable ehcache // excludes 'ehcache' } log "warn" // log level of Ivy resolver, either 'error', 'warn', 'info', 'debug' or 'verbose' repositories { - grailsCentral() + inherits true // Whether to inherit repository definitions from plugins + grailsPlugins() + grailsHome() + grailsCentral() + mavenCentral() } - +// dependencies { +// compile 'org.apache.commons:commons-lang3:3.4' +// } + plugins { - build(":release:2.2.1", ":rest-client-builder:1.0.2", ":tomcat:$grailsVersion") { - export = false - } + build(":release:3.1.2", ":rest-client-builder:2.1.1") { + export = false + } test(':spock:0.7') { export = false } diff --git a/grails-app/conf/UserDataFilter.groovy b/grails-app/conf/UserDataFilters.groovy similarity index 90% rename from grails-app/conf/UserDataFilter.groovy rename to grails-app/conf/UserDataFilters.groovy index 004269b..a0c519f 100644 --- a/grails-app/conf/UserDataFilter.groovy +++ b/grails-app/conf/UserDataFilters.groovy @@ -1,5 +1,3 @@ -package grails.plugins.airbrake.test - class UserDataFilters { def airbrakeService diff --git a/grails-app/views/error.gsp b/grails-app/views/error.gsp deleted file mode 100644 index 64a0b08..0000000 --- a/grails-app/views/error.gsp +++ /dev/null @@ -1,11 +0,0 @@ - - - - Grails Runtime Exception - - - - - - - \ No newline at end of file diff --git a/src/groovy/grails/plugins/airbrake/Notice.groovy b/src/groovy/grails/plugins/airbrake/Notice.groovy index 2bb4800..6944580 100644 --- a/src/groovy/grails/plugins/airbrake/Notice.groovy +++ b/src/groovy/grails/plugins/airbrake/Notice.groovy @@ -2,6 +2,8 @@ package grails.plugins.airbrake import groovy.transform.ToString import groovy.xml.MarkupBuilder + +import org.apache.commons.lang.exception.ExceptionUtils; import org.codehaus.groovy.grails.web.servlet.mvc.GrailsWebRequest import org.springframework.web.context.request.RequestContextHolder import org.codehaus.groovy.grails.exceptions.StackTraceFilterer @@ -149,7 +151,10 @@ class Notice { this.env = args.env this.cgiData = args.cgiData ?: getCgiDataFromRequest(webRequest) this.session = args.session ?: getSessionData(webRequest) - this.backtrace = parseBacktrace(throwable?.stackTrace ?: args.backtrace) + + def stacktraceList = throwable? (ExceptionUtils.getThrowableList(throwable).collect { it.stackTrace}.flatten()) :[] + + this.backtrace = parseBacktrace(throwable? stacktraceList : args.backtrace) this.errorClass = throwable?.class?.name ?: args.errorClass // Grails creates a really long error message for uncaught exceptions. Essentially a combination of all the webRequest meta data. // However it creates very unhelpful messages for airbrake so we just prefer the simpler message on the throwable diff --git a/web-app/WEB-INF/applicationContext.xml b/web-app/WEB-INF/applicationContext.xml deleted file mode 100644 index 69fbef3..0000000 --- a/web-app/WEB-INF/applicationContext.xml +++ /dev/null @@ -1,33 +0,0 @@ - - - - - Grails application factory bean - - - - - - A bean that manages Grails plugins - - - - - - - - - - - - - - - - utf-8 - - - \ No newline at end of file diff --git a/web-app/WEB-INF/sitemesh.xml b/web-app/WEB-INF/sitemesh.xml deleted file mode 100644 index 72399ce..0000000 --- a/web-app/WEB-INF/sitemesh.xml +++ /dev/null @@ -1,14 +0,0 @@ - - - - - - - - - - - \ No newline at end of file