SlideShare una empresa de Scribd logo
1 de 41
Descargar para leer sin conexión
1




                              Mindquarry
Mindquarry for
Cocoon Users
  Lars Trieloff, Mindquarry
What is Mindquarry    2




                     Mindquarry
What is Mindquarry    2




                     Mindquarry
What is Mindquarry    2




                     Mindquarry
What is Mindquarry    2




                     Mindquarry
What is Mindquarry    2




                     Mindquarry
Short Demo                       3
Mindquarry Collaboration Server:




                                           Mindquarry
   Teams, Files, Tasks and Talk
Mindquarry Desktop Client:
   File Synchronization, Task Management
Live Sites:
   http://www.mindquarry.org
Mindquarry Internals    4
Server based on




                        Mindquarry
   Apache Cocoon 2.2
   Apache Jackrabbit
   Apache Lucene Solr
   Subversion
   Apache Web Server
   mod_perl
   SubethaSMTP
   JRuby
Client based on
   Java 5
   SWT
   Svnkit
Architecture              5
Jetty Web App Container




                          Mindquarry
Architecture              5
Jetty Web App Container




                          Mindquarry
  Apache Cocoon 2.2
Architecture              5
Jetty Web App Container




                          Mindquarry
  Apache Cocoon 2.2


      Team
      Block
Architecture              5
Jetty Web App Container




                          Mindquarry
  Apache Cocoon 2.2


       Team
       Block




Apache Jackrabbit
Architecture              5
Jetty Web App Container




                          Mindquarry
  Apache Cocoon 2.2


       Team
       Block




Apache Jackrabbit

  PostgreSQL
Architecture              5
Jetty Web App Container




                          Mindquarry
  Apache Cocoon 2.2


       Team    DForms
       Block    Block




Apache Jackrabbit

  PostgreSQL
Architecture              5
Jetty Web App Container




                          Mindquarry
  Apache Cocoon 2.2
       Wiki
       Block

       Team    DForms
       Block    Block




Apache Jackrabbit

  PostgreSQL
Architecture              5
Jetty Web App Container




                          Mindquarry
  Apache Cocoon 2.2
       Wiki    Tasks
       Block   Block

       Team    DForms
       Block    Block




Apache Jackrabbit

  PostgreSQL
Architecture                    5
Jetty Web App Container




                                Mindquarry
  Apache Cocoon 2.2
       Wiki    Tasks
       Block   Block

       Team    DForms   Files
       Block    Block   Block




Apache Jackrabbit

  PostgreSQL
Architecture                       5
Jetty Web App Container




                                   Mindquarry
  Apache Cocoon 2.2
       Wiki    Tasks
       Block   Block

       Team    DForms   Files
       Block    Block   Block




Apache Jackrabbit

  PostgreSQL            SVN Repo
Architecture                       5
Jetty Web App Container




                                   Mindquarry
  Apache Cocoon 2.2
       Wiki    Tasks     Talk
       Block   Block    Block

       Team    DForms   Files
       Block    Block   Block




Apache Jackrabbit

  PostgreSQL            SVN Repo
Architecture                                     5
                                   SubethaSMTP
Jetty Web App Container




                                                 Mindquarry
  Apache Cocoon 2.2
       Wiki    Tasks     Talk
       Block   Block    Block

       Team    DForms   Files
       Block    Block   Block




Apache Jackrabbit

  PostgreSQL            SVN Repo
Architecture                                      5
                                   SubethaSMTP
Jetty Web App Container




                                                  Mindquarry
                                    Mail Parser
  Apache Cocoon 2.2
       Wiki    Tasks     Talk
       Block   Block    Block

       Team    DForms   Files
       Block    Block   Block




Apache Jackrabbit

  PostgreSQL            SVN Repo
Architecture                                      5
                                   SubethaSMTP
Jetty Web App Container




                                                  Mindquarry
                                    Mail Parser
  Apache Cocoon 2.2
       Wiki    Tasks     Talk
       Block   Block    Block         REST
                                      Client
       Team    DForms   Files
       Block    Block   Block




Apache Jackrabbit

  PostgreSQL            SVN Repo
Architecture                                      5
                                   SubethaSMTP
Jetty Web App Container




                                                  Mindquarry
                                    Mail Parser
  Apache Cocoon 2.2
       Wiki    Tasks     Talk
       Block   Block    Block         REST
                                      Client
       Team    DForms   Files
       Block    Block   Block




Apache Jackrabbit

  PostgreSQL            SVN Repo
Architecture                                       5
                                     SubethaSMTP
Jetty Web App Container




                                                    Mindquarry
                                      Mail Parser
   Apache Cocoon 2.2
Search   Wiki    Tasks     Talk
Block    Block   Block    Block         REST
                                        Client
         Team    DForms   Files
         Block    Block   Block




Apache Jackrabbit

    PostgreSQL            SVN Repo
Architecture                                        5
                                      SubethaSMTP
Jetty Web App Container




                                                     Mindquarry
                                       Mail Parser
    Apache Cocoon 2.2
Search    Wiki    Tasks     Talk
Block     Block   Block    Block         REST
                                         Client
 Solr     Team    DForms   Files
Servlet   Block    Block   Block




