SlideShare a Scribd company logo
1 of 27
CMIS & IntegrationsJeff Potts
Introduction to CMIS
What is CMIS? Vendor independent API for working with content repositories Specification managed by OASIS Web Services Binding ATOM Pub Binding CMIS Query Language
The Beauty of Presentation Tier REST SOAP Content Services Tier ? ? Enterprise Apps Tier
Client consumer read write Services Domain Model Content Management Interoperability Services Vendor Mapping provider Content Repository CMIS lets you read, search, write, update, delete, version, control, … content and metadata! Meet CMIS
Client Content Repository Client Content Repository Content Repository Content Repository Content Repository Content Repository ,[object Object]
Archival
Virtual Documents
DAM / WCM
Collaborative Content Creation
Portals
Client Application Integration
MashupUse Cases
Document ,[object Object]
 Renditions
 Version HistoryFolder ,[object Object]
 Hierarchy
 FilingDescribed by Type Definitions Relationship ,[object Object]
 Target ObjectPolicy ,[object Object],Types
Object ,[object Object]
 Parent
 Display Name
Queryable
 ControllableProperty ,[object Object]
 Display Name
 Type
 Required

More Related Content

What's hot

Taking Advantage of the SharePoint 2013 REST API
Taking Advantage of the SharePoint 2013 REST APITaking Advantage of the SharePoint 2013 REST API
Taking Advantage of the SharePoint 2013 REST API
Eric Shupps
 

What's hot (9)

Webinar: Building Your First MongoDB App
Webinar: Building Your First MongoDB AppWebinar: Building Your First MongoDB App
Webinar: Building Your First MongoDB App
 
Less css
Less cssLess css
Less css
 
Search as main navigation
Search as main navigationSearch as main navigation
Search as main navigation
 
Quick start guide to java script frameworks for sharepoint apps spsbe-2015
Quick start guide to java script frameworks for sharepoint apps spsbe-2015Quick start guide to java script frameworks for sharepoint apps spsbe-2015
Quick start guide to java script frameworks for sharepoint apps spsbe-2015
 
Taking Advantage of the SharePoint 2013 REST API
Taking Advantage of the SharePoint 2013 REST APITaking Advantage of the SharePoint 2013 REST API
Taking Advantage of the SharePoint 2013 REST API
 
Nuxeo World Session: CMIS - What's Next?
Nuxeo World Session: CMIS - What's Next?Nuxeo World Session: CMIS - What's Next?
Nuxeo World Session: CMIS - What's Next?
 
SharePoint 2013 APIs
SharePoint 2013 APIsSharePoint 2013 APIs
SharePoint 2013 APIs
 
Neos CMS and SEO
Neos CMS and SEONeos CMS and SEO
Neos CMS and SEO
 
Introduction to the SharePoint 2013 REST API
Introduction to the SharePoint 2013 REST APIIntroduction to the SharePoint 2013 REST API
Introduction to the SharePoint 2013 REST API
 

Similar to Alfresco SAUG: CMIS & Integrations

The Magic Revealed: Four Real-World Examples of Using the Client Object Model...
The Magic Revealed: Four Real-World Examples of Using the Client Object Model...The Magic Revealed: Four Real-World Examples of Using the Client Object Model...
The Magic Revealed: Four Real-World Examples of Using the Client Object Model...
SPTechCon
 
Speed up your developments with Symfony2
Speed up your developments with Symfony2Speed up your developments with Symfony2
Speed up your developments with Symfony2
Hugo Hamon
 
GateIn Frameworks
GateIn FrameworksGateIn Frameworks
GateIn Frameworks
jviet
 
Web Technologies - forms and actions
Web Technologies -  forms and actionsWeb Technologies -  forms and actions
Web Technologies - forms and actions
Aren Zomorodian
 
JSR 170: The Key to Unlocking Content Repositories
JSR 170: The Key to Unlocking Content RepositoriesJSR 170: The Key to Unlocking Content Repositories
JSR 170: The Key to Unlocking Content Repositories
Joel Amoussou
 
Java Technology
Java TechnologyJava Technology
Java Technology
ifnu bima
 
Enhance Web Performance
Enhance Web PerformanceEnhance Web Performance
Enhance Web Performance
Adam Lu
 

Similar to Alfresco SAUG: CMIS & Integrations (20)

