https://github.com/spring-projects/spring-boot/tree/1.5.x/spring-boot-starters
https://docs.spring.io/spring-boot/docs/1.5.x/reference/html/production-ready-endpoints.html
client-dependencies
, npm or yarn (via gradle)Deployment
Views
Documentation
Metrics
Web (Other)
scaffolding
erichelgeson@gmail.com
@nulleric
Online software for Pre-Schools and Day Cares.
https://sproutary.com
See many plugins you know and some you don’t with example code
So many good plugins out there allow you to quickly setup sane defaults for your app and get going quickly
Few things not as apparent to newcomers or seasoned Grails 2 devs.
Magic is still there and that’s what I’m going to talk about.
SpringBoot already comes with one
session/springsession
datasource { logSql = true }
mail/emailtools
grails-app/assets/vendor
frontend/assets
container/undertow
container/tc
grails.config.locations = [
"classpath:myconfig.groovy",
"file:///etc/app/myconfig.yml",
"~/.grails/myconfig.properties",
'file:${catalina.base}/myconfig.groovy',
]
grails yml-to-groovy-config [ymlFile] [optional outputFile]
grails groovy-to-yml-config [ymlFile] [optional outputFile]
--spring.config.location=classpath:/some.properties
SERVER_PORT == server.port
info/info
➜ source grails list-profiles
| Available Profiles
--------------------
* angular - A profile for creating Grails applications with Angular 2
* rest-api - Profile for REST API applications
* base - The base profile extended by other profiles
* angularjs - A profile for creating applications using AngularJS
* plugin - Profile for plugins designed to work across all profiles
* profile - A profile for creating new Grails profiles
* react - A profile for creating Grails applications with a React frontend
* rest-api-plugin - Profile for REST API plugins
* web - Profile for Web applications
* web-jboss7 - A Profile for Creating a JBoss 7.1 EAP Project
* web-plugin - Profile for Plugins designed for Web applications
* webpack - A profile for creating applications with node-based frontends using webpack
Older Mixin framework still works in 3.3+
Sometimes unnecessary even for a plugin
Grails provides a lot of great tools to build the functionality you ended quickly
Settings plugin (older 2.x plugin)
The Current Echosystem
Thanks
My preferred way AWS elastic beanstalk
Docker
sshoogar
War (gradle deploy plugin)
Deploy info
Logging slf4j
remote api
GSP (Yes it’s a plugin now)
Gson (json views)
Markup
grails-vaadin-plugin
asciidoctorj
spring-restdocs
swagger
statsd metrics
Sentry
Datadog
Accutaotrs monitoring
Cookie
Not really something I use, anyways right after building
scaffolding
angular-scaffolding
3?
2?
1…?
@Scheduled
scheduling/scheduled
grails-app/jobs
as srcscheduling/quartz
scheduling/schwartz
resque
security/spring-security
spring-session
works out of boxdb/dbm
db/flyway
we all know sqlLogging= true, helpfull, but not always clear.
p6spy sits between your app and jdbc driver and intercepts & logs exact sql queries (with params!) unlike hibernate sqlLogging
hibernateStats is available, easily added to an dev-time interceptor
Good to have on in development to quickly see if you’re making 1 or 1000 sql queries, or flushing the session 100’s of times.
db/logging
db/dialects
db/multitenant
sproutary-grails
testing/testing
good
bad
ugly
AWS gradle plugins make this trivial
What to know
docker gradle plugins
Easily build your jar into a container, and define your other infra containers as well
Sometimes you just need to push a file somewhere and restart a service
sshoogar - dsl for doing just that
Deploy war to Tomcat api
(git commit,)
grailsinfocontributor
Log Accutator API, change logging on the fly
Ship logs off system!
Splunk, ELK, Papertrail, anywhere!
Static type, speed, inheritance, etc
hal
json-api
Easy & powerful writing tool
Gradle integration
Keep documentation with your code!
Publish to static site (s3/etc)
Or just use the library itself
Health
Build your own
(careful, up/down one) - https://tedvinke.wordpress.com/2017/10/25/why-is-springs-health-down-down-up-up-up-and-down-again/
$ grails s2-quickstart com.yourapp User Role
CONFIGURE SUCCESSFUL in 7s
| Creating User class 'User' and Role class 'Role' in package 'com.yourapp'
| Rendered template PersonWithoutInjection.groovy.template to destination grails-app/domain/com/yourapp/User.groovy
| Rendered template PersonPasswordEncoderListener.groovy.template to destination src/main/groovy/com/yourapp/UserPasswordEncoderListener.groovy
| Rendered template Authority.groovy.template to destination grails-app/domain/com/yourapp/Role.groovy
| Rendered template PersonAuthority.groovy.template to destination grails-app/domain/com/yourapp/UserRole.groovy
|
************************************************************
* Created security-related domain classes. Your *
* grails-app/conf/application.groovy has been updated with *
* the class names of the configured domain classes; *
* please verify that the values are correct. *
************************************************************
<sec:*>
taglibsEverything you need to build a website quickly is there.
Discover-ability
You need to know where to look, or come to this talk to find everything.
years between releases
better changelogs
broken links