SlideShare a Scribd company logo
1 of 46
Download to read offline
N Hidden Gems You Didn't Know
Hippo Delivery Tier and Hippo Forge Could Give
Woonsan Ko
Solution Architect
w.ko @ onehippo.com
Sharing Information
● SlideShare.net/woonsan
● WoonsanKo.blogspot.com
OSS
Libraries
Forge
Plugins
Enterprise
Plugins
Around Hippo Delivery Tier
OSS*
Frameworks
More Hippo specific
More
feature-rich
* OSS: Open Source Software
OSS
Libraries
Forge
Plugins
Enterprise
Plugins
Around Hippo Delivery Tier
OSS*
Frameworks
More Hippo specific
More
feature-rich
Hippo
Delivery
Tier
* OSS: Open Source Software
OSS
Libraries
Forge
Plugins
Enterprise
Plugins
Around Hippo Delivery Tier
OSS*
Frameworks
More Hippo specific
More
feature-rich
Hippo
Delivery
Tier
* OSS: Open Source Software
Gems in Hippo Delivery Tier
Gems in Hippo Delivery Tier
#1 Fluent Query
“Made up with fluent style.
Don’t confuse me with the flats!”
Fluent Query
HstRequestContext requestContext = RequestContextProvider.get();
HstQueryManager qm = requestContext.getQueryManager();
HstQuery hstQuery = qm.createQuery(scope, BaseDocument.class);
hstQuery.setOffset(0);
hstQuery.setLimit(10);
hstQuery.addOrderByDescending("my:date");
Filter filter = hstQuery.createFilter();
filter.addContains(".", "hippo");
hstQuery.setFilter(filter);
HstQueryResult result = hstQuery.execute();
Old, Non-Fluent Style
HstRequestContext requestContext = RequestContextProvider.get();
HstQueryManager qm = requestContext.getQueryManager();
HstQuery hstQuery = qm.createQuery(scope, BaseDocument.class);
hstQuery.setOffset(0);
hstQuery.setLimit(10);
hstQuery.addOrderByDescending("my:date");
Filter filter = hstQuery.createFilter();
filter.addContains(".", "hippo");
hstQuery.setFilter(filter);
HstQueryResult result = hstQuery.execute();
Fluent Query
Filter filter = hstQuery.createFilter();
filter.addContains(".", "hippo");
Filter sub1 = hstQuery.createFilter();
sub1.addGreaterOrEqualThan("my:date", date, DAY);
filter.addAndFilter(sub1);
Filter sub2 = hstQuery.createFilter();
sub2.addEqualTo("my:createdBy", "editor1");
filter.addAndFilter(sub2);
Old, Non-Fluent Style
Nested Filter
Fluent Query
* More at https://www.onehippo.org/library/concepts/fluent-search/hst-fluent-search.html
New, Fluent Style
HstQuery hstQuery = HstQueryBuilder.create(scope) // varargs
.ofTypes(BaseDocument.class) // varargs
.where(constraint(".").contains("hippo")) // varargs
.offset(0)
.limit(10)
.orderByDescending("my:date") // varargs
.build();
HstQueryResult result = hstQuery.execute();
Fluent Query
HstQuery hstQuery = HstQueryBuilder.create(scope)
.ofTypes(BaseDocument.class)
.where(constraint(".").contains("hippo"))
.offset(0)
.limit(10)
.orderByDescending("my:date")
.build();
HstQueryResult result = hstQuery.execute();
.where(
and(
constraint(".").contains("hippo"),
constraint("my:date").greaterOrEqualThan(date, DAY),
constraint("my:createdBy").equalTo("editor1")
)
)
* More at https://www.onehippo.org/library/concepts/fluent-search/hst-fluent-search.html
New, Fluent Style
Nested Constraints
Gems in Hippo Delivery Tier
#2 HDC (Hierarchical
Diagnostic Context) API
“Determine performance problems faster!”
HDC API
● Lightweight performance diagnostic tool, for both SITE and CMS.
● Hierarchical Diagnostics Reporting on request processing:
- HstFilter (3011ms): {hostName=www.example.com, uri=/site/, query=null}
`- Pipeline processing (3002ms): {pipeline=null}
|- HstComponentInvokerProfiler (0ms): {method=doBeforeRender, window=main,
component=com.example.components.BaseComponent, ref=r46_r1}
|- HstComponentInvokerProfiler (471ms): {method=doBeforeRender, window=latestjobs,
component=com.example.components.common.LatestItems, ref=r46_r1_r1_r1,
HippoBeanIterationCount=1}
| `- query (466ms):
{statement=//*[(@hippo:paths='a5a24dd3-04a0-4ed1-a59a-ffc960ae69f2') and
(@hippo:availability='live') and ((@jcr:primaryType='hippogogreen:job'))] order by
@hippogogreen:closingdate descending}
...
HDC API
● Lightweight performance diagnostic tool, for both SITE and CMS.
● Hierarchical Diagnostics Reporting on request processing:
- HstFilter (3011ms): {hostName=www.example.com, uri=/site/, query=null}
`- Pipeline processing (3002ms): {pipeline=null}
|- HstComponentInvokerProfiler (0ms): {method=doBeforeRender, window=main,
component=com.example.components.BaseComponent, ref=r46_r1}
|- HstComponentInvokerProfiler (471ms): {method=doBeforeRender, window=latestjobs,
component=com.example.components.common.LatestItems, ref=r46_r1_r1_r1,
HippoBeanIterationCount=1}
| `- query (466ms):
{statement=//*[(@hippo:paths='a5a24dd3-04a0-4ed1-a59a-ffc960ae69f2') and
(@hippo:availability='live') and ((@jcr:primaryType='hippogogreen:job'))] order by
@hippogogreen:closingdate descending}
...
Runtime Configuration
HDC API
● What if I want to measure the performance of my own business logic?
* More at https://www.onehippo.org/library/concepts/request-handling/hst-page-diagnostics.html
// RelatedArticles.java
public void doBeforeRender(HstRequest req, HstResponse res) throws HstComponentException {
// ...
List<Articles> articles = getRelatedArticlesIntelligently();
req.setAtttribute("articles", articles);
// ...
}
HDC API
● What if I want to measure the performance of my own business logic?
* More at https://www.onehippo.org/library/concepts/request-handling/hst-page-diagnostics.html
// RelatedArticles.java
public void doBeforeRender(HstRequest req, HstResponse res) throws HstComponentException {
Task relDocsTask = null;
try {
if (HDC.isStarted()) relDocsTask = HDC.getCurrentTask().startSubtask("relDocs");
List<Articles> articles = getRelatedArticlesIntelligently();
req.setAtttribute("articles", articles);
relDocsTask.setAttribute("count", articles.size());
} finally {
if (relDocsTask != null) relDocsTask.stop();
}
}
HDC API
● What if I want to measure the performance of my own business logic?
// RelatedArticles.java
public void doBeforeRender(HstRequest req, HstResponse res) throws HstComponentException {
Task relDocsTask = null;
try {
if (HDC.isStarted()) relDocsTask = HDC.getCurrentTask().startSubtask("relDocs");
List<Articles> articles = getRelatedArticlesIntelligently();
req.setAtttribute("articles", articles);
relDocsTask.setAttribute("count", articles.size());
} finally {
if (relDocsTask != null) relDocsTask.stop();
}
}
* More at https://www.onehippo.org/library/concepts/request-handling/hst-page-diagnostics.html
|- HstComponentInvokerProfiler (1235ms):
{component=c.e.c.RelatedArticles, ...}
| `- relDocs (1117ms): {count=330}
...
Outcome
Gems in Hippo Delivery Tier
#3 Spring Managed
HstComponent
“Cleaner with Real Dependency Injection!”
Spring Managed HstComponent
package com.example.components;
public class Search extends AbstractSearchComponent {
public void doBeforeRender(HstRequest req, HstResponse res) throws HstComponentException {
// Manual look up the service component, 'catalogServiceBean' ...
CatalogService catService =
HstServices.getComponentManager().getComponent("catalogServiceBean");
request.setAttribute("item", catService.getItem(req.getParameter("pid")));
}
}
Old, Manual Style
Spring Managed HstComponent
package com.example.components;
@Component // for auto-scanning!
@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) // "prototype" always!
@Service("com.example.components.Search") // FQCN as @Service!
public class Search extends AbstractSearchComponent {
@Autowired
private CatalogService catService;
public void doBeforeRender(HstRequest req, HstResponse res) throws HstComponentException {
request.setAttribute("item", catService.getItem(req.getParameter("pid")));
}
}
New, Auto-wiring Style
● Annotation scanning on Spring managed HST Components
<!-- e.g. site/src/main/resources/META-INF/hst-assembly/overrides/base.xml-->
<!-- (HST)Components Annotation Scanning -->
<context:component-scan base-package="com.example.components" />
Spring Managed HstComponent
* More at https://www.onehippo.org/library/concepts/web-application/spring-managed-hst-components.html
● Special Attentions!
○ Always set @Scope to prototype!
○ Always set @Service to the FQCN of the component class!
Gems in Hippo Delivery Tier
#4 Asynchronous Rendering
“Better Render Later!”
● Client-side Asynchronous Rendering
○ E.g. A component accessing external services.
○ AJAX code, retrieving HST Component Rendering URL
● Server-side Asynchronous Rendering
○ E.g. A non-cacheable component in the server side.
○ ESI or SSI, retrieving HST Component Rendering URL
Asynchronous Component Rendering
<<header>>
<<footer>>
<<left>> <<content>>
<Store Locator>
● Client-side Asynchronous Component Rendering
○ @hst:async = true
Asynchronous Component Rendering
Browser
HST
Container
<<header>>
<<footer>>
<<left>> <<content>>
<Store Locator>
(1) HST Page Request
(5) HST Component
Rendering URL
(2) Default Pipeline
(6) HST Component
Rendering Pipeline
(3) Page(4) AJAX script seeded
(8) Component
Window Response
(7) Component
Window
● Server-side Asynchronous Component Rendering
○ @hst:async = true, @hst:asyncmode = "esi"
Asynchronous Component Rendering
* More at https://www.onehippo.org/library/concepts/component-development/asynchronous-hst-components-and-containers.html
Browser
HST
Container
(1) HST Page Request
<<header>>
<<footer>>
<<left>> <<content>>
<Store Locator>
(3) Default Pipeline
Page
Cache
(2) Get Page
ESI
Processor
(4) Page
(6) HST Component
Rendering Pipeline
(7) Component
Window
(5) Put Page
(8) Dynamically
Aggregated Page
HST ESI Processor
Browser ESI
Processor Dispatchable
local path
Page
Cache
<html>
<h1>Hello, World!</h1>
<!--esi:include src="/special..." -->
</html>
<div>Hi ${user}! Here’s a
special deal for you!</div>
<html>
<h1>Hello, World!</h1>
</html>
<div>Hi Hippo! Here’s a
special deal for you!</div>
HST HST
Component
● HST ESI Processor dispatches to . . .
a Component Rendering URL or Local URI Path (Servlet/JSP).
○ Note: HST ESI does NOT support Remote URLs for simplicity!
HST ESI Processor
● What if I want to include remote URLs using ESI tags?
○ APA Reverse Proxy Project:
■ Java Servlet or Filter library as Reverse Proxy
■ portals.apache.org/applications/webcontent2/reverse-proxy-module.html
○ Map Local Path to Remote URLs!
■ e.g. /site/products/ → http://example.com/products/ ,
/site/products/123 → http://example.com/products/123
* More at https://www.onehippo.org/library/concepts/web-application/hst-2-edge-side-includes-support.html
<!--esi:include src="/site/products/123" -->
Gems in Hippo Forge Projects
Gems in Hippo Forge Projects
#1 Integration with
External Content
“Link Document to External Content with Metadata
(e.g. in CMIS, Commerce, DB, … ).”
Integration with External Content
● External Document Picker Forge Plugin:
○ Concept: Separation of UI and Data Service.
■ UI Plugin
● UI for searching and displaying of external document item(s), retrieved by
ExternalDocumentServiceFacade component.
■ ExternalDocumentServiceFacade Data Service interface
● Configured for the UI Plugin; Invoked by the UI Plugin.
● All Data Handling under the hood against backend.
○ Title, icon and description for each external document.
○ Store metadata of selected item(s) into Hippo document.
* More at http://exdocpickerbase.forge.onehippo.org/
Integration with External Content
Integration with External Content
ExternalDocumentServiceFacade
is responsible for data to
display each item.
Integration with External Content
Again,
ExternalDocumentServiceFacade
is responsible for data to
display each selection.
Gems in Hippo Forge Projects
#2 Content EXIM
“Import Document / Binary Data to Hippo!”
Content EXIM
● Lightweight Library to EXport/IMport
Documents and Binaries to/from JSON or XML
● Uses Standard Hippo Workflow/Gallery APIs.
● Groovy Updater as primary execution engine
● Example Groovy Scripts to start with:
○ to export/import documents and image/assets.
○ to create documents from CSV.
○ to create image sets from image files.
* More at http://content-exim.forge.onehippo.org/
Content EXIM
Content EXIM
* More at http://content-exim.forge.onehippo.org/
Gems in Hippo Forge Projects
#3 Apache Camel Integration
“Synchronize Content with External System
through Enterprise Message Bus!”
Apache Camel Integration
● An example use case
Apache Camel Integration
● Apache Camel (camel.apache.org):
○ Lightweight framework for the Enterprise Integration Patterns
○ Production-ready components:
■ JMS, ActiveMQ, Kafka, File, SFTP, HTTP4, SQL, NoSQLs, ElasticSearch, XMPP, . . .
● Apache Camel Integration Forge:
○ Provides a Camel Component to consume Hippo Events (from Hippo Event Bus).
■ Component URI: hippoevent:
* More at http://camel-hippoevt.forge.onehippo.org/
<camelContext>
<route id="Route-HippoEventBus-to-Queue">
<from uri="hippoevent:?category=workflow&amp;action=publish,depublish" />
<convertBodyTo type="java.lang.String" />
<to uri="activemq:queue:hippo" />
</route>
</camelContext>
Gems in Hippo Forge Projects
#4 Spring Security Integration
“Secure My Services through JWT, SAML or OAuth!”
Spring Security Integration
● Spring Security Framework:
○ Powerful and highly customizable authentication and access-control framework.
○ Basic Auth, Spring Security SAML, Spring Security OAuth, etc.
● HST Spring Security Framework Integration Forge adds:
○ Hippo Authentication Provider with Hippo UserDetailsService.
○ Spring Security Valve injected in HST pipeline.
■ Sitemap Item with @hst:authenticated, @hst:roles, @hst:users.
■ JAX-RS Services with JEE Security Annotations such as @RolesAllowed.
* More at http://hst-springsec.forge.onehippo.org/
OSS
Libraries
Forge
Plugins
Enterprise
Plugins
Gems in Summary
OSS*
Frameworks
More Hippo specific
More
feature-rich
Hippo
Delivery
Tier
* OSS: Open Source Software
OSS
Libraries
Forge
Plugins
Enterprise
Plugins
Gems in Summary
OSS*
Frameworks
More Hippo specific
More
feature-rich
Hippo
Delivery
Tier
● Delivery Tier
○ HST Fluent Query
○ HDC
○ Spring Managed Components
○ Async Components
■ HST ESI Processor
* OSS: Open Source Software
OSS
Libraries
Forge
Plugins
Enterprise
Plugins
Gems in Summary
OSS*
Frameworks
More Hippo specific
More
feature-rich
Hippo
Delivery
Tier
● Delivery Tier
○ HST Fluent Query
○ HDC
○ Spring Managed Components
○ Async Components
■ HST ESI Processor
● Forges
○ External Document Picker
○ Content EXIM
○ Apache Camel Integration
○ Spring Security Integration
* OSS: Open Source Software
Stay in Touch
NORTH AMERICA
71 Summer Street
Boston, MA 02110
USA
EUROPE
Oosteinde 11
1017 WT Amsterdam
The Netherlands
CALL US
+31 20 522 44 66
+44 20 35 14 99 60
+49 69 80 88 40 67
+1 877 414 47 76
WEB & EMAIL
www.onehippo.com
sales@onehippo.com
● SlideShare.net/woonsan
● WoonsanKo.blogspot.com

More Related Content

What's hot

How to Scrap Any Website's content using ScrapyTutorial of How to scrape (cra...
How to Scrap Any Website's content using ScrapyTutorial of How to scrape (cra...How to Scrap Any Website's content using ScrapyTutorial of How to scrape (cra...
How to Scrap Any Website's content using ScrapyTutorial of How to scrape (cra...Anton
 
Downloading the internet with Python + Scrapy
Downloading the internet with Python + ScrapyDownloading the internet with Python + Scrapy
Downloading the internet with Python + ScrapyErin Shellman
 
Web Scraping with Python
Web Scraping with PythonWeb Scraping with Python
Web Scraping with PythonPaul Schreiber
 
第一回MongoDBソースコードリーディング
第一回MongoDBソースコードリーディング第一回MongoDBソースコードリーディング
第一回MongoDBソースコードリーディングnobu_k
 
연구자 및 교육자를 위한 계산 및 분석 플랫폼 설계 - PyCon KR 2015
연구자 및 교육자를 위한 계산 및 분석 플랫폼 설계 - PyCon KR 2015연구자 및 교육자를 위한 계산 및 분석 플랫폼 설계 - PyCon KR 2015
연구자 및 교육자를 위한 계산 및 분석 플랫폼 설계 - PyCon KR 2015Jeongkyu Shin
 
HTML5 tutorial: canvas, offfline & sockets
HTML5 tutorial: canvas, offfline & socketsHTML5 tutorial: canvas, offfline & sockets
HTML5 tutorial: canvas, offfline & socketsRemy Sharp
 
Presto in Treasure Data (presented at db tech showcase Sapporo 2015)
Presto in Treasure Data (presented at db tech showcase Sapporo 2015)Presto in Treasure Data (presented at db tech showcase Sapporo 2015)
Presto in Treasure Data (presented at db tech showcase Sapporo 2015)Mitsunori Komatsu
 
How to scraping content from web for location-based mobile app.
How to scraping content from web for location-based mobile app.How to scraping content from web for location-based mobile app.
How to scraping content from web for location-based mobile app.Diep Nguyen
 
CouchDB Mobile - From Couch to 5K in 1 Hour
CouchDB Mobile - From Couch to 5K in 1 HourCouchDB Mobile - From Couch to 5K in 1 Hour
CouchDB Mobile - From Couch to 5K in 1 HourPeter Friese
 
WorkFlow: An Inquiry Into Productivity by Timothy Bolton
WorkFlow:  An Inquiry Into Productivity by Timothy BoltonWorkFlow:  An Inquiry Into Productivity by Timothy Bolton
WorkFlow: An Inquiry Into Productivity by Timothy BoltonMiva
 
Replacing Oracle with MongoDB for a templating application at the Bavarian go...
Replacing Oracle with MongoDB for a templating application at the Bavarian go...Replacing Oracle with MongoDB for a templating application at the Bavarian go...
Replacing Oracle with MongoDB for a templating application at the Bavarian go...Comsysto Reply GmbH
 
MongoDB Munich 2012: MongoDB for official documents in Bavaria
MongoDB Munich 2012: MongoDB for official documents in BavariaMongoDB Munich 2012: MongoDB for official documents in Bavaria
MongoDB Munich 2012: MongoDB for official documents in BavariaMongoDB
 

What's hot (19)

Web Scrapping with Python
Web Scrapping with PythonWeb Scrapping with Python
Web Scrapping with Python
 
How to Scrap Any Website's content using ScrapyTutorial of How to scrape (cra...
How to Scrap Any Website's content using ScrapyTutorial of How to scrape (cra...How to Scrap Any Website's content using ScrapyTutorial of How to scrape (cra...
How to Scrap Any Website's content using ScrapyTutorial of How to scrape (cra...
 
Downloading the internet with Python + Scrapy
Downloading the internet with Python + ScrapyDownloading the internet with Python + Scrapy
Downloading the internet with Python + Scrapy
 
Web Scraping with Python
Web Scraping with PythonWeb Scraping with Python
Web Scraping with Python
 
Pydata-Python tools for webscraping
Pydata-Python tools for webscrapingPydata-Python tools for webscraping
Pydata-Python tools for webscraping
 
ElasticSearch
ElasticSearchElasticSearch
ElasticSearch
 
第一回MongoDBソースコードリーディング
第一回MongoDBソースコードリーディング第一回MongoDBソースコードリーディング
第一回MongoDBソースコードリーディング
 
연구자 및 교육자를 위한 계산 및 분석 플랫폼 설계 - PyCon KR 2015
연구자 및 교육자를 위한 계산 및 분석 플랫폼 설계 - PyCon KR 2015연구자 및 교육자를 위한 계산 및 분석 플랫폼 설계 - PyCon KR 2015
연구자 및 교육자를 위한 계산 및 분석 플랫폼 설계 - PyCon KR 2015
 
Selenium&amp;scrapy
Selenium&amp;scrapySelenium&amp;scrapy
Selenium&amp;scrapy
 
HTML5 tutorial: canvas, offfline & sockets
HTML5 tutorial: canvas, offfline & socketsHTML5 tutorial: canvas, offfline & sockets
HTML5 tutorial: canvas, offfline & sockets
 
Presto in Treasure Data (presented at db tech showcase Sapporo 2015)
Presto in Treasure Data (presented at db tech showcase Sapporo 2015)Presto in Treasure Data (presented at db tech showcase Sapporo 2015)
Presto in Treasure Data (presented at db tech showcase Sapporo 2015)
 
How to scraping content from web for location-based mobile app.
How to scraping content from web for location-based mobile app.How to scraping content from web for location-based mobile app.
How to scraping content from web for location-based mobile app.
 
Elk stack @inbot
Elk stack @inbotElk stack @inbot
Elk stack @inbot
 
CouchDB Mobile - From Couch to 5K in 1 Hour
CouchDB Mobile - From Couch to 5K in 1 HourCouchDB Mobile - From Couch to 5K in 1 Hour
CouchDB Mobile - From Couch to 5K in 1 Hour
 
Introducing CouchDB
Introducing CouchDBIntroducing CouchDB
Introducing CouchDB
 
Lumberjack XPath 101
Lumberjack XPath 101Lumberjack XPath 101
Lumberjack XPath 101
 
WorkFlow: An Inquiry Into Productivity by Timothy Bolton
WorkFlow:  An Inquiry Into Productivity by Timothy BoltonWorkFlow:  An Inquiry Into Productivity by Timothy Bolton
WorkFlow: An Inquiry Into Productivity by Timothy Bolton
 
Replacing Oracle with MongoDB for a templating application at the Bavarian go...
Replacing Oracle with MongoDB for a templating application at the Bavarian go...Replacing Oracle with MongoDB for a templating application at the Bavarian go...
Replacing Oracle with MongoDB for a templating application at the Bavarian go...
 
MongoDB Munich 2012: MongoDB for official documents in Bavaria
MongoDB Munich 2012: MongoDB for official documents in BavariaMongoDB Munich 2012: MongoDB for official documents in Bavaria
MongoDB Munich 2012: MongoDB for official documents in Bavaria
 

Similar to N hidden gems you didn't know hippo delivery tier and hippo (forge) could give

Azure Functions @ global azure day 2017
Azure Functions  @ global azure day 2017Azure Functions  @ global azure day 2017
Azure Functions @ global azure day 2017Sean Feldman
 
Make BDD great again
Make BDD great againMake BDD great again
Make BDD great againYana Gusti
 
Primefaces Nextgen Lju
Primefaces Nextgen LjuPrimefaces Nextgen Lju
Primefaces Nextgen LjuSkills Matter
 
Primefaces Nextgen Lju
Primefaces Nextgen LjuPrimefaces Nextgen Lju
Primefaces Nextgen LjuSkills Matter
 
nodejs_at_a_glance.ppt
nodejs_at_a_glance.pptnodejs_at_a_glance.ppt
nodejs_at_a_glance.pptWalaSidhom1
 
Using the new WordPress REST API
Using the new WordPress REST APIUsing the new WordPress REST API
Using the new WordPress REST APICaldera Labs
 
Hyperproductive JSF 2.0 @ JavaOne Brazil 2010
Hyperproductive JSF 2.0 @ JavaOne Brazil 2010Hyperproductive JSF 2.0 @ JavaOne Brazil 2010
Hyperproductive JSF 2.0 @ JavaOne Brazil 2010Arun Gupta
 
RichFaces: rich:* component library
RichFaces: rich:* component libraryRichFaces: rich:* component library
RichFaces: rich:* component libraryMax Katz
 
Angular - Improve Runtime performance 2019
Angular - Improve Runtime performance 2019Angular - Improve Runtime performance 2019
Angular - Improve Runtime performance 2019Eliran Eliassy
 
Diving into HHVM Extensions (php[tek] 2016)
Diving into HHVM Extensions (php[tek] 2016)Diving into HHVM Extensions (php[tek] 2016)
Diving into HHVM Extensions (php[tek] 2016)James Titcumb
 
Creating a Smooth Development Workflow for High-Quality Modular Open-Source P...
Creating a Smooth Development Workflow for High-Quality Modular Open-Source P...Creating a Smooth Development Workflow for High-Quality Modular Open-Source P...
Creating a Smooth Development Workflow for High-Quality Modular Open-Source P...Pantheon
 
Unit Testing from Setup to Deployment
Unit Testing from Setup to DeploymentUnit Testing from Setup to Deployment
Unit Testing from Setup to DeploymentMark Niebergall
 
Saving Time And Effort With QuickBase Api - Sergio Haro
Saving Time And Effort With QuickBase Api - Sergio HaroSaving Time And Effort With QuickBase Api - Sergio Haro
Saving Time And Effort With QuickBase Api - Sergio HaroQuickBase, Inc.
 
HTML5: huh, what is it good for?
HTML5: huh, what is it good for?HTML5: huh, what is it good for?
HTML5: huh, what is it good for?Remy Sharp
 
Spark IT 2011 - Simplified Web Development using Java Server Faces 2.0
Spark IT 2011 - Simplified Web Development using Java Server Faces 2.0Spark IT 2011 - Simplified Web Development using Java Server Faces 2.0
Spark IT 2011 - Simplified Web Development using Java Server Faces 2.0Arun Gupta
 
GraphConnect 2014 SF: From Zero to Graph in 120: Scale
GraphConnect 2014 SF: From Zero to Graph in 120: ScaleGraphConnect 2014 SF: From Zero to Graph in 120: Scale
GraphConnect 2014 SF: From Zero to Graph in 120: ScaleNeo4j
 
Serverless and Servicefull Applications - Where Microservices complements Ser...
Serverless and Servicefull Applications - Where Microservices complements Ser...Serverless and Servicefull Applications - Where Microservices complements Ser...
Serverless and Servicefull Applications - Where Microservices complements Ser...Red Hat Developers
 
Advanced technic for OS upgrading in 3 minutes
Advanced technic for OS upgrading in 3 minutesAdvanced technic for OS upgrading in 3 minutes
Advanced technic for OS upgrading in 3 minutesHiroshi SHIBATA
 

Similar to N hidden gems you didn't know hippo delivery tier and hippo (forge) could give (20)

Azure Functions @ global azure day 2017
Azure Functions  @ global azure day 2017Azure Functions  @ global azure day 2017
Azure Functions @ global azure day 2017
 
Make BDD great again
Make BDD great againMake BDD great again
Make BDD great again
 
Primefaces Nextgen Lju
Primefaces Nextgen LjuPrimefaces Nextgen Lju
Primefaces Nextgen Lju
 
Primefaces Nextgen Lju
Primefaces Nextgen LjuPrimefaces Nextgen Lju
Primefaces Nextgen Lju
 
nodejs_at_a_glance.ppt
nodejs_at_a_glance.pptnodejs_at_a_glance.ppt
nodejs_at_a_glance.ppt
 
Using the new WordPress REST API
Using the new WordPress REST APIUsing the new WordPress REST API
Using the new WordPress REST API
 
Hyperproductive JSF 2.0 @ JavaOne Brazil 2010
Hyperproductive JSF 2.0 @ JavaOne Brazil 2010Hyperproductive JSF 2.0 @ JavaOne Brazil 2010
Hyperproductive JSF 2.0 @ JavaOne Brazil 2010
 
RichFaces: rich:* component library
RichFaces: rich:* component libraryRichFaces: rich:* component library
RichFaces: rich:* component library
 
Angular - Improve Runtime performance 2019
Angular - Improve Runtime performance 2019Angular - Improve Runtime performance 2019
Angular - Improve Runtime performance 2019
 
Diving into HHVM Extensions (php[tek] 2016)
Diving into HHVM Extensions (php[tek] 2016)Diving into HHVM Extensions (php[tek] 2016)
Diving into HHVM Extensions (php[tek] 2016)
 
Creating a Smooth Development Workflow for High-Quality Modular Open-Source P...
Creating a Smooth Development Workflow for High-Quality Modular Open-Source P...Creating a Smooth Development Workflow for High-Quality Modular Open-Source P...
Creating a Smooth Development Workflow for High-Quality Modular Open-Source P...
 
Unit Testing from Setup to Deployment
Unit Testing from Setup to DeploymentUnit Testing from Setup to Deployment
Unit Testing from Setup to Deployment
 
Saving Time And Effort With QuickBase Api - Sergio Haro
Saving Time And Effort With QuickBase Api - Sergio HaroSaving Time And Effort With QuickBase Api - Sergio Haro
Saving Time And Effort With QuickBase Api - Sergio Haro
 
HTML5: huh, what is it good for?
HTML5: huh, what is it good for?HTML5: huh, what is it good for?
HTML5: huh, what is it good for?
 
4.2 PHP Function
4.2 PHP Function4.2 PHP Function
4.2 PHP Function
 
Spark IT 2011 - Simplified Web Development using Java Server Faces 2.0
Spark IT 2011 - Simplified Web Development using Java Server Faces 2.0Spark IT 2011 - Simplified Web Development using Java Server Faces 2.0
Spark IT 2011 - Simplified Web Development using Java Server Faces 2.0
 
GraphConnect 2014 SF: From Zero to Graph in 120: Scale
GraphConnect 2014 SF: From Zero to Graph in 120: ScaleGraphConnect 2014 SF: From Zero to Graph in 120: Scale
GraphConnect 2014 SF: From Zero to Graph in 120: Scale
 
Serverless and Servicefull Applications - Where Microservices complements Ser...
Serverless and Servicefull Applications - Where Microservices complements Ser...Serverless and Servicefull Applications - Where Microservices complements Ser...
Serverless and Servicefull Applications - Where Microservices complements Ser...
 
Logstash
LogstashLogstash
Logstash
 
Advanced technic for OS upgrading in 3 minutes
Advanced technic for OS upgrading in 3 minutesAdvanced technic for OS upgrading in 3 minutes
Advanced technic for OS upgrading in 3 minutes
 

Recently uploaded

CRM Contender Series: HubSpot vs. Salesforce
CRM Contender Series: HubSpot vs. SalesforceCRM Contender Series: HubSpot vs. Salesforce
CRM Contender Series: HubSpot vs. SalesforceBrainSell Technologies
 
Introduction Computer Science - Software Design.pdf
Introduction Computer Science - Software Design.pdfIntroduction Computer Science - Software Design.pdf
Introduction Computer Science - Software Design.pdfFerryKemperman
 
PREDICTING RIVER WATER QUALITY ppt presentation
PREDICTING  RIVER  WATER QUALITY  ppt presentationPREDICTING  RIVER  WATER QUALITY  ppt presentation
PREDICTING RIVER WATER QUALITY ppt presentationvaddepallysandeep122
 
EY_Graph Database Powered Sustainability
EY_Graph Database Powered SustainabilityEY_Graph Database Powered Sustainability
EY_Graph Database Powered SustainabilityNeo4j
 
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte GermanySuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte GermanyChristoph Pohl
 
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed DataAlluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed DataAlluxio, Inc.
 
What is Fashion PLM and Why Do You Need It
What is Fashion PLM and Why Do You Need ItWhat is Fashion PLM and Why Do You Need It
What is Fashion PLM and Why Do You Need ItWave PLM
 
What is Advanced Excel and what are some best practices for designing and cre...
What is Advanced Excel and what are some best practices for designing and cre...What is Advanced Excel and what are some best practices for designing and cre...
What is Advanced Excel and what are some best practices for designing and cre...Technogeeks
 
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...stazi3110
 
MYjobs Presentation Django-based project
MYjobs Presentation Django-based projectMYjobs Presentation Django-based project
MYjobs Presentation Django-based projectAnoyGreter
 
SpotFlow: Tracking Method Calls and States at Runtime
SpotFlow: Tracking Method Calls and States at RuntimeSpotFlow: Tracking Method Calls and States at Runtime
SpotFlow: Tracking Method Calls and States at Runtimeandrehoraa
 
Ahmed Motair CV April 2024 (Senior SW Developer)
Ahmed Motair CV April 2024 (Senior SW Developer)Ahmed Motair CV April 2024 (Senior SW Developer)
Ahmed Motair CV April 2024 (Senior SW Developer)Ahmed Mater
 
Xen Safety Embedded OSS Summit April 2024 v4.pdf
Xen Safety Embedded OSS Summit April 2024 v4.pdfXen Safety Embedded OSS Summit April 2024 v4.pdf
Xen Safety Embedded OSS Summit April 2024 v4.pdfStefano Stabellini
 
Automate your Kamailio Test Calls - Kamailio World 2024
Automate your Kamailio Test Calls - Kamailio World 2024Automate your Kamailio Test Calls - Kamailio World 2024
Automate your Kamailio Test Calls - Kamailio World 2024Andreas Granig
 
Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...
Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...
Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...OnePlan Solutions
 
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...Matt Ray
 
Cloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEECloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEEVICTOR MAESTRE RAMIREZ
 
Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)Hr365.us smith
 
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptx
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptxKnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptx
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptxTier1 app
 

Recently uploaded (20)

CRM Contender Series: HubSpot vs. Salesforce
CRM Contender Series: HubSpot vs. SalesforceCRM Contender Series: HubSpot vs. Salesforce
CRM Contender Series: HubSpot vs. Salesforce
 
Introduction Computer Science - Software Design.pdf
Introduction Computer Science - Software Design.pdfIntroduction Computer Science - Software Design.pdf
Introduction Computer Science - Software Design.pdf
 
PREDICTING RIVER WATER QUALITY ppt presentation
PREDICTING  RIVER  WATER QUALITY  ppt presentationPREDICTING  RIVER  WATER QUALITY  ppt presentation
PREDICTING RIVER WATER QUALITY ppt presentation
 
EY_Graph Database Powered Sustainability
EY_Graph Database Powered SustainabilityEY_Graph Database Powered Sustainability
EY_Graph Database Powered Sustainability
 
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte GermanySuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
 
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed DataAlluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
 
What is Fashion PLM and Why Do You Need It
What is Fashion PLM and Why Do You Need ItWhat is Fashion PLM and Why Do You Need It
What is Fashion PLM and Why Do You Need It
 
What is Advanced Excel and what are some best practices for designing and cre...
What is Advanced Excel and what are some best practices for designing and cre...What is Advanced Excel and what are some best practices for designing and cre...
What is Advanced Excel and what are some best practices for designing and cre...
 
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
 
MYjobs Presentation Django-based project
MYjobs Presentation Django-based projectMYjobs Presentation Django-based project
MYjobs Presentation Django-based project
 
SpotFlow: Tracking Method Calls and States at Runtime
SpotFlow: Tracking Method Calls and States at RuntimeSpotFlow: Tracking Method Calls and States at Runtime
SpotFlow: Tracking Method Calls and States at Runtime
 
Ahmed Motair CV April 2024 (Senior SW Developer)
Ahmed Motair CV April 2024 (Senior SW Developer)Ahmed Motair CV April 2024 (Senior SW Developer)
Ahmed Motair CV April 2024 (Senior SW Developer)
 
Xen Safety Embedded OSS Summit April 2024 v4.pdf
Xen Safety Embedded OSS Summit April 2024 v4.pdfXen Safety Embedded OSS Summit April 2024 v4.pdf
Xen Safety Embedded OSS Summit April 2024 v4.pdf
 
2.pdf Ejercicios de programación competitiva
2.pdf Ejercicios de programación competitiva2.pdf Ejercicios de programación competitiva
2.pdf Ejercicios de programación competitiva
 
Automate your Kamailio Test Calls - Kamailio World 2024
Automate your Kamailio Test Calls - Kamailio World 2024Automate your Kamailio Test Calls - Kamailio World 2024
Automate your Kamailio Test Calls - Kamailio World 2024
 
Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...
Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...
Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...
 
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
 
Cloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEECloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEE
 
Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)
 
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptx
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptxKnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptx
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptx
 

N hidden gems you didn't know hippo delivery tier and hippo (forge) could give

  • 1. N Hidden Gems You Didn't Know Hippo Delivery Tier and Hippo Forge Could Give Woonsan Ko Solution Architect w.ko @ onehippo.com
  • 3. OSS Libraries Forge Plugins Enterprise Plugins Around Hippo Delivery Tier OSS* Frameworks More Hippo specific More feature-rich * OSS: Open Source Software
  • 4. OSS Libraries Forge Plugins Enterprise Plugins Around Hippo Delivery Tier OSS* Frameworks More Hippo specific More feature-rich Hippo Delivery Tier * OSS: Open Source Software
  • 5. OSS Libraries Forge Plugins Enterprise Plugins Around Hippo Delivery Tier OSS* Frameworks More Hippo specific More feature-rich Hippo Delivery Tier * OSS: Open Source Software
  • 6. Gems in Hippo Delivery Tier
  • 7. Gems in Hippo Delivery Tier #1 Fluent Query “Made up with fluent style. Don’t confuse me with the flats!”
  • 8. Fluent Query HstRequestContext requestContext = RequestContextProvider.get(); HstQueryManager qm = requestContext.getQueryManager(); HstQuery hstQuery = qm.createQuery(scope, BaseDocument.class); hstQuery.setOffset(0); hstQuery.setLimit(10); hstQuery.addOrderByDescending("my:date"); Filter filter = hstQuery.createFilter(); filter.addContains(".", "hippo"); hstQuery.setFilter(filter); HstQueryResult result = hstQuery.execute(); Old, Non-Fluent Style
  • 9. HstRequestContext requestContext = RequestContextProvider.get(); HstQueryManager qm = requestContext.getQueryManager(); HstQuery hstQuery = qm.createQuery(scope, BaseDocument.class); hstQuery.setOffset(0); hstQuery.setLimit(10); hstQuery.addOrderByDescending("my:date"); Filter filter = hstQuery.createFilter(); filter.addContains(".", "hippo"); hstQuery.setFilter(filter); HstQueryResult result = hstQuery.execute(); Fluent Query Filter filter = hstQuery.createFilter(); filter.addContains(".", "hippo"); Filter sub1 = hstQuery.createFilter(); sub1.addGreaterOrEqualThan("my:date", date, DAY); filter.addAndFilter(sub1); Filter sub2 = hstQuery.createFilter(); sub2.addEqualTo("my:createdBy", "editor1"); filter.addAndFilter(sub2); Old, Non-Fluent Style Nested Filter
  • 10. Fluent Query * More at https://www.onehippo.org/library/concepts/fluent-search/hst-fluent-search.html New, Fluent Style HstQuery hstQuery = HstQueryBuilder.create(scope) // varargs .ofTypes(BaseDocument.class) // varargs .where(constraint(".").contains("hippo")) // varargs .offset(0) .limit(10) .orderByDescending("my:date") // varargs .build(); HstQueryResult result = hstQuery.execute();
  • 11. Fluent Query HstQuery hstQuery = HstQueryBuilder.create(scope) .ofTypes(BaseDocument.class) .where(constraint(".").contains("hippo")) .offset(0) .limit(10) .orderByDescending("my:date") .build(); HstQueryResult result = hstQuery.execute(); .where( and( constraint(".").contains("hippo"), constraint("my:date").greaterOrEqualThan(date, DAY), constraint("my:createdBy").equalTo("editor1") ) ) * More at https://www.onehippo.org/library/concepts/fluent-search/hst-fluent-search.html New, Fluent Style Nested Constraints
  • 12. Gems in Hippo Delivery Tier #2 HDC (Hierarchical Diagnostic Context) API “Determine performance problems faster!”
  • 13. HDC API ● Lightweight performance diagnostic tool, for both SITE and CMS. ● Hierarchical Diagnostics Reporting on request processing: - HstFilter (3011ms): {hostName=www.example.com, uri=/site/, query=null} `- Pipeline processing (3002ms): {pipeline=null} |- HstComponentInvokerProfiler (0ms): {method=doBeforeRender, window=main, component=com.example.components.BaseComponent, ref=r46_r1} |- HstComponentInvokerProfiler (471ms): {method=doBeforeRender, window=latestjobs, component=com.example.components.common.LatestItems, ref=r46_r1_r1_r1, HippoBeanIterationCount=1} | `- query (466ms): {statement=//*[(@hippo:paths='a5a24dd3-04a0-4ed1-a59a-ffc960ae69f2') and (@hippo:availability='live') and ((@jcr:primaryType='hippogogreen:job'))] order by @hippogogreen:closingdate descending} ...
  • 14. HDC API ● Lightweight performance diagnostic tool, for both SITE and CMS. ● Hierarchical Diagnostics Reporting on request processing: - HstFilter (3011ms): {hostName=www.example.com, uri=/site/, query=null} `- Pipeline processing (3002ms): {pipeline=null} |- HstComponentInvokerProfiler (0ms): {method=doBeforeRender, window=main, component=com.example.components.BaseComponent, ref=r46_r1} |- HstComponentInvokerProfiler (471ms): {method=doBeforeRender, window=latestjobs, component=com.example.components.common.LatestItems, ref=r46_r1_r1_r1, HippoBeanIterationCount=1} | `- query (466ms): {statement=//*[(@hippo:paths='a5a24dd3-04a0-4ed1-a59a-ffc960ae69f2') and (@hippo:availability='live') and ((@jcr:primaryType='hippogogreen:job'))] order by @hippogogreen:closingdate descending} ... Runtime Configuration
  • 15. HDC API ● What if I want to measure the performance of my own business logic? * More at https://www.onehippo.org/library/concepts/request-handling/hst-page-diagnostics.html // RelatedArticles.java public void doBeforeRender(HstRequest req, HstResponse res) throws HstComponentException { // ... List<Articles> articles = getRelatedArticlesIntelligently(); req.setAtttribute("articles", articles); // ... }
  • 16. HDC API ● What if I want to measure the performance of my own business logic? * More at https://www.onehippo.org/library/concepts/request-handling/hst-page-diagnostics.html // RelatedArticles.java public void doBeforeRender(HstRequest req, HstResponse res) throws HstComponentException { Task relDocsTask = null; try { if (HDC.isStarted()) relDocsTask = HDC.getCurrentTask().startSubtask("relDocs"); List<Articles> articles = getRelatedArticlesIntelligently(); req.setAtttribute("articles", articles); relDocsTask.setAttribute("count", articles.size()); } finally { if (relDocsTask != null) relDocsTask.stop(); } }
  • 17. HDC API ● What if I want to measure the performance of my own business logic? // RelatedArticles.java public void doBeforeRender(HstRequest req, HstResponse res) throws HstComponentException { Task relDocsTask = null; try { if (HDC.isStarted()) relDocsTask = HDC.getCurrentTask().startSubtask("relDocs"); List<Articles> articles = getRelatedArticlesIntelligently(); req.setAtttribute("articles", articles); relDocsTask.setAttribute("count", articles.size()); } finally { if (relDocsTask != null) relDocsTask.stop(); } } * More at https://www.onehippo.org/library/concepts/request-handling/hst-page-diagnostics.html |- HstComponentInvokerProfiler (1235ms): {component=c.e.c.RelatedArticles, ...} | `- relDocs (1117ms): {count=330} ... Outcome
  • 18. Gems in Hippo Delivery Tier #3 Spring Managed HstComponent “Cleaner with Real Dependency Injection!”
  • 19. Spring Managed HstComponent package com.example.components; public class Search extends AbstractSearchComponent { public void doBeforeRender(HstRequest req, HstResponse res) throws HstComponentException { // Manual look up the service component, 'catalogServiceBean' ... CatalogService catService = HstServices.getComponentManager().getComponent("catalogServiceBean"); request.setAttribute("item", catService.getItem(req.getParameter("pid"))); } } Old, Manual Style
  • 20. Spring Managed HstComponent package com.example.components; @Component // for auto-scanning! @Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) // "prototype" always! @Service("com.example.components.Search") // FQCN as @Service! public class Search extends AbstractSearchComponent { @Autowired private CatalogService catService; public void doBeforeRender(HstRequest req, HstResponse res) throws HstComponentException { request.setAttribute("item", catService.getItem(req.getParameter("pid"))); } } New, Auto-wiring Style
  • 21. ● Annotation scanning on Spring managed HST Components <!-- e.g. site/src/main/resources/META-INF/hst-assembly/overrides/base.xml--> <!-- (HST)Components Annotation Scanning --> <context:component-scan base-package="com.example.components" /> Spring Managed HstComponent * More at https://www.onehippo.org/library/concepts/web-application/spring-managed-hst-components.html ● Special Attentions! ○ Always set @Scope to prototype! ○ Always set @Service to the FQCN of the component class!
  • 22. Gems in Hippo Delivery Tier #4 Asynchronous Rendering “Better Render Later!”
  • 23. ● Client-side Asynchronous Rendering ○ E.g. A component accessing external services. ○ AJAX code, retrieving HST Component Rendering URL ● Server-side Asynchronous Rendering ○ E.g. A non-cacheable component in the server side. ○ ESI or SSI, retrieving HST Component Rendering URL Asynchronous Component Rendering <<header>> <<footer>> <<left>> <<content>> <Store Locator>
  • 24. ● Client-side Asynchronous Component Rendering ○ @hst:async = true Asynchronous Component Rendering Browser HST Container <<header>> <<footer>> <<left>> <<content>> <Store Locator> (1) HST Page Request (5) HST Component Rendering URL (2) Default Pipeline (6) HST Component Rendering Pipeline (3) Page(4) AJAX script seeded (8) Component Window Response (7) Component Window
  • 25. ● Server-side Asynchronous Component Rendering ○ @hst:async = true, @hst:asyncmode = "esi" Asynchronous Component Rendering * More at https://www.onehippo.org/library/concepts/component-development/asynchronous-hst-components-and-containers.html Browser HST Container (1) HST Page Request <<header>> <<footer>> <<left>> <<content>> <Store Locator> (3) Default Pipeline Page Cache (2) Get Page ESI Processor (4) Page (6) HST Component Rendering Pipeline (7) Component Window (5) Put Page (8) Dynamically Aggregated Page
  • 26. HST ESI Processor Browser ESI Processor Dispatchable local path Page Cache <html> <h1>Hello, World!</h1> <!--esi:include src="/special..." --> </html> <div>Hi ${user}! Here’s a special deal for you!</div> <html> <h1>Hello, World!</h1> </html> <div>Hi Hippo! Here’s a special deal for you!</div> HST HST Component ● HST ESI Processor dispatches to . . . a Component Rendering URL or Local URI Path (Servlet/JSP). ○ Note: HST ESI does NOT support Remote URLs for simplicity!
  • 27. HST ESI Processor ● What if I want to include remote URLs using ESI tags? ○ APA Reverse Proxy Project: ■ Java Servlet or Filter library as Reverse Proxy ■ portals.apache.org/applications/webcontent2/reverse-proxy-module.html ○ Map Local Path to Remote URLs! ■ e.g. /site/products/ → http://example.com/products/ , /site/products/123 → http://example.com/products/123 * More at https://www.onehippo.org/library/concepts/web-application/hst-2-edge-side-includes-support.html <!--esi:include src="/site/products/123" -->
  • 28. Gems in Hippo Forge Projects
  • 29. Gems in Hippo Forge Projects #1 Integration with External Content “Link Document to External Content with Metadata (e.g. in CMIS, Commerce, DB, … ).”
  • 30. Integration with External Content ● External Document Picker Forge Plugin: ○ Concept: Separation of UI and Data Service. ■ UI Plugin ● UI for searching and displaying of external document item(s), retrieved by ExternalDocumentServiceFacade component. ■ ExternalDocumentServiceFacade Data Service interface ● Configured for the UI Plugin; Invoked by the UI Plugin. ● All Data Handling under the hood against backend. ○ Title, icon and description for each external document. ○ Store metadata of selected item(s) into Hippo document. * More at http://exdocpickerbase.forge.onehippo.org/
  • 32. Integration with External Content ExternalDocumentServiceFacade is responsible for data to display each item.
  • 33. Integration with External Content Again, ExternalDocumentServiceFacade is responsible for data to display each selection.
  • 34. Gems in Hippo Forge Projects #2 Content EXIM “Import Document / Binary Data to Hippo!”
  • 35. Content EXIM ● Lightweight Library to EXport/IMport Documents and Binaries to/from JSON or XML ● Uses Standard Hippo Workflow/Gallery APIs. ● Groovy Updater as primary execution engine ● Example Groovy Scripts to start with: ○ to export/import documents and image/assets. ○ to create documents from CSV. ○ to create image sets from image files. * More at http://content-exim.forge.onehippo.org/
  • 37. Content EXIM * More at http://content-exim.forge.onehippo.org/
  • 38. Gems in Hippo Forge Projects #3 Apache Camel Integration “Synchronize Content with External System through Enterprise Message Bus!”
  • 39. Apache Camel Integration ● An example use case
  • 40. Apache Camel Integration ● Apache Camel (camel.apache.org): ○ Lightweight framework for the Enterprise Integration Patterns ○ Production-ready components: ■ JMS, ActiveMQ, Kafka, File, SFTP, HTTP4, SQL, NoSQLs, ElasticSearch, XMPP, . . . ● Apache Camel Integration Forge: ○ Provides a Camel Component to consume Hippo Events (from Hippo Event Bus). ■ Component URI: hippoevent: * More at http://camel-hippoevt.forge.onehippo.org/ <camelContext> <route id="Route-HippoEventBus-to-Queue"> <from uri="hippoevent:?category=workflow&amp;action=publish,depublish" /> <convertBodyTo type="java.lang.String" /> <to uri="activemq:queue:hippo" /> </route> </camelContext>
  • 41. Gems in Hippo Forge Projects #4 Spring Security Integration “Secure My Services through JWT, SAML or OAuth!”
  • 42. Spring Security Integration ● Spring Security Framework: ○ Powerful and highly customizable authentication and access-control framework. ○ Basic Auth, Spring Security SAML, Spring Security OAuth, etc. ● HST Spring Security Framework Integration Forge adds: ○ Hippo Authentication Provider with Hippo UserDetailsService. ○ Spring Security Valve injected in HST pipeline. ■ Sitemap Item with @hst:authenticated, @hst:roles, @hst:users. ■ JAX-RS Services with JEE Security Annotations such as @RolesAllowed. * More at http://hst-springsec.forge.onehippo.org/
  • 43. OSS Libraries Forge Plugins Enterprise Plugins Gems in Summary OSS* Frameworks More Hippo specific More feature-rich Hippo Delivery Tier * OSS: Open Source Software
  • 44. OSS Libraries Forge Plugins Enterprise Plugins Gems in Summary OSS* Frameworks More Hippo specific More feature-rich Hippo Delivery Tier ● Delivery Tier ○ HST Fluent Query ○ HDC ○ Spring Managed Components ○ Async Components ■ HST ESI Processor * OSS: Open Source Software
  • 45. OSS Libraries Forge Plugins Enterprise Plugins Gems in Summary OSS* Frameworks More Hippo specific More feature-rich Hippo Delivery Tier ● Delivery Tier ○ HST Fluent Query ○ HDC ○ Spring Managed Components ○ Async Components ■ HST ESI Processor ● Forges ○ External Document Picker ○ Content EXIM ○ Apache Camel Integration ○ Spring Security Integration * OSS: Open Source Software
  • 46. Stay in Touch NORTH AMERICA 71 Summer Street Boston, MA 02110 USA EUROPE Oosteinde 11 1017 WT Amsterdam The Netherlands CALL US +31 20 522 44 66 +44 20 35 14 99 60 +49 69 80 88 40 67 +1 877 414 47 76 WEB & EMAIL www.onehippo.com sales@onehippo.com ● SlideShare.net/woonsan ● WoonsanKo.blogspot.com