Good Chemistry: Alfresco, JBoss and CMIS
Good Chemistry: Alfresco, JBoss and CMISGood Chemistry: Alfresco, JBoss and CMIS
Good Chemistry: Alfresco, JBoss and CMIS
 
OpenCMIS Part 1
OpenCMIS Part 1OpenCMIS Part 1
OpenCMIS Part 1
 
Building a friendly .NET SDK to connect to Space
Building a friendly .NET SDK to connect to SpaceBuilding a friendly .NET SDK to connect to Space
Building a friendly .NET SDK to connect to Space
 
Library Project
Library ProjectLibrary Project
Library Project
 
68837.ppt
68837.ppt68837.ppt
68837.ppt
 
The Magic Revealed: Four Real-World Examples of Using the Client Object Model...
The Magic Revealed: Four Real-World Examples of Using the Client Object Model...The Magic Revealed: Four Real-World Examples of Using the Client Object Model...
The Magic Revealed: Four Real-World Examples of Using the Client Object Model...
 
Speed up your developments with Symfony2
Speed up your developments with Symfony2Speed up your developments with Symfony2
Speed up your developments with Symfony2
 
Introduction to Prototype JS Framework
Introduction to Prototype JS FrameworkIntroduction to Prototype JS Framework
Introduction to Prototype JS Framework
 
GateIn Frameworks
GateIn FrameworksGateIn Frameworks
GateIn Frameworks
 
Django tech-talk
Django tech-talkDjango tech-talk
Django tech-talk
 
Active server pages
Active server pagesActive server pages
Active server pages
 
Painless Persistence in a Disconnected World
Painless Persistence in a Disconnected WorldPainless Persistence in a Disconnected World
Painless Persistence in a Disconnected World
 
A mobile web app for Android in 75 minutes
A mobile web app for Android in 75 minutesA mobile web app for Android in 75 minutes
A mobile web app for Android in 75 minutes
 
Web Technologies - forms and actions
Web Technologies -  forms and actionsWeb Technologies -  forms and actions
Web Technologies - forms and actions
 
JSR 170: The Key to Unlocking Content Repositories
JSR 170: The Key to Unlocking Content RepositoriesJSR 170: The Key to Unlocking Content Repositories
JSR 170: The Key to Unlocking Content Repositories
 
Java Technology
Java TechnologyJava Technology
Java Technology
 
Online Meetup: Why should container system / platform builders care about con...
Online Meetup: Why should container system / platform builders care about con...Online Meetup: Why should container system / platform builders care about con...
Online Meetup: Why should container system / platform builders care about con...
 
Enhance Web Performance
Enhance Web PerformanceEnhance Web Performance
Enhance Web Performance
 
Build powerfull and smart web applications with Symfony2
Build powerfull and smart web applications with Symfony2Build powerfull and smart web applications with Symfony2
Build powerfull and smart web applications with Symfony2
 
May 2010 - RestEasy
May 2010 - RestEasyMay 2010 - RestEasy
May 2010 - RestEasy
 

More from Jeff Potts

Alfresco Community Survey 2012 Results
Alfresco Community Survey 2012 ResultsAlfresco Community Survey 2012 Results
Alfresco Community Survey 2012 Results
Jeff Potts
 

More from Jeff Potts (20)

No Docker? No Problem: Automating installation and config with Ansible
No Docker? No Problem: Automating installation and config with AnsibleNo Docker? No Problem: Automating installation and config with Ansible
No Docker? No Problem: Automating installation and config with Ansible
 
Moving From Actions & Behaviors to Microservices
Moving From Actions & Behaviors to MicroservicesMoving From Actions & Behaviors to Microservices
Moving From Actions & Behaviors to Microservices
 
Flexible Permissions Management with ACL Templates
Flexible Permissions Management with ACL TemplatesFlexible Permissions Management with ACL Templates
Flexible Permissions Management with ACL Templates
 
Moving Gigantic Files Into and Out of the Alfresco Repository
Moving Gigantic Files Into and Out of the Alfresco RepositoryMoving Gigantic Files Into and Out of the Alfresco Repository
Moving Gigantic Files Into and Out of the Alfresco Repository
 
Could Alfresco Survive a Zombie Attack?
Could Alfresco Survive a Zombie Attack?Could Alfresco Survive a Zombie Attack?
Could Alfresco Survive a Zombie Attack?
 
