Jive, Dropbox and other integrations!
Jared Ottley
 Integration Engineer!
 Twitter: @jottley!
 Blog: http://jared.ottleys.net!

 Senior Consultant, Alfresco!
 Solutions Engineer, Alfresco !
 QA Engineer, (Linux Lead – OES), Novell!
 Developer/System Analyst, US Federal Courts!

 Maintainer Alfresco PDF Toolkit!
 http://code.google.com/p/alfresco-pdf-toolkit/!
Integration Engineering @ Alfresco!

What do we do
  •  Focused on Developing Integrations with other products and the
     Alfresco Platform!

  •  Develop from the perspective of the customer. !
         •    Donʼt modify the core!
         •    Only use Public APIs!

  •  Share what we learn!
    •     Blog post!
    •     Documentation!
    •     Engineering!
Alfresco – Jive Toolkit
Alfresco – Jive Toolkit!

What is the Alfresco – Jive Toolkit?
  •  A set of pre-built components that allows Jive to store documents
     in Alfresco while still offering all of the same social features as
     “native” Jive documents (commenting, rating, discussions, etc.)!

  •  The initial version of the Toolkit will allow users of Alfresco and/or
     Jive to create “managed” documents in any of the following 3
     ways:!

     •    …By uploading a document to Alfresco, using the Jive UI.!
     •    …By “publishing” an existing document from Alfresco to Jive, using
          Alfrescoʼs Share UI.!
     •    …By “linking” an existing document stored in Alfresco to Jive, using the
          Jive UI.!
Housekeeping


What is required?
  •  Alfresco 3.4.3 and up (NOT Swift/4.0 at this time)!
  •  Jive 5.0.1!

Release Date?
  •  Soon!!
    •    Small Developer Preview!
    •    Incorporate fixes from Preview!
    •    Release to the public!
Design


CMIS Client
  •  CMIS Client on the Jive side!
  •  No need to add custom web scripts on the Alfresco side to handle
     requests.!

  •  We did add:!
    •     request filter!
         •    Identifies calls from Jive!
    •     Authentication Servlet!
         •    Authentication requests from Jive (…explained next…)!
Design


Permissions
  •  The models differ!
  •  No access to user credentials on either side!
  •  Implemented Solution!
    •    Rely on a common backend – LDAP – Let each side manage its own
         permissions (Jive – Community; Alfresco – Node).!
    •    Common user to make calls to Alfresco/Jive!
    •    Encrypted UserID to specify “RunAs” User!
    •    This is still open for change/improvement. We need “real world” feedback
         to validate our approach!
Design


Delete
  •  Jive does not hold a copy of the content, just a reference: the
     cmis:id!
  •  To protect it from from having Orphaned content. Alfresco does not
     allow deletes while content is socialized.!
  •  Accomplished through a policy (beforeDeleteNode) which simply
     throws an exception when a delete is tried!

Copy
  •  We want to allow coping of content in Alfresco, but we donʼt want
     the content to be socialized!
    •    The Jive side only supports a single reference to content!
    •    Jive has no concept of folders (Though it does support tags/categories)!
  •  Disable copying the socialized aspect to new node through a copy
     callback!
    •    getCopyCallback returns DoNothingCopyBehaviourCallback()!
Demo
Alfresco Dropbox Connector!
Alfresco Dropbox Connector!
What is the Connector
  •  A Dropbox client with specific ties into Alfresco!

  •  The initial version will support syncing content (documents and
     folders) to and from a Dropbox account (single or multiple)!
    •    While implemented specifically with Share in mind the implementation is
         primarily exposed through web scripts that can be called independently of
         Share.!
Housekeeping


What is required?
  •  Alfresco 4.0 (aka Swift)!

Release Date?
  •  TBD!
    •    Close to submission for Approval from Dropbox!
    •    Further Testing of Multiple User use case!
Design


 Worked started on 3.4.3!
  •  A couple of hurdles!
    •    No OAuth support!
    •    No Encrypted properties in content Models!
    •    Share customizations to Document Library possible...but not very friendly!

 What we wanted to accomplish!
  •  Sync Documents/Folders from Alfresco to Dropbox!
  •  Sync Document/Folders from Dropbox to Alfresco!
  •  It needs to be simple with as little burden on the user to configure
     and use!
