Upload
vincent-massol
View
3.899
Download
0
Embed Size (px)
DESCRIPTION
Presentation given at the Alpes JUG and Mars JUG on 10th and 11th of October 2012. Explains why XWiki is a runtime platform for developing web applications
Citation preview
Copyright (c) Vincent Massol - 2012
XWikiDeveloping simple web applications quickly
Ocober 2012
Friday, October 12, 12
Copyright (c) Vincent Massol - 2012
Agenda
• Architecture
• Developing on XWiki
• Usages
• Pros and cons
• QA
Friday, October 12, 12
Copyright (c) Vincent Massol - 2012
Architecture
Friday, October 12, 12
Copyright (c) Vincent Massol - 2012
XWiki Platform
... for developing (collaborative) web applications
Friday, October 12, 12
Copyright (c) Vincent Massol - 2012
Building an Application
Traditional way
Runtime
Friday, October 12, 12
Copyright (c) Vincent Massol - 2012
Building an Application
XWiki way - Morphing!
RuntimeRuntime
Friday, October 12, 12
Copyright (c) Vincent Massol - 2012
Developing on XWikia.k.a Morphing XWiki
Friday, October 12, 12
Copyright (c) Vincent Massol - 2012
Extensions
Friday, October 12, 12
Copyright (c) Vincent Massol - 2012
Adding Structure
• Ability to associate arbitrary data to any wiki page
• Enable structure in the wiki
• Enable Application development
• == Application wiki or Next Gen Wiki
• Application Within Minutes
Friday, October 12, 12
Copyright (c) Vincent Massol - 2012
Classes - Objects
Friday, October 12, 12
Copyright (c) Vincent Massol - 2012
Class Sheets
• A Document with script to display the content of Object(s) nicely
• Automatic usage if defined in Class Document
• Can be overridden on a page basis if needed
Friday, October 12, 12
Copyright (c) Vincent Massol - 2012
Skinning & Theming
Friday, October 12, 12
Copyright (c) Vincent Massol - 2012
Skin ExtensionsCSS JS
== Grease MonkeyFriday, October 12, 12
Copyright (c) Vincent Massol - 2012
Scripting in Pages (1/2){{groovy}}import groovy.json.*
def url = "https://api.github.com/users/xwiki/repos".toURL().textdef root = new JsonSlurper().parseText(url)
println "|=Project|=Description|=Use Wiki?|=Use Issues?"root.each() { repo -> println "|[[${repo.name}>>http://github.com/xwiki/${repo.name}]]|${repo.description}|${repo.has_wiki}|${repo.has_issues}"}{{/groovy}}
Friday, October 12, 12
Copyright (c) Vincent Massol - 2012
Scripting in Pages (2/2){{velocity}}#set ($xwql = "where doc.content like '%welcome%'")#foreach ($item in $services.query.xwql($xwql).execute()) #if ($request.confirm == "1") #set ($itemDoc = $xwiki.getDocument($item)) $itemDoc.setContent($itemDoc.getContent().replaceAll( "welcome", "bienvenue")) $itemDoc.save("Replaced bienvenue") * [[$item>>$item]] replaced! #else * [[$item>>$item]] #end#end
[[Replace "welcome" by "bienvenue">>?confirm=1]]{{/velocity}}
Friday, October 12, 12
Copyright (c) Vincent Massol - 2012
UI Extensions
{{velocity}}...#foreach($uix in $services.uix.getExtensions( 'org.xwiki.platform.panels.Applications')) #set($params = $uix.getParameters()) * [[image:$params.icon $params.label>>$params.target]]#end...{{/velocity}}
Extension Point
Extension
Result
Friday, October 12, 12
Copyright (c) Vincent Massol - 2012
Wiki Macros
Friday, October 12, 12
Copyright (c) Vincent Massol - 2012
Components@Rolepublic interface Macro{ List<Block> execute();}
@Component@Named("message")@Singletonpublic class MessageMacro implements Macro{ @Inject private Execution execution;
@Inject @Named("box") private Macro boxMacro;
public List<Block> execute() { ... }}
org.xwiki.rendering.internal.macro.message.MessageMacro
META-INF/components.txt
+ Wiki Components!
Friday, October 12, 12
Copyright (c) Vincent Massol - 2012
Usages
Friday, October 12, 12
Copyright (c) Vincent Massol - 2012
Multiple Usages
Friday, October 12, 12
Copyright (c) Vincent Massol - 2012
http://www.xwiki.org/xwiki/bin/view/Main/Screenshots
Friday, October 12, 12
Copyright (c) Vincent Massol - 2012
Long tail of AppsExcel of the
Web
Web’s Swiss army knife
Friday, October 12, 12
Copyright (c) Vincent Massol - 2012
Pros and Cons
Friday, October 12, 12
Copyright (c) Vincent Massol - 2012
Pros• Iterative, Need-based development
• Continuous Delivery
• Work collaboratively on creating applications
• Designers can style while devs create logic
• Works from day one, immediate feedbacks
• Open source and community-based
Friday, October 12, 12
Copyright (c) Vincent Massol - 2012
Cons
• Save code in SCM
• ... but SVN Application, Git Application
• Low integration with existing dev tools
• ... but XEclipse
• ... but WebDAV
• Not an official standard
Friday, October 12, 12
Copyright (c) Vincent Massol - 2012
Getting Started• Download XWiki from xwiki.org
• Ask for a wiki on myxwiki.org
• Non-profit orgs and individuals, no SLA
• Used as a test platform by XWiki devs
• XWiki Cloud
• Free plan (5 users), paid plans
• Contact a company supporting XWiki
Friday, October 12, 12
Copyright (c) Vincent Massol - 2012
Q&A
Me
Friday, October 12, 12
Copyright (c) Vincent Massol - 2012
Vincent [email protected]: vmassolhttp://about.me/vmassol
http://xwiki.orghttp://xwiki.com
Friday, October 12, 12