The Challenges of Keeping Bees
The Challenges of Keeping BeesThe Challenges of Keeping Bees
The Challenges of Keeping Bees
 
Getting Started With CMIS
Getting Started With CMISGetting Started With CMIS
Getting Started With CMIS
 
Alfresco: What every developer should know
Alfresco: What every developer should knowAlfresco: What every developer should know
Alfresco: What every developer should know
 
CMIS: An Open API for Managing Content
CMIS: An Open API for Managing ContentCMIS: An Open API for Managing Content
CMIS: An Open API for Managing Content
 
Apache Chemistry in Action: Using CMIS and your favorite language to unlock c...
Apache Chemistry in Action: Using CMIS and your favorite language to unlock c...Apache Chemistry in Action: Using CMIS and your favorite language to unlock c...
Apache Chemistry in Action: Using CMIS and your favorite language to unlock c...
 
Alfresco: The Story of How Open Source Disrupted the ECM Market
Alfresco: The Story of How Open Source Disrupted the ECM MarketAlfresco: The Story of How Open Source Disrupted the ECM Market
Alfresco: The Story of How Open Source Disrupted the ECM Market
 
Join the Alfresco community
Join the Alfresco communityJoin the Alfresco community
Join the Alfresco community
 
Intro to the Alfresco Public API
Intro to the Alfresco Public APIIntro to the Alfresco Public API
Intro to the Alfresco Public API
 
Apache Chemistry in Action
Apache Chemistry in ActionApache Chemistry in Action
Apache Chemistry in Action
 
Building Content-Rich Java Apps in the Cloud with the Alfresco API
Building Content-Rich Java Apps in the Cloud with the Alfresco APIBuilding Content-Rich Java Apps in the Cloud with the Alfresco API
Building Content-Rich Java Apps in the Cloud with the Alfresco API
 
Alfresco Community Survey 2012 Results
Alfresco Community Survey 2012 ResultsAlfresco Community Survey 2012 Results
Alfresco Community Survey 2012 Results
 
Getting Started with CMIS
Getting Started with CMISGetting Started with CMIS
Getting Started with CMIS
 
Relational Won't Cut It: Architecting Content Centric Apps
Relational Won't Cut It: Architecting Content Centric AppsRelational Won't Cut It: Architecting Content Centric Apps
Relational Won't Cut It: Architecting Content Centric Apps
 
Alfresco SAUG: State of ECM
Alfresco SAUG: State of ECMAlfresco SAUG: State of ECM
Alfresco SAUG: State of ECM
 
Should You Attend Alfresco Devcon 2011
Should You Attend Alfresco Devcon 2011Should You Attend Alfresco Devcon 2011
Should You Attend Alfresco Devcon 2011
 

Recently uploaded

Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Victor Rentea
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
panagenda
 
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 

Recently uploaded (20)

AI+A11Y 11MAY2024 HYDERBAD GAAD 2024 - HelloA11Y (11 May 2024)
AI+A11Y 11MAY2024 HYDERBAD GAAD 2024 - HelloA11Y (11 May 2024)AI+A11Y 11MAY2024 HYDERBAD GAAD 2024 - HelloA11Y (11 May 2024)
AI+A11Y 11MAY2024 HYDERBAD GAAD 2024 - HelloA11Y (11 May 2024)
 
Stronger Together: Developing an Organizational Strategy for Accessible Desig...
Stronger Together: Developing an Organizational Strategy for Accessible Desig...Stronger Together: Developing an Organizational Strategy for Accessible Desig...
Stronger Together: Developing an Organizational Strategy for Accessible Desig...
 
How to Check CNIC Information Online with Pakdata cf
How to Check CNIC Information Online with Pakdata cfHow to Check CNIC Information Online with Pakdata cf
How to Check CNIC Information Online with Pakdata cf
 