Design


Alfresco is the center of the universe
  •  Alfresco wins in conflicts!
     •    Though we should note when conflicts occur and possibly at some point
          allow for conflict resolution!
  •  If content is deleted in Alfresco is should be deleted in Dropbox.!
  •  If it is deleted in Dropbox it should not be removed from Alfresco!
  •  Targted deletes should be possible!

Dropbox integration is different than social content
management
  •  Social Content Management has multiple users typically publishing
     to single channel (1:1)!
  •  Dropbox will typically have multiple users talking with their own
     Dropbox accounts (1:n)!
Design


Challenges
  •  Closed resource!
       •    No way to add/customize functionality on the service endanger!
  •     Limited Metadata!
  •     API does not currently allow for sharing across accounts!
  •     Rate Limited!
  •     Java API is focused on Android!
       •    It is basically just a wrapper around the REST API!
Design


Oauth
  •  Currently Using Signpost!
  •  Moving to SpringSocial!
    •    SpringSocial is supported in Alfresco (Needed for Social Content
         Publishing)!
  •  Use *New* Encyptyped Content Model properties types to store
     Token Key and Secret!

Apache HTTP Client 4.x
  •  Alfresco 4.0 now uses HTTPClient 4.x.!
    •    This is different than 3.x!
Design


Document Library Customizations
  •  Old way wasn't amp friendly!
    •    Changes were overwriten!
  •  New way allows you to package changes in amp!


  Note: Toolbar customizations aren't yet supported by the new
    DocumentLibrary extension functionality!
Functionality


Sync Content/Folders (Alfresco to Dropbox)
  •  Select a piece of content and send it to Dropbox!
  •  Select a Folder and sync it to Dropbox!
    •    If a folder is synced, all content in that folder will be synced to Dropbox as
         well!
  •  When content/folder is synced to Dropbox it will show Dropbox
     icon as an indicator that it is currently synced to dropbox!
Functionality


Once Sync'd, now what?
  •  Updates to content will sync the change automatically!
  •  Content added to a synced folder will be automatically synced!

Deleting Content
  •  Deletes in Dropbox will not delete the content in Alfresco!
  •  Deletes in Alfresco will be deleted in Dropbox!
  •  Targeted deletes not yet supported!

Copying Content
  •  Copying the content will remove the Dropbox aspect from the
     content ie the copy will no longer be synced to Dropbox!
Functionality


Sync Content/Folders (Dropbox to Alfresco)
  •  No way to trigger changes from Dropbox to Alfresco!
  •  We have to poll or manually sync content!
    •     Manual sync!
         •   Content!
            •  Users can sync updated content that has been synced to Dropbox from Alfresco
               back into the repository!
         •  Folders!
            •  Users can sync updated content that has been synced to Dropbox from Alfresco
               back into the repository in a synced folder!
            •  New Content added to a synced folder on the Dropbox side will be pulled into
               Alfresco!
    •     Scheduled sync!
         •    Not yet implemented!
         •    Will use the same underlying process of the manual sync to provide same functionality!
Implementation


  •  Build the Dropbox Client!
  •  Build the Model!
  •  Dropbox Service (move to an action?)!
    •     Web Scripts!
         •    Why not CMIS?!
    •     Background!
  •  Share UI!
#ToDo


  •  Finish move to SpringSocial!
  •  Dropbox Dashlet!
       •    Allow to setup sync!
       •    Show current quota*!
  •     Multi user Testing!
  •     Unsync !
  •     Targeted delete!
  •     Add when last synced information (when, by whom)!
Demo
Help Wanted!

We are looking for Help
  •  Highly visible projects!
  •  Build your community street cred!
     •    Facebook Integration!
     •    Kofax Release Scripts!
     •    Lotus Quickr Connector!
     •    Microsoft Office Add-ins!
     •    PHP API!

