-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #56 from matrei/matrei/update-cleanup
Update and cleanup for Grails 6/Java 11
- Loading branch information
Showing
132 changed files
with
2,502 additions
and
3,076 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 4 additions & 2 deletions
6
examples/pubsub-demo/grails-app/controllers/pubsub/demo/ApplicationController.groovy
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 7 additions & 3 deletions
10
examples/pubsub-demo/grails-app/controllers/pubsub/demo/SumController.groovy
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,19 @@ | ||
package pubsub.demo | ||
|
||
import groovy.transform.CompileStatic | ||
|
||
@CompileStatic | ||
class SumController { | ||
static responseFormats = ['json', 'xml'] | ||
|
||
@SuppressWarnings('unused') | ||
static responseFormats = ['json', 'xml'] | ||
|
||
SumService sumService | ||
TotalService totalService | ||
|
||
def index() { | ||
int sum = sumService.sum(1, 2) | ||
int sum = sumService.sum 1, 2 | ||
int total = totalService.accumulatedTotal | ||
render "sum: $sum, total: $total" | ||
render"sum: $sum, total: $total" | ||
} | ||
} |
12 changes: 8 additions & 4 deletions
12
examples/pubsub-demo/grails-app/controllers/pubsub/demo/TaskController.groovy
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,28 @@ | ||
package pubsub.demo | ||
|
||
import groovy.transform.CompileStatic | ||
|
||
import static grails.async.web.WebPromises.* | ||
|
||
@CompileStatic | ||
class TaskController { | ||
|
||
@SuppressWarnings('unused') | ||
static responseFormats = ['json', 'xml'] | ||
|
||
def index() { | ||
task { | ||
sleep 1000 | ||
render "good" | ||
render 'good' | ||
} | ||
} | ||
|
||
def error() { | ||
task { | ||
sleep(1000) | ||
throw new RuntimeException("bad") | ||
sleep 1000 | ||
throw new RuntimeException('bad') | ||
}.onError { | ||
render text:"error occured",status: 500 | ||
render text: 'error occurred', status: 500 | ||
} | ||
} | ||
} |
5 changes: 5 additions & 0 deletions
5
examples/pubsub-demo/grails-app/domain/pubsub/demo/Author.groovy
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,13 @@ | ||
package pubsub.demo | ||
|
||
import grails.compiler.GrailsCompileStatic | ||
|
||
/** | ||
* Created by graemerocher on 18/05/2017. | ||
*/ | ||
@GrailsCompileStatic | ||
class Author { | ||
|
||
String name | ||
|
||
} |
5 changes: 5 additions & 0 deletions
5
examples/pubsub-demo/grails-app/domain/pubsub/demo/Book.groovy
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,10 @@ | ||
package pubsub.demo | ||
|
||
import grails.compiler.GrailsCompileStatic | ||
|
||
@GrailsCompileStatic | ||
class Book { | ||
|
||
String title | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
9 changes: 0 additions & 9 deletions
9
examples/pubsub-demo/grails-app/init/pubsub/demo/BootStrap.groovy
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
23 changes: 0 additions & 23 deletions
23
examples/pubsub-demo/src/integration-test/groovy/pubsub/demo/HttpClientSpec.groovy
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.