[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
 
Choreo: Empowering the Future of Enterprise Software Engineering
Choreo: Empowering the Future of Enterprise Software EngineeringChoreo: Empowering the Future of Enterprise Software Engineering
Choreo: Empowering the Future of Enterprise Software Engineering
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
Introduction to use of FHIR Documents in ABDM
Introduction to use of FHIR Documents in ABDMIntroduction to use of FHIR Documents in ABDM
Introduction to use of FHIR Documents in ABDM
 
The Zero-ETL Approach: Enhancing Data Agility and Insight
The Zero-ETL Approach: Enhancing Data Agility and InsightThe Zero-ETL Approach: Enhancing Data Agility and Insight
The Zero-ETL Approach: Enhancing Data Agility and Insight
 
Simplifying Mobile A11y Presentation.pptx
Simplifying Mobile A11y Presentation.pptxSimplifying Mobile A11y Presentation.pptx
Simplifying Mobile A11y Presentation.pptx
 
Exploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with MilvusExploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with Milvus
 
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamDEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
 
WSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering DevelopersWSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering Developers
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
WSO2 Micro Integrator for Enterprise Integration in a Decentralized, Microser...
WSO2 Micro Integrator for Enterprise Integration in a Decentralized, Microser...WSO2 Micro Integrator for Enterprise Integration in a Decentralized, Microser...
WSO2 Micro Integrator for Enterprise Integration in a Decentralized, Microser...
 
ChatGPT and Beyond - Elevating DevOps Productivity
ChatGPT and Beyond - Elevating DevOps ProductivityChatGPT and Beyond - Elevating DevOps Productivity
ChatGPT and Beyond - Elevating DevOps Productivity
 
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdfRising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
 
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 

Alfresco SAUG: CMIS & Integrations

  • 3. What is CMIS? Vendor independent API for working with content repositories Specification managed by OASIS Web Services Binding ATOM Pub Binding CMIS Query Language
  • 4. The Beauty of Presentation Tier REST SOAP Content Services Tier ? ? Enterprise Apps Tier
  • 5. Client consumer read write Services Domain Model Content Management Interoperability Services Vendor Mapping provider Content Repository CMIS lets you read, search, write, update, delete, version, control, … content and metadata! Meet CMIS
  • 6.
  • 14.
  • 16.
  • 18.
  • 19.
  • 20.
  • 24.
  • 29.
  • 30.
  • 31. Target TypesPolicy Custom Type Type Definitions
  • 32. Implementations Already Available… Providers Consumers Developed by 30+ ECM Vendors
  • 33. Open Source implementations of CMIS Apache Chemistry is the umbrella project for all CMIS related projects within the ASF OpenCMIS (Java, client and server) cmislib (Python, client) phpclient (PHP, client) DotCMIS (.NET, client)
  • 34. Apache Chemistry started as an incubator project in May 2009 Graduated to a top level project in February 2011. Backed by Adobe, Alfresco, Nuxeo, OpenText, and SAP OpenCMIS is a de-facto reference for CMIS and is also used by the CMIS TC to test new CMIS 1.1 features
  • 35.
  • 37. Full Featured Integration CMIS RESTful APIs JSR-168 Alfresco Web Content Services Java Portal PHP Web Java WEM Custom App Web Quick Start Templates Use case: Home-grown web application in PHP, Surf, Rails, etc. Use case: Full Web Experience Mgmton an all Java stack Use case: internal or external web-based portal Use case: Public website or community site Alfresco Platform
  • 38. CMIS-based integrations to be aware of Drupal CMIS module (http://drupal.org) JBoss CMIS Portlets Liferay CMIS Portlets (?) Flexspaces JM Pascal’s Android client Alfresco iOS Mobile Apps Others?
  • 40. // set up session parameters Map<String, String> parameter = new HashMap<String, String>(); parameter.put(SessionParameter.BINDING_TYPE, BindingType.ATOMPUB.value()); parameter.put(SessionParameter.ATOMPUB_URL, "http://cmis.alfresco.com/service/cmis"); parameter.put(SessionParameter.USER, "admin"); parameter.put(SessionParameter.PASSWORD, "admin"); // get a list of repositories and choose the first one SessionFactory factory = SessionFactoryImpl.newInstance(); List<Repository> repositories = factory.getRepositories(parameter); Session session = repositories.get(0).createSession(); Example: Getting a Session
  • 41. Example: Using the Session Information about the repository: RepositoryInfo ri = session.getRepositoryInfo(); String id = ri.getId(); String name = ri.getName(); Access objects by id or path: CmisObject object1 = session.getObject("1234567890"); CmisObject object2 = session.getObjectByPath("/my/path/doc"); Iterate through a folder: Folder rootFolder = session.getRootFolder(); String rootFolderId = rootFolder.getId(); for(CmisObject object: rootFolder.getChildren()) { String name = object.getName(); if(objectinstanceof Document) { Document doc = (Document) object; long size = doc.getContentStreamLength(); } }
  • 42. Navigation // get root folder Folder root = session.getRootFolder(); String rootFolderName = root.getName(); println "Root folder: ${rootFolderName}" // print root folder children for(CmisObject object: root.getChildren()) { String name = object.getName(); String typeId = object.getType().getId(); String path = object.getPaths().get(0); println "${name} ${typeId} (${path})" // get parents /* for(CmisObject parent: object.getParents()) { String parentName = parent.getName(); println " Parent: ${parentName}" } */ }
  • 43. Paging Folder root = session.getRootFolder(); printList( root.getChildren() ) //printList( root.getChildren().getPage(3) ) //printList( root.getChildren().skipTo(2) ) //printList( root.getChildren().skipTo(2).getPage(3) ) void printList(ItemIterable<CmisObject> list) { list.each { println "${it.name} ${it.type.id}" } long numItems = list.getTotalNumItems(); booleanhasMore = list.getHasMoreItems(); println "--------------------------------------" println "Total number: ${numItems}" println "Has more: ${hasMore}" println "--------------------------------------" }
  • 44. Properties CmisObject object = session.getObjectByPath("/User Homes/florian/Test Folder/MyText"); for(Property<?> property: object.getProperties()) { String propId = property.getId(); String displayName = property.getDefinition().getDisplayName(); String queryName = property.getDefinition().getQueryName(); PropertyTypedatatype = property.getType(); Object value = property.getFirstValue(); println "${displayName}: ${value}" println " Data type: ${datatype}" println " Id: ${propId}" println " Query name: ${queryName}" println "" }
  • 45. Content CmisObject object = session.getObjectByPath("/User Homes/florian/Test Folder/MyText"); if(!(object instanceof Document)) { throw new Exception("Not a document!"); } Document doc = (Document) object; ContentStream content = doc.getContentStream(); if(content == null) { throw new Exception("Document has no content!"); } String filename = content.getFileName(); String mimeType = content.getMimeType(); long length = content.getLength(); InputStream stream = content.getStream(); println "File: ${filename}" println "MIME Type: ${mimeType}" println "Size: ${length} bytes" println "Has stream: " + (stream != null)
  • 46. Query String cql = "SELECT cmis:objectId, cmis:name, cmis:contentStreamLength FROM cmis:document"; ItemIterable<QueryResult> results = session.query(cql, false); //ItemIterable<QueryResult> results = session.query(cql, false).getPage(10); //ItemIterable<QueryResult> results = session.query(cql, false).skipTo(10).getPage(10); for(QueryResult hit: results) { for(PropertyData<?> property: hit.getProperties()) { String queryName = property.getQueryName(); Object value = property.getFirstValue(); println "${queryName}: ${value}" } println "--------------------------------------" }
  • 47. Folders Folder root = session.getRootFolder(); // create a new folder Map<String, Object> properties = new HashMap<String, Object>(); properties.put("cmis:objectTypeId", "cmis:folder"); properties.put("cmis:name", "a new folder"); Folder newFolder = root.createFolder(properties); printProperties(newFolder); // update properties Map<String, Object> updateproperties = new HashMap<String, Object>(); updateproperties.put("cmis:name", "renamed folder"); newFolder.updateProperties(updateproperties); newFolder.refresh(); printProperties(newFolder); // delete folder newFolder.deleteTree(true, UnfileObject.DELETE, true);
  • 48. Documents Folder root = session.getRootFolder(); // create a new document String name = "myNewDocument.txt"; Map<String, Object> properties = new HashMap<String, Object>(); properties.put("cmis:objectTypeId", "cmis:document"); properties.put("cmis:name", name); byte[] content = "Hello World!".getBytes(); InputStream stream = new ByteArrayInputStream(content); ContentStreamcontentStream = new ContentStreamImpl(name, content.length, "text/plain", stream); Document newDoc = root.createDocument(properties, contentStream, VersioningState.MAJOR); printProperties(newDoc); // delete document newDoc.delete(true);
  • 49. Questions? Jeff Potts jeff.potts@alfresco.com http://ecmarchitect.com Twitter/Skype: jeffpotts01