You are on page 1of 81

lnLroducuon Lo

Core Spring Topics



Contents

1
Spr|ng
Iramework

2
Spr|ng
Integranon &
8atch

3
Spr|ng Data




Spr|ng Iramework
Spr|ng Iramework 1hemes & 1rends
1
Spr|ng Iramework 3.1 (uec. 2011)
Current and Upcom|ng: 3.1, 3.2 & 3.3
! LnvlronmenL proles, !ava-based congurauon, declarauve cachlng

! lnlual !ava 7 supporL, ServleL 3.0 based deploymenL
Spr|ng Iramework 3.2 (uec. 2012)
! Cradle-based bulld, ClLPub-based conLrlbuuon model
! lully !ava 7 orlenLed, async MvC processlng on ServleL 3.0
Spr|ng Iramework 3.3 (C4 2013)
! Comprehenslve !ava SL 8 supporL (lncludlng lambda expresslons)
! SupporL for !ava LL 7 Al level and WebSockeL
S
p
r
|
n
g

I
r
a
m
e
w
o
r
k

3
.
1

LnvlronmenL-based bean denluon proles
!ava-based appllcauon congurauon
ServleL 3.0 based web appllcauon
deploymenL
ueclarauve cachlng
PlbernaLe 4.0/4.1 supporL
lnlual !ava 7 supporL
Ma[or revlslon aer Sprlng 3.0
- compleung Lhe programmlng model ln
many ways
8ean Dehn|non roh|es
<beans profile="production">
<bean id="dataSource"
class="org.apache.commons.dbcp.BasicDataSource"
destroy-method="close>
<property name="driverClass" value="${database.driver}"/>
<property name="jdbcUrl" value="${database.url}"/>
<property name="username" value="${database.username}"/>
<property name="password" value="${database.password}"/>
</bean>
</beans>

<beans profile="embedded">
<jdbc:embedded-database id="dataSource" type="H2">
<jdbc:script location="/WEB-INF/database/schema-member.sql"/>
<jdbc:script location="/WEB-INF/database/schema-activity.sql"/>
<jdbc:script location="/WEB-INF/database/schema-event.sql"/>
<jdbc:script location="/WEB-INF/database/data.sql"/>
</jdbc:embedded-database>
</beans>
3.1
Iava-8ased Conhguranon
@Configuration
@EnableTransactionManagement(proxyTargetClass=true)
public class DataConfig {

@Bean
public PlatformTransactionManager txManager() {
return new HibernateTransactionManager(sessionFactory());
}

@Bean
public SessionFactory sessionFactory() throws Exception {
return new LocalSessionFactoryBuilder(dataSource())
.addAnnotatedClasses(Order.class, Account.class)
.buildSessionFactory();
}

@Bean
public DataSource dataSource() {
// ... configure and return JDBC DataSource ...
}
}
3.1
Serv|et 3.0 8ased App||canon In|na||zer
/**
* Automatically detected and invoked on startup.
* May register listeners, filters, servlets etc against the given
* Servlet 3.0 ServletContext. */
public class MyWebAppInitializer implements WebApplicationInitializer {

public void onStartup(ServletContext sc) throws ServletException {
// Create the 'root' Spring application context
AnnotationConfigWebApplicationContext root =
new AnnotationConfigWebApplicationContext();

root.scan("com.mycompany.myapp");
root.register(FurtherConfig.class);

// Manages the lifecycle of the root application context
sc.addListener(new ContextLoaderListener(root));
...
}
}
3.1
Dec|aranve Cach|ng
@Cacheable
public Owner loadOwner(int id);

@Cacheable(condition="name.length < 10")
public Owner loadOwner(String name);

@CacheEvict
public void deleteOwner(int id);
3.1
S
p
r
|
n
g

I
r
a
m
e
w
o
r
k

3
.
2

Cradle-based bulld
8lnarles bullL agalnsL !ava 7
lnllned ASM 4.0 and CCLl8 3.0
Larly !Cache (!S8-107) supporL
Async MvC processlng on ServleL 3.0
Sprlng MvC LesL supporL
MvC congurauon renemenLs
SpLL renemenLs
Also lncludlng many runume renemenLs
- parually backporLed Lo 3.1.2/3.1.3
1he Iava SL 7 Story
3.2
Sprlng 3.1 came wlLh early supporL for !ava 7
- !u8C 4.1, lork!olnool, eLc
- framework lLself sull complled on !ava 6
Sprlng 3.2 ls now belng bullL on !ava 7
- Cl bullds runnlng agalnsL !ava 3, 6 and 7
- enabled Lhrough new Cradle bulld
Sprlng 3.2 comes wlLh ASM 4.0 and CCLl8 3.0
- fully supporung Lhe !ava 7 byLe code formaL
- ASM and CCLl8 lnllned lnLo Sprlng module [ars now
Lar|y ICache Support
3.2
Allgned wlLh Sprlng's cache absLracuon
!CacheCacheManager
!CacheManagerlacLory8ean
8ullL agalnsL !Cache 0.3 (!S8-107 dra)
no ouL-of-Lhe-box supporL for nauve !Cache
annoLauons yeL
- planned for Sprlng 3.3, once !Cache ls nal
Async MVC rocess|ng: Ca||ab|e
@RequestMapping(method=RequestMethod.POST)
public Callable<String> processUpload(MultipartFile file) {
// ...
return new Callable<String>() {
public String call() throws Exception {
// ...
return "someView";
}
};
}
3.2
Async MVC rocess|ng: Deferredkesu|t
@RequestMapping("/quotes")
@ResponseBody
public DeferredResult quotes() {
DeferredResult deferredResult = new DeferredResult();
// Add deferredResult to a Queue or a Map...
return deferredResult;
}

// In some other thread:
// Set the return value on the DeferredResult
deferredResult.set(data);
3.2
S
p
r
|
n
g

I
r
a
m
e
w
o
r
k

3
.
3

Comprehenslve !ava 8 supporL
SupporL for !ava LL 7 Al levels
locus on message-orlenLed archlLecLures
- annoLauon-drlven !MS endpolnL model
- revlsed appllcauon evenL mechanlsm
- WebSockeL supporL ln Sprlng MvC
nexL-generauon Croovy supporL
- Cralls bean bullder nally maklng lL lnLo
Sprlng proper
1he Iava SL 8 Story
3.3
Comprehenslve !ava 8 supporL
- lambda expresslons a.k.a. closures
- uaLe and 1lme Al (!S8-310)
- nlC-based P11 cllenL Als
- parameLer name dlscovery
- [ava.uul.concurrenL enhancemenLs
8eLalnlng supporL for !ava 3 and hlgher
- wlLh !ava 6 and 7 as common levels
- !ava 8 poLenually becomlng popular raLher
qulckly...
1he Iava LL 7 Story
3.3
SupporL for !ava LL 7 Al levels
- !Cache 1.0
- !MS 2.0
- !A2.1
- !1A 1.2 ([1ransacuonal)
- 8ean valldauon 1.1
- ServleL 3.1
- !Sl 2.2
8eLalnlng supporL for !ava LL 3 and hlgher
Annotanon-Dr|ven IMS Lndpo|nts
@JmsListener(destination="myQueue")
public void handleMessage(TextMessage payload);

@JmsListener(destination="myQueue", selector="...")
public void handleMessage(String payload);

@JmsListener(destination="myQueue")
public String handleMessage(String payload);
3.3
WebSocket Support
3.3
WebSockeL supporL ln currenL servers lsn'L fully
sLandardlzed yeL
!S8-336 upcomlng wlLhln Lhe !ava LL 7
umeframe
!euy 9 Lo adopL lL raLher qulckly
Sprlng lramework 3.3 Lo research all opuons for
WebSockeL supporL
- prlmarlly ln Sprlng MvC
- buL also generally for message-orlenLed
archlLecLures





2
Spr|ng Integranon & 8atch
Introducnon
S
p
r
|
n
g

I
n
t
e
g
r
a
n
o
n

Sprlng lnLegrauon ls mouvaLed by Lhe
followlng goals:
- rovlde a slmple model for
lmplemenung complex enLerprlse
lnLegrauon soluuons
- laclllLaLe asynchronous, message-
drlven behavlor wlLhln a Sprlng-based
appllcauon
- romoLe lnLuluve, lncremenLal
adopuon for exlsung Sprlng users
Integranon Sty|es
Integranon
8uslness Lo 8uslness lnLegrauon (828)
lnLer Appllcauon lnLegrauon (LAl)
lnLra Appllcauon lnLegrauon
llle 1ransfer
Shared uaLabase
8emoung
Messaglng
Lnterpr|se Integranon auerns
Integranon
8y Cregor Pohpe & 8obby
Woolf (ubllshed 2003)
Collecuon of well-known
pauerns
hup://www.ealpauerns.com/
ealpauerns.hLml
lcon llbrary provlded
Spr|ng Integranon
Integranon
Sprlng lnLegrauon provldes an exLenslon
of Lhe Sprlng programmlng model
Lo supporL Lhe well-known enLerprlse
lnLegrauon pauerns.
What |s Spr|ng Integranon?
Integranon
LlghL-welghL messaglng framework
rovldes an adapLer-based plauorm
|pes and I||ters aL Lhe core of Sprlng
lnLegrauon's archlLecLure
LndpolnL (lllLer)
Channel (lpe)
Message
Conhguranon
Integranon
xML namespace SupporL
AnnoLauon SupporL (e.g. [1ransformer, [8ouLer,
[ServlceAcuvaLor)
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:int="http://www.springframework.org/schema/integration"
xsi:schemaLocation="..">
...

<int:channel id="orders"/>
<int:splitter input-channel="orders"
expression="payload.items" output-channel="drinks"/>
<int:channel id="drinks"/>
<int:router input-channel="drinks"
expression="payload.iced ? 'coldDrinks' : 'hotDrinks'"/>
</beans>
Spr|ng Integranon DSLs
Integranon
Scala
Croovy
val messageFlow =
filter {payload: String => payload == "World"} -->
transform { payload: String => "Hello " + payload} -->
handle { payload: String => println(payload) }

messageFlow.send("World")
def builder = new IntegrationBuilder()
def flow = builder.messageFlow {
transform {payload->payload.toUpperCase()}
filter {payload-> payload =="HELLO"}
handle {payload->payload}
}
assert flow.sendAndReceive("hello") == "HELLO"
assert flow.sendAndReceive("world") == nul
Iava examp|e - xml
Integranon
!!"#$%&#'(&) #$%&'($)'*+$%,-($./,0012-%1345-+$6-4/
7$,-89+)%$:8$#+)(;-**$9./'*<;-**$9/=>

!!"#$*!+#', '*?8+)(;-**$9./'*<;-**$9/
$@?%$##'0*./?-490-71$:8-9#ABC0%97BD/
08+?8+)(;-**$9./+%-*#,0%E'*F<;-**$9/=>

!!"#$#,&"-*.,/', '*?8+)(;-**$9./+%-*#,0%E'*F<;-**$9/
$@?%$##'0*./BG$990 B H ?-490-7/
08+?8+)(;-**$9./90FF'*F<;-**$9/=>

!!"#$-',0!1'2&1#!0&#., '*?8+)(;-**$9./90FF'*F<;-**$9/
$@?%$##'0*./IAJ-&-19-*F1K4#+$ED108+1?%'*+9*A?-490-7D/=>

Iava examp|e - [ava
Integranon
345+!1 1+&-- 73,!"%8"#'%,&#!."8"#,. 9

345+!1 -#&#!1 0.!: /&!";7#,!"%<<< -#,!"%-=9
L??9'(-+'0*<0*+$@+ (0*+$@+ .
"'( >+&--?&#@A/+B33+!1&#!.">."#'C#;D1."*!%<C/+D=E
345-+$6-4 F-+$6-4 . (0*+$@+1F$+M$-*A345-+$6-411+&--=E
F-+$6-41#$*7A/C0%97/DN
O

345+!1 -#&#!1 !"#',*&1' F)G&#'(&) 9
345+!1 0.!: -'":;7#,!"% 0&+4'=E
O
O
What |s |n a Message?
Integranon
unlL of lnformauon
LncapsulaLes daLa
assed beLween endpolnLs
ConslsLs of headers
- conLalns daLa relevanL Lo Lhe messaglng sysLem
and a pay|oad
- acLual daLa for Lhe recelver
- dependlng on use-cases: C!C lnsLances or
serlallzed daLa
What |s |n a Message?
Integranon
package org.springframework.integration;

public interface Message<T> {
MessageHeaders getHeaders();
T getPayload();
}
Message neaders
Integranon
Message lu (auLomaucally generaLed uulu)
1lmesLamp
Correlauon ld
8eply Channel
Lrror Channel
Lxplrauon uaLe
rlorlLy
...
Add your own headers uslng a Peader Lnrlcher
Iuncnon of a Message
Integranon
Command Message
LvenL Message
uocumenL Message
What |s a Channe|?
Integranon
Channels connecL producers and consumers
(decoupllng)
MessageChannel lnLerface:
- ollableChannel (olllng Consumer)
- SubscrlbableChannel (LvenL urlven)
lmplemenLauons:
- ulrecLChannel
- ubllshSubscrlbeChannel
- CueueChannel
- rlorlLyChannel
- 8endezvousChannel
- LxecuLorChannel
<int:channel id="input">
<int:queue capacity="10"/>
</int:channel>
What |s a Lndpo|nt?
Integranon
olllng or evenL-drlven
lnbound or ouLbound
unldlrecuonal (Channel AdapLer) or
bldlrecuonal (CaLeway)
lnLernal or exLernal (appllcauon conLexL)
<inbound-channel-adapter/>
<outbound-channel-adapter/>
<inbound-gateway/>
<outbound-gateway/>
<gateway/>
<service-activator/>
kouter
Integranon
Message 8ouLer
ConLenL-based rouLer
8eclplenL llsL rouLer (dynamlc)
ayload Lype rouLer
Peader value rouLer
Lxcepuon Lype rouLe
1ransformer
Integranon
uelegaung vla ref/meLhod
Sprlng Lxpresslon Language
Croovy, !8uby, !yLhon, !avaScrlpL
Cb[ecL-Lo-!SCn / !SCn-Lo-Cb[ecL
ayload serlallzlng/deserlallzlng
llle-Lo-byLes, llle-Lo-SLrlng
!Ax8, !lbx, CasLor, xML8eans, xsLream
xaLh, xSL1
Cb[ecL xML Marshalllng/unmarshalllng (Sprlng
CxM)
...
Adapters
Integranon
AMC/8abblLMC
AWS*
llle/8esource
l1/l1S/Sl1
Cemllre
P11 (8LS1)
!u8C
!MS
!Mx
!A
Mongou8
C3/lMA/SM1
rlnL*
8edls
8Ml
8SS/ALom
Web Servlces
SM8*
Splunk*
* Sprlng lnLegrauon LxLenslons ro[ecL

Sprlng lnLegrauon Samples (Cafe)
Demo...
S
p
r
|
n
g

8
a
t
c
h

LlghLwelghL, comprehenslve baLch
framework deslgned Lo enable Lhe
developmenL of robusL baLch appllcauons
vlLal for Lhe dally operauons of enLerprlse
sysLems
8atch Iobs
8atch
8aLch [obs dler from onllne/real-ume
processlng appllcauons:
Long-runnlng
- Cen ouLslde omce hours
non-lnLeracuve
- Cen lnclude loglc for handllng errors or resLarLs
rocess large volumes of daLa
- More Lhan Ls ln memory or a slngle Lransacuon
Common 8atch Id|oms
8atch
8aLch [obs Lyplcally process large amounLs of
homogeneous lnpuL
Makes lLerauon a common concern: kepeat
1ranslenL errors durlng processlng may requlre
a ketry of an lnpuL lLem
Some lnpuL may noL be valld, may wanL Lo Sk|p
lL wlLhouL falllng
Some errors should fall Lhe [ob execuuon,
allowlng one Lo x Lhe problem and kestart Lhe
[ob lnsLance where lL le o
Spr|ng 8atch
8atch
Sprlng 8aLch supporLs Lhese common concerns
AbsLracLs Lhem ln Lhe framework
- !ob buslness loglc doesn'L need Lo care abouL
deLalls
Allows for slmple congurauon wlLh pluggable
sLraLegles
Iob and Step
8atch
Chunk-Cr|ented rocess|ng
8atch
lnpuL-ouLpuL can be grouped LogeLher
lnpuL collecLs lLems before ouLpumng: Chunk-
CrlenLed rocesslng
IobLauncher
8atch
Iob and Step |n Context
8atch
Iobkepos|tory and 8atch metadata
8atch
Spr|ng 8atch Adm|n
8atch
Sub pro[ecL of Sprlng 8aLch
rovldes Web ul and 8LS1ful lnLerface Lo
manage baLch processes
Manager, 8esources, Sample WA8
- ueployed wlLh baLch [ob(s) as slngle app Lo be able
Lo conLrol & monlLor [obs
- Cr monlLors exLernal [obs only vla shared daLabase
Sca||ng and ara||e| rocess|ng
8atch
llrsL 8ule:
- use Lhe slmplesL Lechnlque Lo geL Lhe [ob done ln
Lhe requlred ume
- uo noL opumlze/parallellze unnecessarlly
Cpuons:
- Mulu-Lhreaded SLep (slngle process)
- arallel SLeps (slngle process)
- 8emoLe Chunklng of SLep (mulu process)
- aruuonlng a SLep (slngle or mulu process)
Launch|ng batch [obs through messages
8atch
LvenL-urlven execuuon of Lhe !obLauncher
Sprlng lnLegrauon reLrleves Lhe daLa (e.g. le
sysLem, l1, ...)
Lasy Lo supporL separaLe lnpuL sources
slmulLaneously
Lxterna||z|ng batch process execunon
8atch
use Sprlng lnLegrauon lnslde of 8aLch [obs, e.g.:
- lLemrocessor
- lLemWrlLer
CMoad complex processlng
Asynchronous processlng supporL:
- AsynclLemrocessor
- AsynclLemWrlLer
LxLernallze chunk processlng uslng
ChunkMessageChannellLemWrlLer





3
Spr|ng Data
New data access techno|og|es
S
p
r
|
n
g

D
a
t
a

SupporLs new daLa access Lechnologles
such as non-relauonal daLabases, map-
reduce frameworks, and cloud based daLa
servlces
umbrella open source pro[ecL whlch
conLalns many subpro[ecLs LhaL are
speclc Lo a glven daLabase
Data s|ze?
Data
ro||feranon of "So|unons"
Data
Subpro[ects
Data
Category Sub-pro[ects Desc.
8elauonal
u8
!A Sprlng uaLa !A - Slmplles Lhe
developmenL of creaung a !A-based
daLa access layer
!u8C
LxLenslons
SupporL for Cracle 8AC, Advanced
Cueulng, and Advanced daLaLypes.
SupporL for uslng CueryuSL wlLh
!dbc1emplaLe
8lg uaLa Apache
Padoop
1he Apache Padoop pro[ecL ls an open-
source lmplemenLauon of frameworks
for rellable, scalable, dlsLrlbuLed
compuung and daLa sLorage
Subpro[ects (cont.)
Data
Category Sub-pro[ects Desc.
uaLa-grld Cemllre vMware vlabrlc Cemllre ls a
dlsLrlbuLed daLa managemenL plauorm
provldlng dynamlc scalablllLy, hlgh
performance, and daLabase-llke
perslsLence. lL blends advanced
Lechnlques llke repllcauon, paruuonlng,
daLa-aware rouung, and conunuous
querylng
P11 8LS1 Sprlng uaLa 8LS1 - erform C8uu
operauons of your perslsLence model
uslng P11 and Sprlng uaLa
8eposlLorles
Subpro[ects (cont.)
Data
Category Sub-pro[ects Desc.
key value
SLores
8edls 8edls ls an open source, advanced key-
value sLore
uocumenL
SLores
Mongou8 Mongou8 ls a scalable, hlgh-
performance, open source, documenL-
orlenLed daLabase
Craph
uaLabases
neo4[ neo4[ ls a graph daLabase, a fully
Lransacuonal daLabase LhaL sLores daLa
sLrucLured as graphs
Column
SLores
P8ase Apache P8ase ls an open-source,
dlsLrlbuLed, versloned, column-
orlenLed sLore modeled aer Coogle'
8lgLable
Spr|ng Data
Data
1rad|nona| Arch|tecture
Data
SCL u8
ul
ConLroller
uomaln Cb[ecLs
uaLa Access (PlbernaLe, !A, eLc.)
1rad|nona| Arch|tecture
Data
ul
ConLroller
uomaln Cb[ecLs
uaLa Access (PlbernaLe, !A, eLc.)
Comp|ex neterogeneous Arch|tecture
Data
ul
ConLroller
uomaln Cb[ecLs
Cemllre Mongou8 neo4[ CLher
Spr|ng Data neterogeneous Arch|tecture
Data
ul
ConLroller
uomaln Cb[ecLs
Sprlng uaLa 8eposlLory
!A
kepos|tory
Data
!"#$%&"' )"&*""+ &," #-.%$+ %+# #%&% .%//$+0
1%2"3' 4'$+0 % 5-11"56-+71$8" $+&"39%5" 9-3
%55"''$+0 #-.%$+ -):"5&'
hup://msdn.mlcroso.com/en-us/llbrary/649690.aspx

hup://marunfowler.com/eaaCaLalog/reposlLory.hLml

Spr|ng Data kepos|tor|es
Data
345+!1 !"#',*&1' >,4:H'3.-!#.,)IJK 8L 'C#'":- 7',!&+!M&5+'
'C#'":- H'3.-!#.,)IJK 8LN 9

J -&0';J '"#!#)=E
8#',&5+'IJN -&0';8#',&5+'IO 'C#'":- JN '"#!#!'-=E
J *!":P"';8L !:=E
5..+'&" 'C!-#-;8L !:=E
8#',&5+'IJN *!":B++;=E
+."% 1.4"#;=E
0.!: :'+'#';8L !:=E
0.!: :'+'#';J '"#!#)=E
0.!: :'+'#';8#',&5+'IO 'C#'":- JN '"#!#!'-=E
0.!: :'+'#'B++;=E
O
uery Methods
Data
SLarLsWlLh, LndsWlLh, ConLalns, Aer, 8efore
Spr|ng Data GemI|re - 8eposlLorles
Data
345+!1 !"#',*&1' >."#&1#H'3.-!#.,)
'C#'":- G'/*!,'H'3.-!#.,)I>."#&1#K Q."%N9
P'#+!<0*+-(+> ,'*7M4Q'%#+*-E$AK+%'*F ,'%#+*-E$DN
P'#+!<0*+-(+> ,'*7M4P-#+*-E$K+-%+#C'+;AK+%'*F 9-#+*-E$DN
O

!R@E9 &$%#'0*.!"#$! &'()*+',-!./012!34
!2$-*#S2$-*# T
@E9*#.!5667899:::#;7<+',=<>?&:)<@#)<,9;(5&?>9*>6>9,&=1*>6>!
@#'S#(;$E-P0(-+'0*.!A!4

!%$?0#'+0%'$# 2-#$)?-(U-F$.!()?#>(?&#<&7);+6)<+&;! 94
!=2$-*#S2$-*#>
Doma|n Mapp|ng
Data
ul
ConLroller
uomaln Cb[ecLs
Sprlng uaLa 8eposlLory
!A
Spr|ng Data GemI|re - LnuLy Mapplng
Data
VW$F'0*
345+!1 1+&-- >."#&1# !/3+'/'"#- 7',!&+!M&5+' 9
3,!0&#' -#&#!1 *!"&+ +."% !"#$%&'"#!$()*+, . /01

VX7
3,!0&#' Q."% !:E

3,!0&#' 7#,!"% *!,-#"&/'E

3,!0&#' 7#,!"% +&-#"&/'E

3,!0&#' 7'#I?@."'N 3@."'- R "'( S&-@7'#I?@."'N;=E

3,!0&#' 7'#IT/&!+B::,'--N '/&!+B::,'-- R
"'( S&-@7'#IT/&!+B::,'--N;=E
O
Doma|n Mapp|ng
Data
ul
ConLroller / Servlce
uomaln Cb[ecLs
Sprlng uaLa 8eposlLory
!A
Spr|ng Data GemI|re - 8eposlLory usage
Data
!F,$)7-+-S%$?0#'+0%'$#
2-#$)?-(U-F$.!)<,#;7<+',=<>?&#:)<@#*>6>#&B>?7C&! 94
345+!1 !"#',*&1' >4-#./',H'3.-!#.,)
'C#'":- G'/*!,'H'3.-!#.,)I>4-#./',K Q."%N 9
K$+!<8#+0E$%> ,'*7L99ADN
P'#+!<8#+0E$%> ,'*7M4P-#+*-E$AK+%'*F 9-#+*-E$DN
<8#+0E$% ,'*7M4YE-'9L77%$##AYE-'9L77%$## $E-'9L77%$##DN
O
Spr|ng Data GemI|re - 8eposlLory usage
Data
345+!1 1+&-- >4-#./',7',0!1' 9
3,!0&#' -#&#!1 Q.% &(2 .
0(23%45(#672"50(289:!5(;"#<"#=$="74&%!!>1

VL8+06'%$7
<8#+0E$%W$?0#'+0%4 (8#+0E$%W$?0#'+0%4N

345+!1 >4-#./', 1,'&#'>4-#./',;>4-#./', 14-#./',= 9
<8#+0E$% *$6<8#+0E$% . (8#+0E$%W$?0#'+0%41#-&$A(8#+0E$%DN
,'#4," "'(>4-#./',E
O

111
Spr|ng Data GemI|re - 8eposlLory usage
Data
111

345+!1 5..+'&" :'+'#'>4-#./',;+."% !:= 9
<8#+0E$% (8#+0E$% . (8#+0E$%W$?0#'+0%41,'*7Z*$A'7DN
!* ;14-#./', UR "4++= 9
(8#+0E$%W$?0#'+0%417$9$+$A(8#+0E$%DN
,'#4," #,4'E
O
C),#:><'D!EF;6)?&< ')6 =)F'* =)< +* ! G +*HI
,'#4," *&+-'E
O

345+!1 Q!-#I>4-#./',N *!":>4-#./',-V)Q&-#"&/';
7#,!"% +&-#"&/'= 9
,'#4," 14-#./',H'3.-!#.,)<*!":V)Q&-#"&/';+&-#"&/'=E
O
O
Use CL for query
Data
345+!1 !"#',*&1' ?,.:41#H'3.-!#.,)
'C#'":- >,4:H'3.-!#.,)I?,.:41#K Q."%N 9
V[8$%4A/KYPY<I \ QWZ3 =]%078(+ 6;$%$ -++%'28+$#^_`a . _b/D
P'#+!]%078(+> ,'*7M4L++%'28+$#AK+%'*F U$4c K+%'*F &-98$DN
O

VW$F'0*
345+!1 1+&-- ?,.:41# 'C#'":- B5-#,&1#?',-!-#'"#T"#!#) 9
3,!0&#' 7#,!"% "&/'K :'-1,!3#!."E
3,!0&#' V!%L'1!/&+ 3,!1'E
3,!0&#' F&3I7#,!"%K 7#,!"%N &##,!54#'- R
"'( S&-@F&3I7#,!"%K 7#,!"%N;=E
O
Deve|opment 1oo||ng
Data
IDL Integranon - Lcllpse
Data
Sprlng uaLa Cemllre
Demo...
keferences
Spr|ng Iramework 3.2 and 3.3 - !uergen Poeller
Introducnon to Spr|ng Integranon and Spr|ng 8atch
- Cunnar PlllerL, Cary 8ussell
Gemng started w|th Spr|ng Data and D|str|buted
Database Gr|ds - uavld 1uranskl, Mark !ohnson


Introducnon to Core Spr|ng 1op|cs
1hank you!