Dynamic Deployment With Apache Felix
-
Upload
marcel-offermans -
Category
Technology
-
view
1.861 -
download
2
description
Transcript of Dynamic Deployment With Apache Felix
![Page 1: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/1.jpg)
Dynamic deployment with Apache Felix
Marcel Offermans
Friday, November 6, 2009
![Page 2: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/2.jpg)
Friday, November 6, 2009
![Page 3: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/3.jpg)
Marcel Offermans
• commi0er and PMC member at Apache Felix
• commi0er at Apache ACE
• so<ware architect at luminis technologies
Friday, November 6, 2009
![Page 4: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/4.jpg)
Agenda
• The case for OSGi
• Dynamic Deployment with Apache ACE
• Demo, ACE in AcIon
• Wrapup
Friday, November 6, 2009
![Page 5: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/5.jpg)
The case for OSGi
• Paint ApplicaIon
• wri0en in Java
• sold to customers
Friday, November 6, 2009
![Page 6: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/6.jpg)
“Specials” that fork your code
Friday, November 6, 2009
![Page 7: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/7.jpg)
ConCnuous builds taking a long Cme
Friday, November 6, 2009
![Page 8: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/8.jpg)
Code reflects the architecture?
Friday, November 6, 2009
![Page 9: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/9.jpg)
How hard is it to change something?
Friday, November 6, 2009
![Page 10: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/10.jpg)
Re-‐use: copy/paste
Friday, November 6, 2009
![Page 11: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/11.jpg)
Re-‐use: Object Oriented
Friday, November 6, 2009
![Page 12: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/12.jpg)
Re-‐use: Component Based
Friday, November 6, 2009
![Page 13: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/13.jpg)
ParCConing your applicaCon
• minimize dependencies
• consider rate of change
• minimize complexity
• maximize architected flexibility
• promote reuse
• improve testability
Friday, November 6, 2009
![Page 14: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/14.jpg)
Designing with services
!"#$%
&'(%)
*+,(%')%-.,(%')%
/0#)1(($234
56)272'). 8)1903
2:;0%) #"%#6)
&<0,)
'%"0=46)
>)=9)%)%
28"=4?#0=302
6(44)%#(=54 )3)='
@(4 *3)='A(=54;%0B(=
4%0,<
@07(;'
C- 203)
A(..0=9
(,)= =)8
Friday, November 6, 2009
![Page 15: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/15.jpg)
Designing with services
!"#$%
&'(%)
*+,(%')%-.,(%')%
/0#)1(($234
56)272'). 8)1903
2:;0%) #"%#6)
&<0,)
'%"0=46)
>)=9)%)%
28"=4?#0=302
6(44)%#(=54 )3)='
@(4 *3)='A(=54;%0B(=
4%0,<
@07(;'
C- 203)
A(..0=9
(,)= =)8
(24"D#0 (24"D6(4
2'(%)D/2 2'(%)D8)1903
(24"D)3)='2'(%)
607(;'
607(;'D4%0,<
2<0,)
2<0,)D2:;0%) 2<0,)D#"%#6) 2<0,)D'%"0=46)
/)6"+D#0 /)6"+D6(4 /)6"+D)3)='
28"=4D#0=302 28"=4D;" 28"=4D#.9D(,)= 28"=4D#.9D203) 28"=4D#.9D=)8
".,D234
".,(%')% )+,(%')%
%)=9)%)% #(..0=9
28"=4D#(='%(62
)+,DE(($ ".,D!"#$%
Friday, November 6, 2009
![Page 16: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/16.jpg)
Designing with services
!"#$%
&'(%)
*+,(%')%-.,(%')%
/0#)1(($234
56)272'). 8)1903
2:;0%) #"%#6)
&<0,)
'%"0=46)
>)=9)%)%
28"=4?#0=302
6(44)%#(=54 )3)='
@(4 *3)='A(=54;%0B(=
4%0,<
@07(;'
C- 203)
A(..0=9
(,)= =)8
(24"D#0 (24"D6(4
2'(%)D/2 2'(%)D8)1903
(24"D)3)='2'(%)
607(;'
607(;'D4%0,<
2<0,)
2<0,)D2:;0%) 2<0,)D#"%#6) 2<0,)D'%"0=46)
/)6"+D#0 /)6"+D6(4 /)6"+D)3)='
28"=4D#0=302 28"=4D;" 28"=4D#.9D(,)= 28"=4D#.9D203) 28"=4D#.9D=)8
".,D234
".,(%')% )+,(%')%
%)=9)%)% #(..0=9
28"=4D#(='%(62
)+,DE(($ ".,D!"#$%
#(..0=92
0,"D"(
0,"D(24"
2<0,)2 )+,(%')%2
;"
#(=5409."= 6(4 )3)='56)2'(%) 8)1903
#(..0=9%)=9)%)%
9%08"=4
4%0,< 234
Friday, November 6, 2009
![Page 17: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/17.jpg)
The Case for ACE
• Started in incubator on april 24th 2009
• So<ware distribuIon framework based on OSGi
• 7 commi0ers
• working codebase
• no release yet
• h0p://incubator.apache.org/ace/
Friday, November 6, 2009
![Page 18: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/18.jpg)
Deployment
!"#$"%&%'()
!"#$"%&%'(*
!"#$"%&%'(!
!"#$%&'(
!"#$%&')
!"#$%&'*
!"#$%&'"()
Friday, November 6, 2009
![Page 19: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/19.jpg)
last year!"#$"%&%'()
!"#$"%&%'(*
+,-.&'()
+,-.&'(!
last month!"#$"%&%'()
!"#$"%&%'(*
+,-.&'()
+,-.&'(*
+,-.&'(!
last week
!"#$"%&%'()
!"#$"%&%'(*
!"#$"%&%'(!
!"#$%&'(
!"#$%&')
!"#$%&'*
Keeping the history
now
!"#$"%&%'()
!"#$"%&%'(*
!"#$"%&%'(!
!"#$%&'(
!"#$%&')
!"#$%&'*
Friday, November 6, 2009
![Page 20: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/20.jpg)
Why?
• Automate deployment
• Insight into who uses what
• History of each system
• Consistent development, tesIng, producIon
• Basis for several possible extensions
Friday, November 6, 2009
![Page 21: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/21.jpg)
Topology
!"#$%!
!"#$%!
!"#$%!
&%!'(#)*#(+,-,(&,&$.
-%#+%#
/(0*(&%&!.#%*(-,!(#1
/2,%&!0"&"$%0%&!.
"$%&!
0"&"$%0%&!."$%&!
0"&"$%0%&!."$%&!
Friday, November 6, 2009
![Page 22: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/22.jpg)
High level overview
!"#"$!"$%&'()$)*"("$+
!"#,-&("$+
.""!/)%0
Friday, November 6, 2009
![Page 23: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/23.jpg)
Dependency Management
• Organizing components
• Mapping them to targets
Friday, November 6, 2009
![Page 24: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/24.jpg)
Organizing components
• group components: makes them manageable
• two levels: group and license
• Analogy: IKEA catalog
• data is kept in “store repository”
!"#$%&'%(#)*"#$+
!"#$"%&%' ()*&%+&,-".$
Friday, November 6, 2009
![Page 25: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/25.jpg)
Mapping them onto targets
• mapping licenses to targets
• someImes done by an external system
• data kept in “license repository”
!"#$%&$'($)*&"+*,-
!"#$%&$ '()*$+
Friday, November 6, 2009
![Page 26: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/26.jpg)
User Interface
• user retrieves,
• modifies locally and
• stores data on server
Friday, November 6, 2009
![Page 27: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/27.jpg)
Deployment
• list of targets
• list of versions per target
• list of components per version
• management agent
!"#$%&'"()*+"#%,-)%.&
!"#$%& '()*(+%+&
Friday, November 6, 2009
![Page 28: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/28.jpg)
Deployment Repository
!"#$"%&%'()&*(+"%(',*-&'(
.,*-&'/0
1"#$"%&%'/02
3
4
5
!"#$"%&%'()
1"#$"%&%'/0 !"#$"%&%'() !"#$"%&%'(!
1"#$"%&%'/0 !"#$"%&%'(! !"#$"%&%'(*
1"#$"%&%'/1 !"#$"%&%'(*
.,*-&'/61"#$"%&%'/62
3
!"#$"%&%'(*
1"#$"%&%'/0 !"#$"%&%'() !"#$"%&%'(*
Friday, November 6, 2009
![Page 29: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/29.jpg)
Management Agent
• manages life cycle of bundlesBundleContext
• controls package sharing policiesPackageAdmin
• controls starIng/stopping orderStartLevel
• implements a security policyCondi7onalPermissionAdmin
!"#$%"&'($)&%*+,-./'01/'&%"2&)$.$),-$/345&%!"#$%6++$,3)&
7&+&,8&%9:%;&'8$/3%9<=>?3&%=@@A
Friday, November 6, 2009
![Page 30: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/30.jpg)
Management Agent
!"#$%&'(%)$ "!*')+#,-
*'.#"/0#,
"#10)-2#$343(*5
(/"!340)6
!"#"$%!%#&'"$%#&
'('.#
Friday, November 6, 2009
![Page 31: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/31.jpg)
Deployment Admin
• deployment packages
• versioned set of arIfacts
• transacIonal install/update
• fix packages provide deltas
• signing makes them secure
• extensible through resource processors
• AutoConfig defines configuraIon admin data
Friday, November 6, 2009
![Page 32: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/32.jpg)
From dependency to deployment
!"#$%&'%(#)*"#$+
!"#$"%&%' ()*&%+&,-".$ + =,*-%.)%&'%(#)*"#$+
()*&%+& /0-1&'
/%(0#+1%."&'%(#)*"#$+
/0-1&' !"#$"%&%'
Friday, November 6, 2009
![Page 33: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/33.jpg)
Feedback
!"#$"%&'()*+%,+'(+*-!"#$.%/+'(01)%23-'+*%4(56%7*(,851%9%+5%:!"#$.%;21-<*%"=%23-'+*-!"#$9%>3-'+*%+5%7*(,851%:%,2??**-*-!.#$9%&'()*+%,+533*-
!=#".%@A*?B*-%45(%23-'+*,C%151*%4521-!:#".!D#".$E#".$!#".
$"#$E%;21-<*%$"%,+533*-$"#$9$"#.9E$#$$E9#$$
!"#$"%&'()*+%,+'(+*-!"#$.%/+'(01)%23-'+*%4(56%7*(,851%9%+5%:!"#$.%;21-<*%"=%23-'+*-!"#$9%>3-'+*%+5%7*(,851%:%,2??**-*-!.#$9%&'()*+%,+533*-
!"#$%!
&%!'(#)*#(+,-,(&,&$.
-%#+%#/"&"$%/%&!.
"$%&!
012,!.3($
012,!.3($
Friday, November 6, 2009
![Page 34: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/34.jpg)
Demo
Friday, November 6, 2009
![Page 35: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/35.jpg)
Demo
Friday, November 6, 2009
![Page 36: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/36.jpg)
Demo
Friday, November 6, 2009
![Page 37: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/37.jpg)
Demo
Friday, November 6, 2009
![Page 38: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/38.jpg)
Wrapup
• Apache ACE is incubaIng
• Take it for a test-‐drive!
• Looking for contribuIons:
• Apache Felix Karaf
• Maven / Nexus repository
• Kalumet, JEE auto deployment
Friday, November 6, 2009
![Page 39: Dynamic Deployment With Apache Felix](https://reader038.fdocuments.in/reader038/viewer/2022103114/55511837b4c9052d0e8b4da0/html5/thumbnails/39.jpg)
QuesCons?
?
?
?
?
?
??
?
? ??
?
??
?
?
Friday, November 6, 2009