Apache Jackrabbit

    PostgreSQL             SVN Repo
Architecture                                        5
                                               SubethaSMTP
         Jetty Web App Container




                                                              Mindquarry
                                                Mail Parser
             Apache Cocoon 2.2
         Search    Wiki    Tasks     Talk
         Block     Block   Block    Block         REST
                                                  Client
          Solr     Team    DForms   Files
Lucene
         Servlet   Block    Block   Block
 Index



         Apache Jackrabbit

             PostgreSQL             SVN Repo
Lessons learned                          6




                                               Mindquarry
1. Integrating Jackrabbit and Cocoon
2. Using the Servlet Services Architecture
3. Integrating Solr-based search with Cocoon
4. Tuning AJAX Performance
5. Neat REST Tricks in Mindquarry

      Code and Libraries available at
         www.mindquarry.org
Jackrabbit and Cocoon                                            7
Jackrabbit: JCR/JSR-173 Container




                                                                Mindquarry
   Versioned, Typed, Queryable Node Store
   Ideal for document-centric applications
Mindquarry's Enhancements
   com.mindquarry.jcr.xml.source.JCRNodeSource
      an JCR-to-XML mapping
   com.mindquarry.jcr.jackrabbit.xpath.JaxenQueryHandler
      a XPath 1.0 Query handler for Jackrabbit based on Jaxen
Mindquarry's most popular Pitfalls
   Having many small nodes in JCR affects performance
   Mapping Business objects to JCR is no good idea
   There is no easy way to limit the result size of queries
Mapping XML to JCR                                                                                                                                                8




                                                                                                                                                                 Mindquarry
                                     rep:root
                                                                                                       nt:unstructured
                                 /

                                                                                                          xt:element                         xt:text
                                                       nt:folder                            *
                nt:folder
                                                                                                                                          STRING xt:characters
                                                   users
         images
                                                                                      xt:element: child nodes of
                                                                                         type xt:element (XML
                                                                                               elements)
                                                                                                                                          xt:element: child
                                                               nt:file                                                                     properties of type
             nt:file                                                                                                                     STRING (XML attribute)
                                                      alex.saar
     photo154
                                                                                          nt:unstructured

                  Binary Data                                  xt:document
                                                                                            xt:document
                                                     jcr:content
             nt:resource
                                                                                 XML
  jcr:content
                                                               xt:element
                                                        user                                                       <user>
          BINARY jcr:data
                                                                                                                     <name>Alexander Saar</name>
                                                                                                                     <email type=quot;businessquot;>alex@mq.com</name>
       STRING jcr:mimeType                                                                                         </user>

                                                                             xt:element
        DATE jcr:lastModified
                                                                         name
                                                                                                       xt:text
                                                                                                text

                                                                                                          STRING xt:characters = Alexander Saar
                       mix:versionable                                   xt:element
                                                                    email
     nt:resource                                                                                       xt:text
            Later                                                                               text
                                                STRING type = business

                                                                                                         STRING xt:characters = alex@mq.com
xt:versionableresource
Using Servlet Services                                     9
Servlet Services allow running and interacting with




                                                          Mindquarry
arbitrary servlets in the Cocoon quot;Containerquot;
What works great
   Shielding: Conflicting dependencies are no problem
   Inheritance: Define a parent block that handles all
   requests that the child cannot handle
What needs more handwork
   Inheritance of resources, e.g. having a common
   styling resource for all blocks
   Passing complex requests (e.g. including
   authentication) between blocks
   Polymorphy: e.g. a parent block passing sub-requests
   back to the child
Mindquarry's Servlet
                                                                         10
         Services




                                                                         Mindquarry
 Solr                                Tasks
                  Wiki Block
Servlet                              Block


Search    Team           DForms
                                         Files Block        Talk Block
Block     Block           Block


                         Resources
                                                           Usage
                           Block
                                                       Inheritance
Integrating Solr and
                                                          11
         Cocoon
Solr is a REST-based search engine based on Lucene




                                                          Mindquarry
Implemented as a Servlet, easy to embed in Cocoon

                             SolrPost
    TextFilter
                  XSLT
    Generator                Serializer
                                    HTTP POST XML

                               Solr              AJAX
                  Lucene
   Document
                              Servlet            Client
                   Index
                                          HTTP
                                           GET
                                          JSON


 When using with Jackrabbit, Shielding is neccessary
 com.mindquarry.cocoon.TextFilterGenerator
Tuning AJAX
                                                         12
           Performance
Cocoon uses Dojo, which is very powerful




                                                         Mindquarry
And up to 500 kb big, which need to be
   downloaded
   parsed
for every page reload
   better use caching
   and better do not reload
Mindquarry uses following solution
   special AJAX representation of every resource
   customization stylesheet (html2lightbox.xsl)
   Client side: Dojo widget AjaxLink
      replaces every (internal) link with an AJAX call
REST in Mindquarry                                   13
  What means REST?




                                                         Mindquarry
   Everything is a resource and has an URI
   Different representations of a resource possible
       HTML, XML, RSS, JSON, Atom...
   Interaction via GET, PUT, POST, DELETE



    HTTP               HTTP             Session-less
