Nuxeo 5 Technical Brief Technical
Thierry Delprat - 2006/09/19
Design goals Design
Design goals Design
Flexible deployment
Address different deployment targets:
RCP, JBoss AS ... Full web, full client, client-server
Permit different deployment strategies
Provide several scale-out deployement scenarii
Keep as much as possible of the good Zope/CPS concepts
Modularity and extensibility Schemas and documents types Actions and views management Caching and invalidation
Design goals Design
Make framework usage more accessible
Provide different levels of access Clearly separate each features to have clear API Rely on standards
Leverage the open source Java community
Use « best of breed » existing components Integrate them into plug & play ECM features
Build for the future
Design consequences Design
Nuxeo 5 must rely on standards
Easy access and interoperability Framework perenity
Nuxeo 5 must provide deployment services
Target OSGI and JMX
Nuxeo 5 must provide extension mechanisms
Enterprise Components (replacement for Zope Products) Enable the creation of simple plug-ins
Design consequences Design
Nuxeo 5 must be built on a layered architecture
Choose what to deploy, where Provide multi-level API Share components between the client and the server
Nuxeo 5 integrates existing OSS components
Jackrabbit / Lucene / jBPM /JBoss Rules / JOOConv ...
Nuxeo 5 uses innovatives Java technologies
Make the framework sexy for developpers Make Java and JEE « agile »
Nuxeo Runtime Nuxeo
NXRuntime
One component model
RCP ECM Application Local API
JEE ECM Web Application Remote API
OSGi
Deployment service
Mutualized ECM Component
JBoss (JMX) custom deployer Eclipse RCP (OSGI)
Nuxeo RunTime Eclipse RCP OSGI Rich ECM Client JBoss AS JMX Thin Web 2.0 ECM Client
Localization services
Uses the platform's native features
Nuxeo components are native components
NXRuntime features NXRuntime
Runtime includes an extension points system
Based on the Eclipse model
You can define new extensions points
Let other components extend yours
You can use extension points
Extend or configure via XML descriptors
Extension examples Extension
Pluggable repository Schemas and content types registration Actions and views registration Register event handlers Register transformation plugins
NXRuntime implementation NXRuntime
Pure POJO NXRuntime defines
The component model The runtime services The extension mechanism
NXJBossRuntime and NXEclipseRuntime provide adapters
For starting and stoping services and bundles For using native services
Layers Layers
Nuxeo 5 Layers Nuxeo
Nuxeo 5
UI Layer
Presentations and Views UI Toolkit
Enterprise Components WDK
Logic Layer
Business Logic Generic ECM Services
Platform ECM Core
Storage Layer
Core document management Runtime
Layers Layers
Clear separation of concerns
Document storage handled by the ECM Core
ex : eMail document storage ex : Mail extraction, creation, sending ... ex : WebMail, Send via mail, Mail display ...
All logic handled by « the Logic Layer »
All presentation handled by the « the Presentation Layer »
Enterprise components (ex-Products) may be split in 5 parts
One client part: JEE or RCP One server part: JEE or RCP One storage part: normally only parameters via extensions points
Layers Layers
Each layer provides its own set of API
Core level
Monolithic API Compound API for the services and content objects deployed Compound AJAX API on UI controlers
Logic layer
UI Layer
Each layer leverages NXRuntime
For extensibility For deployment transparency (when needed)
Layers Layers
Nuxeo RCP Components
(Remote) Ajax API
Nuxeo Apogee GUI Local EC APIs
ejb3 cont.
Nuxeo Web Framew ork
Remote EC APIs
Nuxeo Enterprise Components
Local Core API
Remote Core API
Nuxeo ECM Core
Nuxeo RunTime Eclipse RCP OSGI Rich ECM Client JBoss AS JMX Client / Server Thin Web 2.0 ECM Solution ECM Client
(Full client side)
(GUI on the client (Full server logic on the server) side)
ECM Core ECM
ECM Core ECM
Embeddable document management library
For the server For the client
Contains all generic features
Content storage and retrieval Content schemas management Indexing / query (using NXQL) Low level events ACL and contextual security management Versioning
ECM Core features ECM
Document storage
Storage done according to a set of XSD Schemas Uses JCA to have storage adapters
JCR in current default implementation
Security
Stores ACE, ACL and ACP on each document
Storage can be done outside of the document
Provides placeful security checks
ECM Core features ECM
Indexing and query
Provides a technical indexing Provides a NXQL Query interface
Several adapters in the way (BIRT, OLEDB ...) Targets MetaQuery in JCR, SQL, LDAP ...
Event manager
Catches all data-related events Pluggable with JMS
Versionning
Check in / Check out model
Implementation Implementation
Pure POJO
Uses NXRuntime as component model
JCA used to manage the storage adapter JSR 170 (JCR) used as default storage
Apache Jackrabbit by default
XSD is used to define schemas
Schemas are mapped to node types in the JCR
Usage Usage
Extensions points
Declaring schemas Defining types Registering event handlers
ECM storage API for the upper layers 2 API flavors
POJO local API IIOP/SOAP remote API via ejb3
Logical view Logical
POJO Local API JEE Local and Remote API
ECM Core Nuxeo ECM Core API Nx o ECM Services NNx eECM Services ux ECM Services Nuxeo Core (Content Repository) Storage Adapter JCA JCR / Jack Rabbit
Document Object Document
DocumenModels
Inside the Core
Core API
CoreDocuments
NxCore Services NxCore Services NxCore Services
ECM Core
Outside the Core (In and Out)
Core Documents NxCorre Services NxCore Services NxCo e Services Core Documents Nuxeo Runtime NxContent Model
DocumentModel
CoreDocument CoreDocument
A CoreDocument is
A Type name A set of schemas A set of facet (Folderish, Orderable ...)
A CoreDocument has no GUI-related information
Motivations for DocumentModel
Detach document from the Core
Use Serializable objects Reduce network calls
Transmit a consolidated artifact of the content object Transparent Lazy fetching Caching and invalidation management
« Logical Layer » « Logical
The Logic part The
High level ECM services
Audit and logging service Workflow service Comment service Transformation service ...
Provides business logic
The Core provides the structure EC provides the behavior associated to documents
Platform Platform
Integration with JEE Security
AOP Security Interceptors JAAS Integration
Domain
Server
Data Storage Referential Directories User Directories
Domain
Default content hierarchy
Workspace
Workspace Document Repository
Provide very basic content logic over the core Enable multi-cores instances
Folder
Folder
Folder
Audit Trail
Doc
Doc
Logical view Logical
Packaged as separated and logical bundles Leverages JEE 5
Enterprise Components APIs
ECM Enterprise components
No ECM Services NuxNx ECM Services e x ECM Components Nx ECM JEE Services NuxNo ECM Services e x ECM Services
EJB3 SB EJB3 MDB Integrate JAAS
JEE Local and Remote API ECM Core Nuxeo ECM Core API
EJB Power EJB
Enterprise Java Beans component model provides:
Instance pooling State management (Session Bean) Persistance management (Entity Bean) Transaction handling Security propagation Remote call management Deployment and clustering services Session Bean (Stateless ou Statefull): services Entity Bean: Data Object (uses Hibernate) Message Driven Bean: JMS activated component
3 main models of EJBs:
Nuxeo 5 and EJB Nuxeo
We use the new (JEE5) EJB model: EJB 3
Simpler code (one simple class) Uses annotations instead of XML descriptors Almost POJO
Nuxeo 5 uses
Session Beans for Services
Transaction, Security, Pooling, State management, Remote access JMS driven services When DB Mapping is usefull (logging, non-JCR configuration ...)
Message Driven Bean
Entity Beans
Leverage Java Community Leverage
JBPL for workflow and BPEL JSR-94 (JBoss Rules) for rules management JBoss Cache for caching Adobe server and JOOConv for transformation Jena for RDF relations management
What about RCP? What
We already have some Apogee reusable components
Eclipse RCP enforces seperation of GUI vs Logic
Some services will be mutualized
Same API with POJO and EJB implementation
like the Core
Usage of EJB3 embeddable container
We are about to start a new ECM project to build the RCP part
« Presentation Layer » « Presentation
What we need What
A web rendering framework
Template system Reusable widgets Tools to make GUI development easy Action management services Process-driven Form engine
Navigation services
Document presentation services
Context and cache management Glue code between the presentation and the logic layers
Java Server Faces Java
High level Web framework
MVC Model
Bean, Widget, Handler
Handles tree of UI components Even driven navigation Can support differents render kits Complex but plugable life cycle Some IDE tools begins to exists Template mechanism Enforces pure presentation
Facelet template system (like ZPT)
Expression Langage (like TAL)
Java Server Faces Java
We use apache JSF implementation
Apache MyFaces Tomahawk
JMO has already a JSF version of CPSSkins
JBoss Seam JBoss
The missing link between JSF and EJB3
Uses EJB3 as Action Listeners (event handlers) Keep all conversation related objects in cache Context bijection Uses jBPM to define PageFlow Every ActionListener can be accessed via AJAX
Extends JSF to bring real context management
Extends JSF for navigation rules
Integrate JSON and Prototype
Part of Seam is being taken to the JCP for normalization A hype new JBoss framework searching for its killer app
Nuxeo WDK Nuxeo
Handles all generic document-related features
TypeManager
Binds Widgets and Layout to the documents defined in the Core Defines Actions with EL enabled guards and filters Invalidate Seam context Invalidate stalled DocumentModel
ActionManager
Cache Invalidation Management
EL resolver
CPSSkins is on the way
Uses JSF and Seam
AJAX / SOAP Action API
JSF / Facelets
Nuxeo Web Framework JSF Facelets JSF Facelets JSF Facelets
as presentation for context management for Action Listener for ECM UI
Seam
Nuxeo WDK
Acttiion Listeners Ac tion Listeners Ac o n Listeners
Nuxeo WDK
Business Delegates
Business Delegate
Enterprises Components API ECM Enterprises Componeents
to encapsulate remote calls
Enterprise Components Enterprise
Enterprise components have their UI part
JSF Views EJB3 Seam Action Listeners Document view definition (Layout)
By enforcing clear separation of layers inside EC
We will have better reusability We will provide easier customization
Where are we? Where
Build in progress Build
Most infrastructure already exists
Runtime and Core will be released soon The Logic layer is usable The basis of the Web Framework exists We are close to stability at least on the lower layers Unit tests (even if not enought) Automated Build (inside and outside eclipse) Some documentation
We already made several refactoring
We now have
What we have to do What
Write more Enterprise Components
Comments / Relations Workflow Directories ...
Begin work on RCP Finish the Web Layer
Get the best out of Seam and JSF Integrate with the new CPSSkins Deal with JSR 168 (Portlets)
Begin integrating a larger dev team