Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
Static Resources Management with Spring
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
Brian Clozel
April 30, 2015
Programming
390
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Static Resources Management with Spring
(Workshop)
Brian Clozel
April 30, 2015
More Decks by Brian Clozel
See All by Brian Clozel
Back from SpringOnePlatform 2019
bclozel
4
260
Intro à Spring Boot
bclozel
0
170
Cloud native apps with Spring Cloud
bclozel
1
760
HTTP2 for the web developer devoxx
bclozel
0
220
HTTP2 for the web developer
bclozel
1
180
Inside http://spring.io
bclozel
1
420
Intro to Spring Boot
bclozel
4
2.9k
Inside spring.io: a production spring reference application
bclozel
0
190
Open-sourcing http://spring.io
bclozel
1
680
Other Decks in Programming
See All in Programming
Next.js: The final boss of Web Performance
guaca
0
390
Long Living Tokens, Die, Die, Die! (or: The One Ring is Banned in Modern)
sylph01
0
410
Augmenting AI with the Power of Jakarta EE
ivargrimstad
0
170
선언형 햅틱 라이브러리 진동을 소개합니다
l2hyunwoo
1
300
AI時代のFlutter品質設計 — アプリ品質を守るQuality Layers
omatty198
0
360
AmebaブログはKMPから卒業します
kmars0605
0
330
エージェントを使い続けるためのメタワーク / Meta-work for keeping using the agent
rkaga
6
2.2k
Vapor Mode でアクセシビリティは 壊れないか検証した話
fuqda
1
330
Optunaを作ったときにやりたかったこと、その後 (2026/10/16, Optuna Meetup #3)
iwiwi
4
1.5k
AI時代のIaC入門 〜なぜインフラをコードで管理したいのか?〜 / Introduction to IaC in the AI Era
akihisaikeda
6
1.4k
クラウドエージェントは、 何がそんなに便利なのか / what makes cloud agents so useful
rkaga
5
800
まずはコードより業務と向き合う:テーブル解体のためにPdMを呼んだ話
sakawe_ee
0
180
Featured
See All Featured
Designing for humans not robots
tammielis
254
26k
Designing Experiences People Love
moore
143
24k
A Tale of Four Properties
chriscoyier
163
24k
Building Better People: How to give real-time feedback that sticks.
wjessup
371
20k
[Rails World 2026] Durable orchestration on Rails: from continuation to workflow
palkan
3
1.2k
Navigating the moral maze — ethical principles for Al-driven product design
skipperchong
2
680
Unsuck your backbone
ammeep
672
58k
Skip the Path - Find Your Career Trail
mkilby
1
290
Bridging the Design Gap: How Collaborative Modelling removes blockers to flow between stakeholders and teams @FastFlow conf
baasie
0
760
Optimising Largest Contentful Paint
csswizardry
37
4k
The Cult of Friendly URLs
andyhume
79
7.1k
Future Trends and Review - Lecture 12 - Web Technologies (1019888BNR)
signer
PRO
0
3.8k
Transcript
Static Resources Management workshop Brian Clozel @brianclozel
Getting started $ open http://bit.ly/resourcehandling $ git clone http://github.com/bclozel/…
$ git fetch -‐-‐all $ cd angularjs && mvn package
Brian Clozel @brianclozel http://spring.io/team/bclozel
First application 4 What could we achieve before Spring
4.1?
Resource Handling < 4.1 • Serve static resources from *any*
Spring Resource location • Basic Cache header management • Easy to configure 5
WORKSHOP PART #1
Remaining questions • optimize (concatenate, minify) • transform (LESS,
coffeescript, gzip) • front-‐end optimization (cache busting URLs, concatenate, minify) • development experience 7
AngularJS 8 First run with Resource Handling
Sources of inspiration • a complete asset pipeline built into
Spring MVC • fingerprinting URLs for cache busting • client side dev in Sagan project 9
Why not an asset pipeline? • runtime vs. build time
approach • languages and tools evolve *fast* • ES6, HTTP/2 10
Client source code layout • src/main/webapp just not adequate anymore
• client *and* server: dependency management, modularity, tests, build artifacts • client-‐side development: ctrl+S, F5 11
WORKSHOP PART #2
ES6 app 13 client-‐side build and JS module loaders
Spring 4.1 resource handling • ResourceResolver • ResourceTransformer
• ResourceUrlProvider 14
Built-‐in ResourceResolvers • PathResourceResolver • VersionResourceResolver • GzipResourceResolver
• CachingResourceResolver 15
Built-‐in ResourceTransformers • CssLinkResourceTransformer • AppCacheManifestResourceTransformer • CachingResourceTransformer
16
VersionResourceResolver • VersionStrategies: • ContentVersionStrategy (md5 hashes) •
FixedVersionStrategy (version string as a path prefix) 17
WORKSHOP PART #3
Q&A 19 …and what’s next?
What’s next? • https://github.com/bclozel/spring-‐resource-‐ handling • https://github.com/spring-‐io/sagan •
https://jira.spring.io 20