Accept-Headers     Authentication     web applications
HTTP
                  Accept-Headers                                            14
     Specify what content the client can process




                                                                            Mindquarry
        most often HTML, images, but also XML, JSON, etc.

     Definition:
<selector name=quot;RESTquot;
        src=quot;org.apache.cocoon.selection.RegexpHeaderSelectorquot;>

   <header-name>accept</header-name>

   <pattern name=quot;htmlquot;>application/xhtml+xml|text/html|*/*</pattern>

   <pattern name=quot;xmlquot;>text/xml</pattern>

   <pattern name=quot;atomquot;>application/atom.xml</pattern>

   <pattern name=quot;pdfquot;>application/pdf</pattern>

   <pattern name=quot;opmlquot;>text/x-opml</pattern>

   <pattern name=quot;icalquot;>text/calendar</pattern>

   <pattern name=quot;jsonquot;>(text|application)/json</pattern>
</selector>
HTTP
              Accept-Headers                                         15
 Usage Example:




                                                                     Mindquarry
<select type=quot;RESTquot;>
  <when test=quot;jsonquot;>
    <transform src=quot;xslt/json/log2jsonXML.xslquot;>
      <parameter name=quot;baselinkquot; value=quot;/tasks/{1}/{2}quot; />
    </transform>
    <transform type=quot;i18nquot;>
      <parameter name=quot;localequot; value=quot;{request-attr:locale}quot; />
      <parameter name=quot;default-catalogue-idquot; value=quot;mindquarryquot; />
    </transform>
    <serialize type=quot;jsonquot; />
  </when>
  <otherwise>
    <serialize type=quot;xmlquot; />
  </otherwise>
</select>
HTTP
             Accept-Headers                                   16
What to do if my client does not support Accept-




                                                              Mindquarry
Headers?
 <filter>
   <filter-name>HttpHeaderSpoofingFilter</filter-name>
   <display-name>HTTP Header Spoofing Filter</display-name>
   <filter-class>
     com.mindquarry.webapp.servlet.HttpHeaderSpoofingFilter
   </filter-class>
 </filter>


Turns http-*-header request parameters into actual
HTTP headers
  Example usage
  http://localhost:8888/changes?http-accept-
  header=application/json
HTTP
            Authentication                      17
HTTP-Basic or HTTP-Digest Authentication




                                                Mindquarry
  cross client support (even non-interactive)
  no Cookies needed
  no Sessions needed
  But: ugly login window
HTTP
              Authentication                                  18




                                                              Mindquarry
Mindquarry's solution combines
   a servlet filter
   a Dojo (AJAX) widget
<filter>
  <filter-name>MindquarryAuthenticationFilter</filter-name>
  <display-name>
    Mindquarry Authentication filter
  </display-name>
  <filter-class>
    com.mindquarry.user.webapp.AuthenticationFilter
  </filter-class>
  <init-param>
    <param-name>realm</param-name>
    <param-value>Mindquarry Server</param-value>
  </init-param>
</filter>
Session-less
          web applications                       19




                                                 Mindquarry
Mindquarry needs no sessions
   REST architecture
   HTTP Authentication
   Easy to cluster
But Mindquarry uses CForms, which uses
Continuations, which is very close to sessions
A better solution:
   AJAX-based forms
   construct XML document from form values
   send PUT, POST or DELETE afterwards
But not yet implemented
20




                               Mindquarry
  Thank You
    www.mindquarry.com
lars.trieloff@mindquarry.com

Más contenido relacionado

Similar a Mindquarry For Cocoon Users

End-to-end HTML5 APIs - The Geek Gathering 2013
End-to-end HTML5 APIs - The Geek Gathering 2013End-to-end HTML5 APIs - The Geek Gathering 2013
End-to-end HTML5 APIs - The Geek Gathering 2013Alexandre Morgaut
 
CRX 2 Content Application Platform
CRX 2 Content Application PlatformCRX 2 Content Application Platform
CRX 2 Content Application PlatformCédric Hüsler
 
Introduction and hacking OpenStack, Pycon India
Introduction and hacking OpenStack,  Pycon IndiaIntroduction and hacking OpenStack,  Pycon India
Introduction and hacking OpenStack, Pycon IndiaAtul Jha
 
OSGi Service Platform 4.2
OSGi Service Platform 4.2OSGi Service Platform 4.2
OSGi Service Platform 4.2Ilya Katsov
 
State of Developer Tools (WDS09)
State of Developer Tools (WDS09)State of Developer Tools (WDS09)
State of Developer Tools (WDS09)bgalbs
 
Powering the Next Generation Services with Java Platform - Spark IT 2010
Powering the Next Generation Services with Java Platform - Spark IT 2010Powering the Next Generation Services with Java Platform - Spark IT 2010
Powering the Next Generation Services with Java Platform - Spark IT 2010Arun Gupta
 
Content Storage With Apache Jackrabbit
Content Storage With Apache JackrabbitContent Storage With Apache Jackrabbit
Content Storage With Apache JackrabbitJukka Zitting
 
JavaScript Variable Performance
JavaScript Variable PerformanceJavaScript Variable Performance
JavaScript Variable PerformanceNicholas Zakas
 
Shmoocon 2013 - OpenStack Security Brief
Shmoocon 2013 - OpenStack Security BriefShmoocon 2013 - OpenStack Security Brief
Shmoocon 2013 - OpenStack Security Briefopenfly
 
Introduction to Apache Tomcat 7 Presentation
Introduction to Apache Tomcat 7 PresentationIntroduction to Apache Tomcat 7 Presentation
Introduction to Apache Tomcat 7 PresentationTomcat Expert
 
Lithium PHP Meetup 0210
Lithium PHP Meetup 0210Lithium PHP Meetup 0210
Lithium PHP Meetup 0210schreck84
 
SouJava May 2020: Apache Camel 3 - the next generation of enterprise integration
SouJava May 2020: Apache Camel 3 - the next generation of enterprise integrationSouJava May 2020: Apache Camel 3 - the next generation of enterprise integration
SouJava May 2020: Apache Camel 3 - the next generation of enterprise integrationClaus Ibsen
 
Living with SQL and NoSQL at craigslist, a Pragmatic Approach
Living with SQL and NoSQL at craigslist, a Pragmatic ApproachLiving with SQL and NoSQL at craigslist, a Pragmatic Approach
Living with SQL and NoSQL at craigslist, a Pragmatic ApproachJeremy Zawodny
 

Similar a Mindquarry For Cocoon Users (20)

End-to-end HTML5 APIs - The Geek Gathering 2013
End-to-end HTML5 APIs - The Geek Gathering 2013End-to-end HTML5 APIs - The Geek Gathering 2013
End-to-end HTML5 APIs - The Geek Gathering 2013
 
CRX 2 Content Application Platform
CRX 2 Content Application PlatformCRX 2 Content Application Platform
CRX 2 Content Application Platform
 
Introduction and hacking OpenStack, Pycon India
Introduction and hacking OpenStack,  Pycon IndiaIntroduction and hacking OpenStack,  Pycon India
Introduction and hacking OpenStack, Pycon India
 
OSGi Service Platform 4.2
OSGi Service Platform 4.2OSGi Service Platform 4.2
OSGi Service Platform 4.2
 
State of Developer Tools (WDS09)
State of Developer Tools (WDS09)State of Developer Tools (WDS09)
State of Developer Tools (WDS09)
 
Jvm fundamentals
Jvm fundamentalsJvm fundamentals
Jvm fundamentals
 
Devignition 2011
Devignition 2011Devignition 2011
Devignition 2011
 
Powering the Next Generation Services with Java Platform - Spark IT 2010
Powering the Next Generation Services with Java Platform - Spark IT 2010Powering the Next Generation Services with Java Platform - Spark IT 2010
Powering the Next Generation Services with Java Platform - Spark IT 2010
 
Content Storage With Apache Jackrabbit
Content Storage With Apache JackrabbitContent Storage With Apache Jackrabbit
Content Storage With Apache Jackrabbit
 
JavaScript Variable Performance
JavaScript Variable PerformanceJavaScript Variable Performance
JavaScript Variable Performance
 
Shmoocon 2013 - OpenStack Security Brief
Shmoocon 2013 - OpenStack Security BriefShmoocon 2013 - OpenStack Security Brief
Shmoocon 2013 - OpenStack Security Brief
 
Sling demo - JCR Meetup 2008
Sling demo - JCR Meetup 2008Sling demo - JCR Meetup 2008
Sling demo - JCR Meetup 2008
 
Introduction to Apache Tomcat 7 Presentation
Introduction to Apache Tomcat 7 PresentationIntroduction to Apache Tomcat 7 Presentation
Introduction to Apache Tomcat 7 Presentation
 
Deployment de Rails
Deployment de RailsDeployment de Rails
Deployment de Rails
 
JavaOne 2010: OSGI Migrat
JavaOne 2010: OSGI MigratJavaOne 2010: OSGI Migrat
JavaOne 2010: OSGI Migrat
 
Lithium PHP Meetup 0210
Lithium PHP Meetup 0210Lithium PHP Meetup 0210
Lithium PHP Meetup 0210
 
What's new in JSR-283?
What's new in JSR-283?What's new in JSR-283?
What's new in JSR-283?
 
SouJava May 2020: Apache Camel 3 - the next generation of enterprise integration
SouJava May 2020: Apache Camel 3 - the next generation of enterprise integrationSouJava May 2020: Apache Camel 3 - the next generation of enterprise integration
SouJava May 2020: Apache Camel 3 - the next generation of enterprise integration
 
Living with SQL and NoSQL at craigslist, a Pragmatic Approach
Living with SQL and NoSQL at craigslist, a Pragmatic ApproachLiving with SQL and NoSQL at craigslist, a Pragmatic Approach
Living with SQL and NoSQL at craigslist, a Pragmatic Approach
 
Mla2011 final draft
Mla2011 final draftMla2011 final draft
Mla2011 final draft
 

Más de Lars Trieloff

Putting the F in FaaS: Functional Compositional Patterns in a Serverless World
Putting the F in FaaS: Functional Compositional Patterns in a Serverless WorldPutting the F in FaaS: Functional Compositional Patterns in a Serverless World
Putting the F in FaaS: Functional Compositional Patterns in a Serverless WorldLars Trieloff
 
Serverless adventures with AWS Lambda and Clojure
Serverless adventures with AWS Lambda and ClojureServerless adventures with AWS Lambda and Clojure
Serverless adventures with AWS Lambda and ClojureLars Trieloff
 
Data Natives 2015: Predictive Applications are Going to Steal Your Job: this ...
Data Natives 2015: Predictive Applications are Going to Steal Your Job: this ...Data Natives 2015: Predictive Applications are Going to Steal Your Job: this ...
Data Natives 2015: Predictive Applications are Going to Steal Your Job: this ...Lars Trieloff
 
How to get value out of data
How to get value out of dataHow to get value out of data
How to get value out of dataLars Trieloff
 
Smartcon 2015 – Automated Decisions in the Supply Chain
Smartcon 2015 – Automated Decisions in the Supply ChainSmartcon 2015 – Automated Decisions in the Supply Chain
Smartcon 2015 – Automated Decisions in the Supply ChainLars Trieloff
 
Business Reasons for Predictive Applications
Business Reasons for Predictive ApplicationsBusiness Reasons for Predictive Applications
Business Reasons for Predictive ApplicationsLars Trieloff
 
ADDD (Automated Data Driven Decisions) – How To Make it Work
ADDD (Automated Data Driven Decisions) – How To Make it WorkADDD (Automated Data Driven Decisions) – How To Make it Work
ADDD (Automated Data Driven Decisions) – How To Make it WorkLars Trieloff
 
Automated decision making with predictive applications – Big Data Frankfurt
Automated decision making with predictive applications – Big Data FrankfurtAutomated decision making with predictive applications – Big Data Frankfurt
Automated decision making with predictive applications – Big Data FrankfurtLars Trieloff
 
Automated Decision making with Predictive Applications – Big Data Hamburg
Automated Decision making with Predictive Applications – Big Data HamburgAutomated Decision making with Predictive Applications – Big Data Hamburg
Automated Decision making with Predictive Applications – Big Data HamburgLars Trieloff
 
Automated Decision Making with Predictive Applications – Big Data Düsseldorf
Automated Decision Making with Predictive Applications – Big Data DüsseldorfAutomated Decision Making with Predictive Applications – Big Data Düsseldorf
Automated Decision Making with Predictive Applications – Big Data DüsseldorfLars Trieloff
 
Automated decision making with predictive applications – Big Data Brussels
Automated decision making with predictive applications – Big Data BrusselsAutomated decision making with predictive applications – Big Data Brussels
Automated decision making with predictive applications – Big Data BrusselsLars Trieloff
 
Automated decision making with predictive applications – Big Data Amsterdam
Automated decision making with predictive applications – Big Data AmsterdamAutomated decision making with predictive applications – Big Data Amsterdam
Automated decision making with predictive applications – Big Data AmsterdamLars Trieloff
 
Automated decision making using Predictive Applications – Big Data Paris
Automated decision making using Predictive Applications – Big Data ParisAutomated decision making using Predictive Applications – Big Data Paris
Automated decision making using Predictive Applications – Big Data ParisLars Trieloff
 
Automated decision making with big data – Big Data Vienna
Automated decision making with big data – Big Data ViennaAutomated decision making with big data – Big Data Vienna
Automated decision making with big data – Big Data ViennaLars Trieloff
 
Big Data Munich – Decision Automation and Big Data
Big Data Munich – Decision Automation and Big DataBig Data Munich – Decision Automation and Big Data
Big Data Munich – Decision Automation and Big DataLars Trieloff
 
10 Things I Learned About Pricing – Product Camp Berlin 2014
10 Things I Learned About Pricing – Product Camp Berlin 201410 Things I Learned About Pricing – Product Camp Berlin 2014
10 Things I Learned About Pricing – Product Camp Berlin 2014Lars Trieloff
 
Big Data Berlin – Automating Decisions is the Next Frontier for Big Data
Big Data Berlin – Automating Decisions is the Next Frontier for Big DataBig Data Berlin – Automating Decisions is the Next Frontier for Big Data
Big Data Berlin – Automating Decisions is the Next Frontier for Big DataLars Trieloff
 
The DNA of Marketing
The DNA of MarketingThe DNA of Marketing
The DNA of MarketingLars Trieloff
 
Cross community campaigns with CQ5
Cross community campaigns with CQ5Cross community campaigns with CQ5
Cross community campaigns with CQ5Lars Trieloff
 
Mastering the customer engagement ecosystem with CQ5
Mastering the customer engagement ecosystem with CQ5Mastering the customer engagement ecosystem with CQ5
Mastering the customer engagement ecosystem with CQ5Lars Trieloff
 

Más de Lars Trieloff (20)

Putting the F in FaaS: Functional Compositional Patterns in a Serverless World
Putting the F in FaaS: Functional Compositional Patterns in a Serverless WorldPutting the F in FaaS: Functional Compositional Patterns in a Serverless World
Putting the F in FaaS: Functional Compositional Patterns in a Serverless World
 
Serverless adventures with AWS Lambda and Clojure
Serverless adventures with AWS Lambda and ClojureServerless adventures with AWS Lambda and Clojure
Serverless adventures with AWS Lambda and Clojure
 
Data Natives 2015: Predictive Applications are Going to Steal Your Job: this ...
Data Natives 2015: Predictive Applications are Going to Steal Your Job: this ...Data Natives 2015: Predictive Applications are Going to Steal Your Job: this ...
Data Natives 2015: Predictive Applications are Going to Steal Your Job: this ...
 
How to get value out of data
How to get value out of dataHow to get value out of data
How to get value out of data
 
Smartcon 2015 – Automated Decisions in the Supply Chain
Smartcon 2015 – Automated Decisions in the Supply ChainSmartcon 2015 – Automated Decisions in the Supply Chain
Smartcon 2015 – Automated Decisions in the Supply Chain
 
Business Reasons for Predictive Applications
Business Reasons for Predictive ApplicationsBusiness Reasons for Predictive Applications
Business Reasons for Predictive Applications
 
ADDD (Automated Data Driven Decisions) – How To Make it Work
ADDD (Automated Data Driven Decisions) – How To Make it WorkADDD (Automated Data Driven Decisions) – How To Make it Work
ADDD (Automated Data Driven Decisions) – How To Make it Work
 
Automated decision making with predictive applications – Big Data Frankfurt
Automated decision making with predictive applications – Big Data FrankfurtAutomated decision making with predictive applications – Big Data Frankfurt
Automated decision making with predictive applications – Big Data Frankfurt
 
Automated Decision making with Predictive Applications – Big Data Hamburg
Automated Decision making with Predictive Applications – Big Data HamburgAutomated Decision making with Predictive Applications – Big Data Hamburg
Automated Decision making with Predictive Applications – Big Data Hamburg
 
Automated Decision Making with Predictive Applications – Big Data Düsseldorf
Automated Decision Making with Predictive Applications – Big Data DüsseldorfAutomated Decision Making with Predictive Applications – Big Data Düsseldorf
Automated Decision Making with Predictive Applications – Big Data Düsseldorf
 
Automated decision making with predictive applications – Big Data Brussels
Automated decision making with predictive applications – Big Data BrusselsAutomated decision making with predictive applications – Big Data Brussels
Automated decision making with predictive applications – Big Data Brussels
 
Automated decision making with predictive applications – Big Data Amsterdam
Automated decision making with predictive applications – Big Data AmsterdamAutomated decision making with predictive applications – Big Data Amsterdam
Automated decision making with predictive applications – Big Data Amsterdam
 
Automated decision making using Predictive Applications – Big Data Paris
Automated decision making using Predictive Applications – Big Data ParisAutomated decision making using Predictive Applications – Big Data Paris
Automated decision making using Predictive Applications – Big Data Paris
 
Automated decision making with big data – Big Data Vienna
Automated decision making with big data – Big Data ViennaAutomated decision making with big data – Big Data Vienna
Automated decision making with big data – Big Data Vienna
 
Big Data Munich – Decision Automation and Big Data
Big Data Munich – Decision Automation and Big DataBig Data Munich – Decision Automation and Big Data
Big Data Munich – Decision Automation and Big Data
 
10 Things I Learned About Pricing – Product Camp Berlin 2014
10 Things I Learned About Pricing – Product Camp Berlin 201410 Things I Learned About Pricing – Product Camp Berlin 2014
10 Things I Learned About Pricing – Product Camp Berlin 2014
 
Big Data Berlin – Automating Decisions is the Next Frontier for Big Data
Big Data Berlin – Automating Decisions is the Next Frontier for Big DataBig Data Berlin – Automating Decisions is the Next Frontier for Big Data
Big Data Berlin – Automating Decisions is the Next Frontier for Big Data
 
The DNA of Marketing
The DNA of MarketingThe DNA of Marketing
The DNA of Marketing
 
Cross community campaigns with CQ5
Cross community campaigns with CQ5Cross community campaigns with CQ5
Cross community campaigns with CQ5
 
Mastering the customer engagement ecosystem with CQ5
Mastering the customer engagement ecosystem with CQ5Mastering the customer engagement ecosystem with CQ5
Mastering the customer engagement ecosystem with CQ5
 

Último

The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slidevu2urc
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Paola De la Torre
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxKatpro Technologies
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure servicePooja Nehwal
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEarley Information Science
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Allon Mureinik
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Enterprise Knowledge
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...Neo4j
 
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...gurkirankumar98700
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Servicegiselly40
 

Último (20)

The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 

Mindquarry For Cocoon Users

  • 1. 1 Mindquarry Mindquarry for Cocoon Users Lars Trieloff, Mindquarry
  • 2. What is Mindquarry 2 Mindquarry
  • 3. What is Mindquarry 2 Mindquarry
  • 4. What is Mindquarry 2 Mindquarry
  • 5. What is Mindquarry 2 Mindquarry
  • 6. What is Mindquarry 2 Mindquarry
  • 7. Short Demo 3 Mindquarry Collaboration Server: Mindquarry Teams, Files, Tasks and Talk Mindquarry Desktop Client: File Synchronization, Task Management Live Sites: http://www.mindquarry.org
  • 8. Mindquarry Internals 4 Server based on Mindquarry Apache Cocoon 2.2 Apache Jackrabbit Apache Lucene Solr Subversion Apache Web Server mod_perl SubethaSMTP JRuby Client based on Java 5 SWT Svnkit
  • 9. Architecture 5 Jetty Web App Container Mindquarry
  • 10. Architecture 5 Jetty Web App Container Mindquarry Apache Cocoon 2.2
  • 11. Architecture 5 Jetty Web App Container Mindquarry Apache Cocoon 2.2 Team Block
  • 12. Architecture 5 Jetty Web App Container Mindquarry Apache Cocoon 2.2 Team Block Apache Jackrabbit
  • 13. Architecture 5 Jetty Web App Container Mindquarry Apache Cocoon 2.2 Team Block Apache Jackrabbit PostgreSQL
  • 14. Architecture 5 Jetty Web App Container Mindquarry Apache Cocoon 2.2 Team DForms Block Block Apache Jackrabbit PostgreSQL
  • 15. Architecture 5 Jetty Web App Container Mindquarry Apache Cocoon 2.2 Wiki Block Team DForms Block Block Apache Jackrabbit PostgreSQL
  • 16. Architecture 5 Jetty Web App Container Mindquarry Apache Cocoon 2.2 Wiki Tasks Block Block Team DForms Block Block Apache Jackrabbit PostgreSQL
  • 17. Architecture 5 Jetty Web App Container Mindquarry Apache Cocoon 2.2 Wiki Tasks Block Block Team DForms Files Block Block Block Apache Jackrabbit PostgreSQL
  • 18. Architecture 5 Jetty Web App Container Mindquarry Apache Cocoon 2.2 Wiki Tasks Block Block Team DForms Files Block Block Block Apache Jackrabbit PostgreSQL SVN Repo
  • 19. Architecture 5 Jetty Web App Container Mindquarry Apache Cocoon 2.2 Wiki Tasks Talk Block Block Block Team DForms Files Block Block Block Apache Jackrabbit PostgreSQL SVN Repo
  • 20. Architecture 5 SubethaSMTP Jetty Web App Container Mindquarry Apache Cocoon 2.2 Wiki Tasks Talk Block Block Block Team DForms Files Block Block Block Apache Jackrabbit PostgreSQL SVN Repo
  • 21. Architecture 5 SubethaSMTP Jetty Web App Container Mindquarry Mail Parser Apache Cocoon 2.2 Wiki Tasks Talk Block Block Block Team DForms Files Block Block Block Apache Jackrabbit PostgreSQL SVN Repo
  • 22. Architecture 5 SubethaSMTP Jetty Web App Container Mindquarry Mail Parser Apache Cocoon 2.2 Wiki Tasks Talk Block Block Block REST Client Team DForms Files Block Block Block Apache Jackrabbit PostgreSQL SVN Repo
  • 23. Architecture 5 SubethaSMTP Jetty Web App Container Mindquarry Mail Parser Apache Cocoon 2.2 Wiki Tasks Talk Block Block Block REST Client Team DForms Files Block Block Block Apache Jackrabbit PostgreSQL SVN Repo
  • 24. Architecture 5 SubethaSMTP Jetty Web App Container Mindquarry Mail Parser Apache Cocoon 2.2 Search Wiki Tasks Talk Block Block Block Block REST Client Team DForms Files Block Block Block Apache Jackrabbit PostgreSQL SVN Repo
  • 25. Architecture 5 SubethaSMTP Jetty Web App Container Mindquarry Mail Parser Apache Cocoon 2.2 Search Wiki Tasks Talk Block Block Block Block REST Client Solr Team DForms Files Servlet Block Block Block Apache Jackrabbit PostgreSQL SVN Repo
  • 26. Architecture 5 SubethaSMTP Jetty Web App Container Mindquarry Mail Parser Apache Cocoon 2.2 Search Wiki Tasks Talk Block Block Block Block REST Client Solr Team DForms Files Lucene Servlet Block Block Block Index Apache Jackrabbit PostgreSQL SVN Repo
  • 27. Lessons learned 6 Mindquarry 1. Integrating Jackrabbit and Cocoon 2. Using the Servlet Services Architecture 3. Integrating Solr-based search with Cocoon 4. Tuning AJAX Performance 5. Neat REST Tricks in Mindquarry Code and Libraries available at www.mindquarry.org
  • 28. Jackrabbit and Cocoon 7 Jackrabbit: JCR/JSR-173 Container Mindquarry Versioned, Typed, Queryable Node Store Ideal for document-centric applications Mindquarry's Enhancements com.mindquarry.jcr.xml.source.JCRNodeSource an JCR-to-XML mapping com.mindquarry.jcr.jackrabbit.xpath.JaxenQueryHandler a XPath 1.0 Query handler for Jackrabbit based on Jaxen Mindquarry's most popular Pitfalls Having many small nodes in JCR affects performance Mapping Business objects to JCR is no good idea There is no easy way to limit the result size of queries
  • 29. Mapping XML to JCR 8 Mindquarry rep:root nt:unstructured / xt:element xt:text nt:folder * nt:folder STRING xt:characters users images xt:element: child nodes of type xt:element (XML elements) xt:element: child nt:file properties of type nt:file STRING (XML attribute) alex.saar photo154 nt:unstructured Binary Data xt:document xt:document jcr:content nt:resource XML jcr:content xt:element user <user> BINARY jcr:data <name>Alexander Saar</name> <email type=quot;businessquot;>alex@mq.com</name> STRING jcr:mimeType </user> xt:element DATE jcr:lastModified name xt:text text STRING xt:characters = Alexander Saar mix:versionable xt:element email nt:resource xt:text Later text STRING type = business STRING xt:characters = alex@mq.com xt:versionableresource
  • 30. Using Servlet Services 9 Servlet Services allow running and interacting with Mindquarry arbitrary servlets in the Cocoon quot;Containerquot; What works great Shielding: Conflicting dependencies are no problem Inheritance: Define a parent block that handles all requests that the child cannot handle What needs more handwork Inheritance of resources, e.g. having a common styling resource for all blocks Passing complex requests (e.g. including authentication) between blocks Polymorphy: e.g. a parent block passing sub-requests back to the child
  • 31. Mindquarry's Servlet 10 Services Mindquarry Solr Tasks Wiki Block Servlet Block Search Team DForms Files Block Talk Block Block Block Block Resources Usage Block Inheritance
  • 32. Integrating Solr and 11 Cocoon Solr is a REST-based search engine based on Lucene Mindquarry Implemented as a Servlet, easy to embed in Cocoon SolrPost TextFilter XSLT Generator Serializer HTTP POST XML Solr AJAX Lucene Document Servlet Client Index HTTP GET JSON When using with Jackrabbit, Shielding is neccessary com.mindquarry.cocoon.TextFilterGenerator
  • 33. Tuning AJAX 12 Performance Cocoon uses Dojo, which is very powerful Mindquarry And up to 500 kb big, which need to be downloaded parsed for every page reload better use caching and better do not reload Mindquarry uses following solution special AJAX representation of every resource customization stylesheet (html2lightbox.xsl) Client side: Dojo widget AjaxLink replaces every (internal) link with an AJAX call
  • 34. REST in Mindquarry 13 What means REST? Mindquarry Everything is a resource and has an URI Different representations of a resource possible HTML, XML, RSS, JSON, Atom... Interaction via GET, PUT, POST, DELETE HTTP HTTP Session-less Accept-Headers Authentication web applications
  • 35. HTTP Accept-Headers 14 Specify what content the client can process Mindquarry most often HTML, images, but also XML, JSON, etc. Definition: <selector name=quot;RESTquot; src=quot;org.apache.cocoon.selection.RegexpHeaderSelectorquot;> <header-name>accept</header-name> <pattern name=quot;htmlquot;>application/xhtml+xml|text/html|*/*</pattern> <pattern name=quot;xmlquot;>text/xml</pattern> <pattern name=quot;atomquot;>application/atom.xml</pattern> <pattern name=quot;pdfquot;>application/pdf</pattern> <pattern name=quot;opmlquot;>text/x-opml</pattern> <pattern name=quot;icalquot;>text/calendar</pattern> <pattern name=quot;jsonquot;>(text|application)/json</pattern> </selector>
  • 36. HTTP Accept-Headers 15 Usage Example: Mindquarry <select type=quot;RESTquot;> <when test=quot;jsonquot;> <transform src=quot;xslt/json/log2jsonXML.xslquot;> <parameter name=quot;baselinkquot; value=quot;/tasks/{1}/{2}quot; /> </transform> <transform type=quot;i18nquot;> <parameter name=quot;localequot; value=quot;{request-attr:locale}quot; /> <parameter name=quot;default-catalogue-idquot; value=quot;mindquarryquot; /> </transform> <serialize type=quot;jsonquot; /> </when> <otherwise> <serialize type=quot;xmlquot; /> </otherwise> </select>
  • 37. HTTP Accept-Headers 16 What to do if my client does not support Accept- Mindquarry Headers? <filter> <filter-name>HttpHeaderSpoofingFilter</filter-name> <display-name>HTTP Header Spoofing Filter</display-name> <filter-class> com.mindquarry.webapp.servlet.HttpHeaderSpoofingFilter </filter-class> </filter> Turns http-*-header request parameters into actual HTTP headers Example usage http://localhost:8888/changes?http-accept- header=application/json
  • 38. HTTP Authentication 17 HTTP-Basic or HTTP-Digest Authentication Mindquarry cross client support (even non-interactive) no Cookies needed no Sessions needed But: ugly login window
  • 39. HTTP Authentication 18 Mindquarry Mindquarry's solution combines a servlet filter a Dojo (AJAX) widget <filter> <filter-name>MindquarryAuthenticationFilter</filter-name> <display-name> Mindquarry Authentication filter </display-name> <filter-class> com.mindquarry.user.webapp.AuthenticationFilter </filter-class> <init-param> <param-name>realm</param-name> <param-value>Mindquarry Server</param-value> </init-param> </filter>
  • 40. Session-less web applications 19 Mindquarry Mindquarry needs no sessions REST architecture HTTP Authentication Easy to cluster But Mindquarry uses CForms, which uses Continuations, which is very close to sessions A better solution: AJAX-based forms construct XML document from form values send PUT, POST or DELETE afterwards But not yet implemented
  • 41. 20 Mindquarry Thank You www.mindquarry.com lars.trieloff@mindquarry.com