Inc. and licensed under a Creative Commons Attribution-NonCommercial license: http://creativecommons.org/licenses/by-nc/3.0/ Open-sourcing http://spring.io Brian Clozel, Spring Framework committer, Pivotal inc. @brianclozel
Inc. and licensed under a Creative Commons Attribution-NonCommercial license: http://creativecommons.org/licenses/by-nc/3.0/ 8 http://github.com/bclozel @brianclozel Brian Clozel
Inc. and licensed under a Creative Commons Attribution-NonCommercial license: http://creativecommons.org/licenses/by-nc/3.0/ 11 The Example App problem
Inc. and licensed under a Creative Commons Attribution-NonCommercial license: http://creativecommons.org/licenses/by-nc/3.0/ 12 The Reference App problem
Inc. and licensed under a Creative Commons Attribution-NonCommercial license: http://creativecommons.org/licenses/by-nc/3.0/ 16 github.com/spring-io/sagan
Inc. and licensed under a Creative Commons Attribution-NonCommercial license: http://creativecommons.org/licenses/by-nc/3.0/ 19 JDK 8 ! List<String> projectVersions = project.getProjectReleases().stream()! .map(ProjectRelease::getVersion)! .collect(Collectors.toList());
Inc. and licensed under a Creative Commons Attribution-NonCommercial license: http://creativecommons.org/licenses/by-nc/3.0/ 20 Conditional Beans ! @Conditional(CustomCondition.class)! @Configuration! public class AppConfiguration {! ! }
Inc. and licensed under a Creative Commons Attribution-NonCommercial license: http://creativecommons.org/licenses/by-nc/3.0/ 22 What’s Spring Boot? “Spring Boot lets you pair-program with the Spring team. Josh Long, @starbuxman
Inc. and licensed under a Creative Commons Attribution-NonCommercial license: http://creativecommons.org/licenses/by-nc/3.0/ 23 AutoConfiguration ! @EnableAutoConfiguration // <- THIS!! @Configuration! @ComponentScan! public class AppConfiguration {! ! }
Inc. and licensed under a Creative Commons Attribution-NonCommercial license: http://creativecommons.org/licenses/by-nc/3.0/ 24 Developers! - Spring Loaded
Inc. and licensed under a Creative Commons Attribution-NonCommercial license: http://creativecommons.org/licenses/by-nc/3.0/ 26 Production-grade application
Inc. and licensed under a Creative Commons Attribution-NonCommercial license: http://creativecommons.org/licenses/by-nc/3.0/ 29 Build integration with Gradle apply plugin: 'java'! // create a webjar to be served by the sagan-site module! jar {! from 'dist'! eachFile { ! details -> details.path = ! details.path.startsWith('META-INF') ?: 'static/'+details.path! }! }! ! jar.dependsOn npmBuild
Inc. and licensed under a Creative Commons Attribution-NonCommercial license: http://creativecommons.org/licenses/by-nc/3.0/ 31 Gulp, a streaming build system
Inc. and licensed under a Creative Commons Attribution-NonCommercial license: http://creativecommons.org/licenses/by-nc/3.0/ 32 Gulp, a streaming build system // concatenate and minify CSS files! gulp.task('minify-css', function() {! return gulp.src('src/css/*.css')! .pipe(cssmin({root: 'src/css'}))! .pipe(gulp.dest('./dist/css'));! });! ! // tasks run in parallel! gulp.task('build', [‘minify-css', 'bower-files'], function(){ });
Inc. and licensed under a Creative Commons Attribution-NonCommercial license: http://creativecommons.org/licenses/by-nc/3.0/ 33 Gulp, a streaming build system // using gulp-bower-src to src bower dependencies! gulp.task('bower-files', function() {! var filter = gulpFilter(["**/*.js", "!**/*.min.js"]);! return bowerSrc()! .pipe(filter)! .pipe(uglify())! .pipe(filter.restore())! .pipe(gulp.dest('./dist/lib'));! })
Inc. and licensed under a Creative Commons Attribution-NonCommercial license: http://creativecommons.org/licenses/by-nc/3.0/ Cloud Foundry + Blue/green deploys
Inc. and licensed under a Creative Commons Attribution-NonCommercial license: http://creativecommons.org/licenses/by-nc/3.0/ 36 Sagan Blue instances CF Router (golang) Sagan Green instances
Inc. and licensed under a Creative Commons Attribution-NonCommercial license: http://creativecommons.org/licenses/by-nc/3.0/ 37 What about Session management?
Inc. and licensed under a Creative Commons Attribution-NonCommercial license: http://creativecommons.org/licenses/by-nc/3.0/ 38 What about DB schema changes?
Inc. and licensed under a Creative Commons Attribution-NonCommercial license: http://creativecommons.org/licenses/by-nc/3.0/ 39 General advice 12factor.net
Inc. and licensed under a Creative Commons Attribution-NonCommercial license: http://creativecommons.org/licenses/by-nc/3.0/ 42 Deployed live at springone 2GX
Inc. and licensed under a Creative Commons Attribution-NonCommercial license: http://creativecommons.org/licenses/by-nc/3.0/ 43 A distributed team! See http://spring.io/team
Inc. and licensed under a Creative Commons Attribution-NonCommercial license: http://creativecommons.org/licenses/by-nc/3.0/ 47 github.com/spring-io/sagan ! spring.io/blog Thanks !!