confluence as a platform - atlassian summit 2010
DESCRIPTION
Confluence as a Platform Jonathan Gilbert, AtlassianTRANSCRIPT
11
Confluence as a Platform
Jonathan Gilbert
Senior Developer
Atlassian
22
Agenda• Why Build on Confluence?
• Confluence Advantages
• Example Application Architecture
• Application Audience
• The Road Ahead
33
4
?
?
Why build on Confluence?
4
When to build on Confluence?• When to choose Confluence
• Content based• Collaborative• Confluence already being used by
target audience
• When to avoid Confluence• Structured data storage needs• Specific, unsupported technology
requirements• Core product customisation is required
55
Confluence Advantages• Content Persistence
• Content Discovery
• Integration
• Easy Development
66
Content Persistence
7
BandanaAttachmentsPages & Blogs Comments
7
Content Persistence
8
Backup & RestoreVersioning
BandanaAttachmentsPages & Blogs
Import & Export
Comments
8
Content Discovery
9
Labels
9
Content Discovery
10
Labels
Search Notifications Activity Stream
Feeds
10
Integration
11
Integrated UI Authentication & Authorisation
Users & GroupsExternal Systems IntegrationMicrosoft Office Support
Page Gadget
11
Easy Development• Atlassian Plugin SDK
• Dependency Injection
• Hot Deploy
1212
Easy Development• UI
• Reusable Components• Fully Customisable
• Internationalisation
• Shared Access Layer
1313
Easy Development• Confluence Source Provided
• Huge Development Community• Forums• Online Documentation• Public issue tracking• Tons of examples
• 400+ existing plugins
1414
Architecture• Example Application
15
Feed
s APIREST API
jQuer
XWVel
UIServices
Labe
lP
age
Blo
gs
Use
r A
ttac
Com
Ban
d
Plugin Core
Search & Persistence
15
Search & Persistence
Feed
s
Architecture - Core• Confluence Managers
• Labels
• Bandana
16
REST API
jQuer
XWVel
UIServices
API
Labe
lP
age
Blo
gs
Use
r A
ttac
Com
Ban
d
Plugin Core
16
Architecture - Core
17Search & Persistence
Feed
s
REST API
jQuer
XWVel
UIServices
API
Labe
lP
age
Blo
gs
Use
r A
ttac
Com
Ban
d
Plugin Core
• Dependency Injection – Spring Framework
17
Architecture - Core
18Search & Persistence
Feed
s
REST API
jQuer
XWVel
UIServices
API
Labe
lP
age
Blo
gs
Use
r A
ttac
Com
Ban
d
Plugin Core
• Dependency Injection – Spring Framework
public class ExampleProcessor {• public ExampleProcessor(PageManager pageManager) {• ... }
public void setSpaceManager(SpaceManager spaceManager){ ... }}
18
Architecture - Core
Search & Persistence
Feed
s
REST API
jQuer
XWVel
UIServices
API
Labe
lP
age
Blo
gs
Use
r A
ttac
Com
Ban
d
Plugin Core
• Shared Components - OSGi
19
Architecture - Core
Search & Persistence
Feed
s
REST API
jQuer
XWVel
UIServices
API
Labe
lP
age
Blo
gs
Use
r A
ttac
Com
Ban
d
Plugin Core
• Shared Components - OSGi• Export
<component key="exampleService" name="Example Service" class="com.atlassian.example.impl.DefaultAppService">
<interface>com.atlassian.example.AppService</interface>
</component>
20
Architecture - Core
Search & Persistence
Feed
s
REST API
jQuer
XWVel
UIServices
API
Labe
lP
age
Blo
gs
Use
r A
ttac
Com
Ban
d
Plugin Core
• Shared Components - OSGi• Export
<component key="exampleService" name="Example Service" class="com.atlassian.example.impl.DefaultAppService">
<interface>com.atlassian.example.AppService</interface>
</component>
• Import<component-import name="exampleService" key="exampleService">
<interface>com.atlassian.example.AppService</interface>
</component-import>
21
Architecture - Core
22
• New Features• Commentable objects• Spaced UserStatus• Custom Space Types• Multi-label queries
Search & Persistence
Feed
s
REST API
jQuer
XWVel
UIServices
API
Labe
lP
age
Blo
gs
Use
r A
ttac
Com
Ban
d
Plugin Core
22
Architecture - Core
23
• New Features• Bandana 3.0
• Custom storage contexts• Enumeration of stored keys per context• Custom serialisers
Search & Persistence
Feed
s
REST API
jQuer
XWVel
UIServices
API
Labe
lP
age
Blo
gs
Use
r A
ttac
Com
Ban
d
Plugin Core
23
Architecture – Traditional UI• XWork Actions
• Velocity
• Web Resources
24
REST API
jQuer
Search & Persistence
Feed
s
Services
Labe
lP
age
Blo
gs
Use
r A
ttac
Com
Ban
d
Plugin CoreAPI
XWVel
UI
24
Architecture – Traditional UI
2525
REST API
jQuer
Search & Persistence
Feed
s
Services
Labe
lP
age
Blo
gs
Use
r A
ttac
Com
Ban
d
Plugin CoreAPI
XWVel
UI<xwork name="Example Actions" key="exampleactions"> <package name="example" extends="default" namespace="/example"> <default-interceptor-ref name="defaultStack"/> <action name="doStuff" class="bean:stuffAction"> <result name="input" type="velocity">/example/templates/action/dostuff.vm</result> </action> </package></xwork>
25
Architecture – Traditional UI
26
REST API
jQuer
Search & Persistence
Feed
s
Services
Labe
lP
age
Blo
gs
Use
r A
ttac
Com
Ban
d
Plugin CoreAPI
XWVel
UI<xwork name="Example Actions" key="exampleactions"> <package name="example" extends="default" namespace="/example"> <default-interceptor-ref name="defaultStack"/> <action name="doStuff" class="bean:stuffAction"> <result name="input" type="velocity">/example/templates/action/dostuff.vm</result> </action> </package></xwork>
<web-resource key=“exampleResource"> <transformation extension="txt"> <transformer key=“example" /> </transformation> <resource type="download" name="testTemplate.txt" /></web-resource><web-resource-transformer key="example" class="bean:exampleTransformer" />
26
Labe
lFeed
s
Architecture – REST UI• Client
• JQuery• Atlassian User Interface
• Server• Macros• REST Framework 2.0
• Jersey• Interceptors
27
XWVel
Search & Persistence
Pag
eB
logs
Use
r A
ttac
Com
Ban
d
Services
Plugin CoreAPI
REST API
jQuerUI
27
Architecture – REST UI
28
Labe
lFeed
s
XWVel
Search & Persistence
Pag
eB
logs
Use
r A
ttac
Com
Ban
d
Services
Plugin CoreAPI
REST API
jQuerUI<rest name="Example Rest Service" key="rest-service-example" path="/exampleService" version="1.0“/>
28
Architecture – REST UI
29
Labe
lFeed
s
XWVel
Search & Persistence
Pag
eB
logs
Use
r A
ttac
Com
Ban
d
Services
Plugin CoreAPI
REST API
jQuerUI<rest name="Example Rest Service" key="rest-service-example" path="/exampleService" version="1.0“/>
@XmlRootElement(name = “example")public class ExampleEntity {
• @XmlElement public String name;
• @XmlAttribute public long id;}
{ name: name, id: id}
29
Architecture – REST UI
30
Labe
lFeed
s
XWVel
Search & Persistence
Pag
eB
logs
Use
r A
ttac
Com
Ban
d
Services
Plugin CoreAPI
REST API
jQuerUI<rest name="Example Rest Service" key="rest-service-example" path="/exampleService" version="1.0"/>
@XmlRootElement(name = “example")public class ExampleEntity {
• @XmlElement public String name;
• @XmlAttribute public long id;}
@Path("/example")public class ExampleResource { @GET
• public Response get() {
• ExampleEntity exampleEntity = …
• return Response.ok(exampleEntity).build(); }}
{ name: name, id: id}
30
Architecture – REST UI
31
XWVel
Search & Persistence
Labe
lP
age
Blo
gs
Use
r A
ttac
Com
Ban
d
Plugin CoreAPI
REST API
jQuerUI
Feed
s
Services
• <div id="exampleArea"/>
31
Architecture – REST UI
32
XWVel
Search & Persistence
Labe
lP
age
Blo
gs
Use
r A
ttac
Com
Ban
d
Plugin CoreAPI
REST API
jQuerUI
Feed
s
Services
• <div id="exampleArea"/>
• <div>
• <span>{id}</span><input value="{name}"/>
• </div>
32
Architecture – REST UI
33
XWVel
Search & Persistence
Labe
lP
age
Blo
gs
Use
r A
ttac
Com
Ban
d
Plugin CoreAPI
REST API
jQuerUI
Feed
s
Services
• <div id="exampleArea"/>
• <script type="text/x-template" title="entity-template">
• <div>
• <span>{id}</span><input value="{name}"/>
• </div>
• </script>
33
Architecture – REST UI
34
XWVel
Search & Persistence
Labe
lP
age
Blo
gs
Use
r A
ttac
Com
Ban
d
Plugin CoreAPI
REST API
jQuerUI
Feed
s
Services
• <div id="exampleArea"/>
• <script type="text/x-template" title="entity-template">
• <div>
• <span>{id}</span><input value="{name}"/>
• </div>
• </script>
• jQuery.ajax({
• url: contextPath + '/rest/exampleService/1.0/example',
• type: 'GET',
• dataType: 'json',
• contentType: 'application/json; charset=utf-8',
• success: function(entity) {
•
• }
• });
34
Architecture – REST UI
35
XWVel
Search & Persistence
Labe
lP
age
Blo
gs
Use
r A
ttac
Com
Ban
d
Plugin CoreAPI
REST API
jQuerUI
Feed
s
Services
• <div id="exampleArea"/>
• <script type="text/x-template" title="entity-template">
• <div>
• <span>{id}</span><input value="{name}"/>
• </div>
• </script>
• jQuery.ajax({
• url: contextPath + '/rest/exampleService/1.0/example',
• type: 'GET',
• dataType: 'json',
• contentType: 'application/json; charset=utf-8',
• success: function(entity) {
• AJS.$('#exampleArea').append(AJS.template.load('entity-template').fill(entity).toString());
• }
• });
35
Architecture - Federation• REST
• XML• JSON
• Feeds
• Gadgets• Page Gadget
36
XWVel
Search & Persistence
Labe
lP
age
Blo
gs
Use
r A
ttac
Com
Ban
d
jQuerUI
Plugin CoreAPI
REST API
Feed
s
Services
36
Application Audience• Organisation Specific
• Commercial & Open Source
3737
Organisation Specific• Confluence is already deployed
• No Resource Requirements• Infrastructure Support• Political Support
3838
Commercial & Open Source
39
• Confluence has a huge customer base (22,000)
• Hosting on plugins.atlassian.com• Open or closed source• Free or commercial
• Confluence Blog
• Codegeist
• AtlasCamp
39
The Road Ahead• Full REST APIs
• AppLinks
• Unified Plugin Manager
• Structured Data Storage
40
Summary• Content based & Collaborative Applications will benefit• Confers number of benefits• Development is easy• REST Application Architecture• Audience
• Confluence Rocks for Small, Content-Driven Applications!
4141
Where next?• Sign up to the forums
• http://forums.atlassian.com/
• Download the plugin SDK
• Check out the Atlassian Developer Blog• http://blogs.atlassian.com/developer/
• Check out the Confluence docs• http://confluence.atlassian.com/
4242