Skip to content

Commit

Permalink
GRAILS-6484 - fix for class loading issue with ‘grails.doc.DocEngine’.
Browse files Browse the repository at this point in the history
The script compiling class loader can't find ‘grails.doc.DocEngine’ for some unknown reason, even though it can find other classes from the same jar. To work around this we load the class using loadClass() on demand.
  • Loading branch information
ldaley committed Jul 30, 2010
1 parent 4941d02 commit 0c06068
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion scripts/_GrailsDocs.groovy
Expand Up @@ -271,7 +271,13 @@ def readDocProperties(DocPublisher publisher) {
}

def configureAliases() {
DocEngine.ALIAS.putAll(config.grails.doc.alias)
// See http://jira.codehaus.org/browse/GRAILS-6484 for why this is soft loaded
def docEngineClassName = "grails.doc.DocEngine"
def docEngineClass = classLoader.loadClass(docEngineClassName)
if (!docEngineClass) {
throw new IllegalStateException("Failed to load $docEngineClassName to configure documentation aliases")
}
docEngineClass.ALIAS.putAll(config.grails.doc.alias)
}

private readIfSet(DocPublisher publisher,String prop) {
Expand Down

0 comments on commit 0c06068

Please sign in to comment.