Others are looking for help too!
     •    OpenOffice.org Plugin!
     •    LibreOffice CMIS Plugin!
     •    LibreOffice Alfresco Implementation!

Learn More @ http://wiki.alfresco.com/wiki/Help_Wanted
Q&A
PLAT-5 Jive, Dropbox & Other Integrations

PLAT-5 Jive, Dropbox & Other Integrations

  • 1.
    Jive, Dropbox andother integrations!
  • 2.
    Jared Ottley IntegrationEngineer! Twitter: @jottley! Blog: http://jared.ottleys.net! Senior Consultant, Alfresco! Solutions Engineer, Alfresco ! QA Engineer, (Linux Lead – OES), Novell! Developer/System Analyst, US Federal Courts! Maintainer Alfresco PDF Toolkit! http://code.google.com/p/alfresco-pdf-toolkit/!
  • 3.
    Integration Engineering @Alfresco! What do we do •  Focused on Developing Integrations with other products and the Alfresco Platform! •  Develop from the perspective of the customer. ! •  Donʼt modify the core! •  Only use Public APIs! •  Share what we learn! •  Blog post! •  Documentation! •  Engineering!
  • 4.
  • 5.
    Alfresco – JiveToolkit! What is the Alfresco – Jive Toolkit? •  A set of pre-built components that allows Jive to store documents in Alfresco while still offering all of the same social features as “native” Jive documents (commenting, rating, discussions, etc.)! •  The initial version of the Toolkit will allow users of Alfresco and/or Jive to create “managed” documents in any of the following 3 ways:! •  …By uploading a document to Alfresco, using the Jive UI.! •  …By “publishing” an existing document from Alfresco to Jive, using Alfrescoʼs Share UI.! •  …By “linking” an existing document stored in Alfresco to Jive, using the Jive UI.!
  • 6.
    Housekeeping
 What is required? •  Alfresco 3.4.3 and up (NOT Swift/4.0 at this time)! •  Jive 5.0.1! Release Date? •  Soon!! •  Small Developer Preview! •  Incorporate fixes from Preview! •  Release to the public!
  • 7.
    Design
 CMIS Client •  CMIS Client on the Jive side! •  No need to add custom web scripts on the Alfresco side to handle requests.! •  We did add:! •  request filter! •  Identifies calls from Jive! •  Authentication Servlet! •  Authentication requests from Jive (…explained next…)!
  • 8.
    Design
 Permissions • The models differ! •  No access to user credentials on either side! •  Implemented Solution! •  Rely on a common backend – LDAP – Let each side manage its own permissions (Jive – Community; Alfresco – Node).! •  Common user to make calls to Alfresco/Jive! •  Encrypted UserID to specify “RunAs” User! •  This is still open for change/improvement. We need “real world” feedback to validate our approach!
  • 9.
    Design
 Delete • Jive does not hold a copy of the content, just a reference: the cmis:id! •  To protect it from from having Orphaned content. Alfresco does not allow deletes while content is socialized.! •  Accomplished through a policy (beforeDeleteNode) which simply throws an exception when a delete is tried! Copy •  We want to allow coping of content in Alfresco, but we donʼt want the content to be socialized! •  The Jive side only supports a single reference to content! •  Jive has no concept of folders (Though it does support tags/categories)! •  Disable copying the socialized aspect to new node through a copy callback! •  getCopyCallback returns DoNothingCopyBehaviourCallback()!
  • 10.
  • 11.
  • 12.
    Alfresco Dropbox Connector! Whatis the Connector •  A Dropbox client with specific ties into Alfresco! •  The initial version will support syncing content (documents and folders) to and from a Dropbox account (single or multiple)! •  While implemented specifically with Share in mind the implementation is primarily exposed through web scripts that can be called independently of Share.!
  • 13.
    Housekeeping
 What is required? •  Alfresco 4.0 (aka Swift)! Release Date? •  TBD! •  Close to submission for Approval from Dropbox! •  Further Testing of Multiple User use case!
  • 14.
    Design
 Worked startedon 3.4.3! •  A couple of hurdles! •  No OAuth support! •  No Encrypted properties in content Models! •  Share customizations to Document Library possible...but not very friendly! What we wanted to accomplish! •  Sync Documents/Folders from Alfresco to Dropbox! •  Sync Document/Folders from Dropbox to Alfresco! •  It needs to be simple with as little burden on the user to configure and use!
  • 15.
    Design
 Alfresco is thecenter of the universe •  Alfresco wins in conflicts! •  Though we should note when conflicts occur and possibly at some point allow for conflict resolution! •  If content is deleted in Alfresco is should be deleted in Dropbox.! •  If it is deleted in Dropbox it should not be removed from Alfresco! •  Targted deletes should be possible! Dropbox integration is different than social content management •  Social Content Management has multiple users typically publishing to single channel (1:1)! •  Dropbox will typically have multiple users talking with their own Dropbox accounts (1:n)!
  • 16.
    Design
 Challenges • Closed resource! •  No way to add/customize functionality on the service endanger! •  Limited Metadata! •  API does not currently allow for sharing across accounts! •  Rate Limited! •  Java API is focused on Android! •  It is basically just a wrapper around the REST API!
  • 17.
    Design
 Oauth • Currently Using Signpost! •  Moving to SpringSocial! •  SpringSocial is supported in Alfresco (Needed for Social Content Publishing)! •  Use *New* Encyptyped Content Model properties types to store Token Key and Secret! Apache HTTP Client 4.x •  Alfresco 4.0 now uses HTTPClient 4.x.! •  This is different than 3.x!
  • 18.
    Design
 Document Library Customizations •  Old way wasn't amp friendly! •  Changes were overwriten! •  New way allows you to package changes in amp! Note: Toolbar customizations aren't yet supported by the new DocumentLibrary extension functionality!
  • 19.
    Functionality
 Sync Content/Folders (Alfrescoto Dropbox) •  Select a piece of content and send it to Dropbox! •  Select a Folder and sync it to Dropbox! •  If a folder is synced, all content in that folder will be synced to Dropbox as well! •  When content/folder is synced to Dropbox it will show Dropbox icon as an indicator that it is currently synced to dropbox!
  • 20.
    Functionality
 Once Sync'd, nowwhat? •  Updates to content will sync the change automatically! •  Content added to a synced folder will be automatically synced! Deleting Content •  Deletes in Dropbox will not delete the content in Alfresco! •  Deletes in Alfresco will be deleted in Dropbox! •  Targeted deletes not yet supported! Copying Content •  Copying the content will remove the Dropbox aspect from the content ie the copy will no longer be synced to Dropbox!
  • 21.
    Functionality
 Sync Content/Folders (Dropboxto Alfresco) •  No way to trigger changes from Dropbox to Alfresco! •  We have to poll or manually sync content! •  Manual sync! •  Content! •  Users can sync updated content that has been synced to Dropbox from Alfresco back into the repository! •  Folders! •  Users can sync updated content that has been synced to Dropbox from Alfresco back into the repository in a synced folder! •  New Content added to a synced folder on the Dropbox side will be pulled into Alfresco! •  Scheduled sync! •  Not yet implemented! •  Will use the same underlying process of the manual sync to provide same functionality!
  • 22.
    Implementation
 • Build the Dropbox Client! •  Build the Model! •  Dropbox Service (move to an action?)! •  Web Scripts! •  Why not CMIS?! •  Background! •  Share UI!
  • 23.
    #ToDo
 • Finish move to SpringSocial! •  Dropbox Dashlet! •  Allow to setup sync! •  Show current quota*! •  Multi user Testing! •  Unsync ! •  Targeted delete! •  Add when last synced information (when, by whom)!
  • 24.
  • 25.
    Help Wanted! We arelooking for Help •  Highly visible projects! •  Build your community street cred! •  Facebook Integration! •  Kofax Release Scripts! •  Lotus Quickr Connector! •  Microsoft Office Add-ins! •  PHP API! Others are looking for help too! •  OpenOffice.org Plugin! •  LibreOffice CMIS Plugin! •  LibreOffice Alfresco Implementation! Learn More @ http://wiki.alfresco.com/wiki/Help_Wanted
  • 26.