Wednesday, 2 August 2017

Steps to implement a search in S&P With AEM

Set up
  • Hosting: Hosting the search tool.
  • Indexing: Indexing the data.
  • Index frequency : Configuring the index.       

Configure
  • Metadata - Used for faceting, sorting, ranking, relevance.
  • Breadcrumbs - for a better navigation.
  • Pagination - for a better navigation.
  • Recent Searches - Search assist.
  • Search suggestions(Did you mean) - Search assist.
  • Auto complete - Search assist.

Fine-tune
  • Promotion: Normal, Based on search result, we can promote.
  • Dictionaries : Configure for better results.
  • Banners : any organizational promotion.
  • Redirects : Send user to a page.

Read more here

Related 
Steps to implement any search technology
AEM Dispatcher, why it  is needed?
AEM Desktop App
Figure out the best search technology or tool
Steps to implement search in Solr
Quality of Search - fine tuning search implementation
 
 
 

How do we select the best search tool for the site?

There are many search engines, some are open source and some are paid. The trend in search technology shows an affinity towards cognitive and artificial intelligence now.

  • Solr
  • Elasticsearch
  • Google Search Appliance (GSA)
  • Oracle Endeca
  • Microsoft FAST
  • Attivio
  • Sinequa
  • Coveo
  • IBM Watson
  • Amazon CloudSearch
  • SharePoint Search
  • HP Autonomy

The common Big data used with searches are:
  • Apache Hadoop
  • Cloudera
  • Hortonworks
Search Trend Evolution
Keyword Search -> Semantic -> Contextual -> Cognitive -> (Human Brain)

Enterprise search now uses natural language processing and machine learning which dramatically improve the results relevancy and completeness.
Here cognitive search is based on Artificial Intelligence.

Which search is the best?

I always suggest the one that meets your needs in your environment and requirements.

Process of identifying the needs

Auditing the current system
Understand the current system and new requirements.
OS & Systems
Think of operating system to be hosted. On-Premise Vs Cloud Vs Hybrid
Dev tools
Think on the tools to develop while search is getting revamped
Repositories
Think about content repository and ensure product upgrade history is clean.
Security
Are there any new security levels to be added?
Content
Think on the content when search system upgrades are in place
Users
External Vs internal? The behavior & type of users.

Understand any data
Search solutions must connect to and ingest data from a wide variety of source. For e.g.: Data types ranging from images, video, audio, and machine data such as from internet-of-things (IoT) devices.

Scale to handle big
Now the data is in peta bytes which resides in distributed architectures.

The migration process
Provide transparent, solid experience to the end users, Educate the users about new system.

Install base and revenue history
A proven stream of revenue generated by customer adoption of its solution and installation market presence.

Cross-domain standalone solution, Employ AI technologies
The solution is self-sufficient, general-purpose cross domain one now. Understand and organize data, predict, improve relevancy, and automatically tune the relevancy of results over time using AI Techniques.

Allow developers to customize search applications
Currently search vendors provide SDKs, Apis, and in some cases visual design tools to customize search to a maximum extend.

List out your semi finalists then finalists. Then rematch the requirement with finalists and decide the winner.

Read More
Steps to implement any search technology
AEM Dispatcher, why it  is needed?
AEM Desktop App
Figure out the best search technology or tool
Steps to implement search in Solr
Quality of Search - fine tuning search implementation

Quality of search - Fine tuning the search

There are many search engines, some are open source and some are paid. The trend in search technology shows an affinity towards cognitive and artificial intelligence now.
  • Solr
  • Elasticsearch
  • Google Search Appliance (GSA)
  • Oracle Endeca
  • Microsoft FAST
  • Attivio
  • Sinequa
  • Coveo
  • IBM Watson
  • Amazon CloudSearch
  • SharePoint Search
  • HP Autonomy
The common Big data used with searches are:
  • Apache Hadoop
  • Cloudera
  • Hortonworks
Quality of search(QoS)
Let us see how we can make a search effective. QoS is a term used with search implementation fine tuning. Once a search is implemented, next steps are to ensure the search performance. There are many ways we can do the fine tuning.

Query cleaning: 
Before search hits the index, ensure the query is cleaned and aligned to your index.

Add analytics:
Ensure you are using analytics hand in hand with search, which will definitely improve the effectiveness of search.

Rules: 
Rules like ranking, relevance etc can be adjusted to fine tune the search results.

Proper metadata mapping:
Re-verify the metadata mapping for index to ensure everything is done perfectly.

Dictionaries, Synonyms:
Some times we miss to configure dictionaries which will restrict the user from synonym search. Words with similar meaning does not come in result set at all. Confirm you have configured them well.

Excluded words:
Ensure the excluded word list is configured so that none of the unwanted queries fetch the result.

Restrictions:
There are cases where we have to skip some pages from search results. Ensure this restrictions are working as expected.

Once all above conditions are met, next step is to verify the search functionality ourselves to confirm the 'recent searches', 'search suggestion', 'auto complete'/ 'type ahead', 'null search results' are functioning as expected.

Finally don't miss to check the reports like Terms report, null search report, search requests, index reports, analytics reports,  crawl reports, content request reports.

Usually search technology is treated as 'once implement then ignore'. My recommendation is keep improving the configurations by constantly watching the reports often.

Read More
Steps to implement any search technology
AEM Dispatcher, why it  is needed?
AEM Desktop App
Figure out the best search technology or tool
Steps to implement search in Solr
Quality of Search - fine tuning search implementation

Monday, 10 July 2017

Search promote Rules

Rules:
Rules helps us to validate a condition before/during/after search execution.
Ensure to use meaningful names while creating rules.



Query Cleaning Rules(QCR)
QCR helps to clean up the query triggered from front end and process something specific before the actual query starts execution.

Example 1: Say we need to set a JSON template for transport layer, below query helps for the same.

Name: Set Json Transport Template

If all of the following conditions are met:
    Every query
Perform the following actions:
   Set backend parameter sp_t to value json.tpl

Example 2: Say we have both content and product searches, to enable the content search we can set up a rule as below,

Name: Content Search

   If all of the following conditions are met:
    Query segment equal value content
Perform the following actions:
   Set custom variable content to value 1

So if the query parameter contains term segment='content', the query gets executed and it sets a variable content = '1' in backend, so that in our template, we can redirect the code to retrieve value for content search by testing this variable.

Direct Hits(DH)
This rules gets executed directly on meeting the condition.

Query Pattern:
website_URL: term1, term2, term3
In this case, when the query term contains term1 or term2 or term 3, the website_URL gets executed. Search gets redirected to the url.

Pre-Search Rules(PSR)
This rules are useful when we need to validate something before the search starts.

Example 1
Name: Load Simulator

If all of the following conditions are met:
    In simulation mode
Perform the following actions:
   Set targeted template to simulator

Example 2 
Name: Load RSS Feeds

   If all of the following conditions are met:
    Query q contains value rss
Perform the following actions:
   Set targeted template to feed

Example 3 

Name: Set Default Content Template
   If all of the following conditions are met:
    Custom variable content equal value 1
Perform the following actions:
   Set targeted template to Content_XML
   
Post Search Rules (PSR)
This helps to adjust the result post the search execution(Before displaying on screen). Say we need to remove some unwanted data from search results, in such cases this rule can be used.

Example 1
Name: check if discontinued items exists in results

If all of the following conditions are met:
    Custom variable discontinued not equal value 0
Perform the following actions:
   Set template's backend parameter sp_x_16 in template *targeted for search *primary to value discontinued
   Set template's backend parameter sp_q_16 in template *targeted for search *primary to value 1
   
Business Rules(BR)
Business rules helps to execute some specific business rules on search. Say we need to display a promotonal banner on top of the search results.

Example 1
Name: Business Rule Ferrari

If all of the following conditions are met:
   Keyword equal Ferrari
Perform the following actions:
   Set banner in area top to banner Ferrari - the top one

Example 2 
Name:  Promote Specific Items

   If all of the following conditions are met:
   Every query
Perform the following actions:
   Push group sp_cs = UTF-8 sp_p = all sp_q = * spc_no_field_table = 1 Product-Type = Product for search default to position 1
   Push group sp_cs = UTF-8 sp_p = all sp_q = * spc_no_field_table = 1 Product-Type = Product2 for search default to position 2
   Push group sp_cs = UTF-8 sp_p = all sp_q = * spc_no_field_table = 1 Product-Type = Product3 for search default to position 3


Ranking Rules
Ranking Rules allow you to modify the relative positioning of Search results based on contained meta tag content and/or related Adobe Analytics metrics.

Example 1
(Meta Tag) salesrank 10 - Maximum Importance

Set rank
regexp -[[:digit:]][[:digit:]][[:digit:]][[:digit:]] -1


Thursday, 29 June 2017

Adobe Search and Promote Menus Explained



Through this post, we will try to explain the main menus and their functionalities here.

Home:


This menu holds the dashboard for viewing overall search system for a specific account. It includes below sections.

  • Index Information,
  • Terms Report,
  • Null Search Terms Report,
  • Crawl Performance,
  • Search Form,
  • Recent Changes,
  • Alerts


Design:
This menu helps to adjust the design specific search configurations on a page. It includes,

  • Navigation - Facets, Facet Rails(Group of facets), Breadcrumbs, Page Navigation, Menus, Recent Searches
  • Templates - Section where we can create new templates. This templates includes both transport(.tpl) and presentation(.tmpl) templates.
  • Banners - Helps to add HTML Banner
  • Autocomplete - Setting up auto complete, word lists, styles of search form and its form related configurations are available in this section.

Rules:

  • Query Cleaning -  When the query is hit on the browser, if we need to clean up the query, this rules can be used.
  • Direct Hits -  For a specific query term, if we need to redirect to a specific url, we can do the same here.
  • Pre-search rules - This rules gets executed before the search happens; useful when we need to do an operation on query term(for eg: check query contains a specific word)
  • Post search rules- This gets executed once a search is done and result is available. (An example could be, if a custom variable is present and its value is meeting some criteria)
  • business rules - purely business queries. For eg if business wants to show a banner(promotional Advt) when the query term contains a specific term.
  • Ranking rules - Helps to provide weights to metatags and adjusting its weights. Based on this, search results can be pushed up or down.


Linguistics:

  • Dictionaries - to add our own dictionary.
  • Words & Language -  To add any conditions like case sensitivity, sound alike etc.
  • Did you mean - If a user types a wrong spelled term and if we need to suggest him a relevant term.
  • Excluded words - always helps to omit some terms from search.

Simulator:
An html form of search page in S&P environment. This helps to test the search functionality in Search and Promote itself. We can set up rules for various simulators.

Staging:

A section which gives idea on what are all things modified in stage and not yet pushed to live

Reports:
An over view section of all search operations. Index reports, term reports, Adobe analytics, alerts etc. Changes made by different users can be tracked here.

Index:
All indexing operations can be performed here. This include configuring new index, editing various types of indexes, running index, roll back etc.

Settings:
All account related and user related settings are found here. Crawl, searching, metadata, filtering, rules, analytics, seo, profile, account, user operations etc are managed through thi

s menu.

Accounts:

All accounts are listed here for a logged in user. If the person is a normal user with single account access, only one account will be listed here.


Friday, 28 April 2017

How , When , What, Where Adobe Search And Promote

This page contains details of flow of Adobe Search & Promote. 

Adobe Search & Promote is one of the leaders in websites Product & Content Searches. How it is different from other technologies is the way we can do customization in search. We can use one of the best feature available in market called promote.

The major aim of any search migration project are given below,

a)    Migration of legacy search system to Search & Promote platform.
b)    Return more relevant results
c)    Use customer-supplied metrics to rank search results

So the flow happens as given below.

•    Create new Search & Promote account for the team.
•    Define metadata schema & configure the URL entry points/ index connector.
•    Using report widgets to see data populated by verifying all results are indexed, verifying all results are returned in the data view & verify that keyword searches are returning best results as offered by S&P.
•    Designing search result pages
•    Facet based search implementation.
•    Implement Sort, facet, breadcrumb, pagination etc.
•    implement best way of navigation by making it easy for users to navigate results using nested facets.
•    More details on content search (data views, sort etc) and transport layer.
•    The output can be configured to deliver HTML or XML as requested by clients.
•    We can do ranking of results based on metrics on previous searches.

Extra Notes:

•    Debug any issues with the search functionality using debug options available and also through analyzing the transport layer output.
•    Then using business rules, direct hits we can display promotional content, such as banners, depending on specific search contexts.

We recommend adobe search & promote for any product/content search in any type of website. If you need assistance, contact Adobe: http://www.adobe.com/in/products/searchandpromote.html


Saturday, 15 October 2016

Search and Promote to Adobe Target


Adobe has moved from Search to Search driven merchandising.

Adobe Target suggests merchandise and offers based on user search pages and search terms they have used. Adobe Target makes it easy to promote the right content to- best way of customization.
The implementation method and tool of target looks almost same as Adobe Search and Promote.

How the new search different from Search and promote?

 Test & Target is an improved version of Adobe Search and Promote, which helps users to test various search experiences, marketing products, or analyzing results pages mutually to determine the highest performers. Test & Target also facilitates the targeting of search results or pages to visitors based on past purchase data or prior category preferences. Target can also be easily incorporated into search results to provide product or content recommendations related to visitors’ searches.

 Adobe Target Features

Site Search Options

Vast amount of options like did you mean, dynamic image rendition, decision making refinements etc

Customized Display

based on algorithm target customize the top offering, most popular, highest rated etc.

Search intent
Brilliantly understands the user search based on linguistics, business rules etc to cater high quality results

Metrics based relevance

Based on the rules set, search items are ordered and placed on top so that the relevancy can be high

Analytics integration

Adobe analytics integrated with target helps to capture the search data for customers

Targeted promotions

Promotional items like videos, banner can be set on search results

Update; Adobe Search & Promote is now Adobe Target

Friday, 20 February 2015

How to debug issues with S&P?

S&P - Debugging issues:

How can we find Run log for S&P:
We can check process of S&P by appending URL as : /q=xxx&gsdo=searchpaths&gsdb=runlog&gsdblog=3

Search and promote Simulator in Browser without login:
just append the gscmc=1 parameter in the stage URL. That will load the simulator in the browser instead of login in S&P.

Analyse category or any complicate errors from page:
Add '&gsdb=searchpaths to the staged/live URL with query. Then 'view source' and look for the default search we can find more details.

Index logs

Majority of the indexing issues are published in index logs and by analysing it, we can resolve many of them.

Can we debug transport layer of S&P?

We can get the data passed from JSON layer to presentation layer by previewing the data. On template we need to select preview option to see the data output.

How to check syntax written in a temlate?
We have guided tags to create S&P output. While writing those, ust enable 'check syntax error' on template options. By doing this temlate throws error on save, when there is a syntax error.

Update; Adobe Search & Promote is now Adobe Target


Thursday, 7 November 2013

Comparison between XML Vs HTML Vs JSON as Search And Promote output

There are many ways too display the Search And Promote outputs. Some clients asks for XML, some may ask JSON and some wants HTML.Let us see what are all the pros and cons of all these outputs? When we decided to go for S&P which format output we can go for.

Advantages of XML:

  1. XML gives greater flexibility to display the results.
  2. It is decoupled from presentation layer with more readabilty.
  3. HTML look and feel can be changed any time without modifying the XML layer.
  4. Same XML output feed can be used for mobile or desktop websites. No dependency on it during implementation.
  5. Less size, more oriented with tags.
  6. Webapp get more flexibility, to include any extra information or to restrict some data from users based on location or anything etc.

Extra changes will need to be made in the webapp to transform XML to HTML

Advantages of HTML:

  1. Everything is ready with the output. 
  2. Website owners need not work on further development because already the output is in html form.

But any change in UI can be an additional task in future.

Advantages of JSON:
  1. Lightweight, more readable.
  2. No xml tags.

Encoding from JSON to html can be a tedious task in the first time. 
In case of multi nested facets, it could be tedious to iterate through the deeper facets.

Update; Adobe Search & Promote is now Adobe Target

Tuesday, 17 September 2013

Wordpress Vs Adobe Search And Promote

People usually ask questions about various CMS integration with Search & Promote. Our answer is any
CMS can be integrated with Adobe Search And Promote. As we explained in previous posts, for any content/product website we can implement search and promote.

If it is a content website, we need to feed the url entry point to search and promote. Also we need to ensure the metadata defined in each page which will be used to map in S&P for better results. Since this is a necessary step for SEO we hope all websites must hold good with this theory.

If it is a product website, create product XML/text feed and feed it to search and promote.

The display logic(S&P output) is one option where in website owners can take better decision on. There can be XML, JSON or HTML outputs. Switiching between output forms after the mplementation gives overhead. So before starting with implementation, one has to decide on the output format.

Search and promote does not depend on any of the CMS / technologies involved in creating a website. Adobe made search and promote totally independent which makes the product unique.

How the CQ handles dynamic facets?

There are cases website uses dynamic facets. These facets appear based on search results. CQ has unique techniques to implement the dynamic facets. CQ also provides slot based facets & facet rails for grouping of websites.

We will be discussing on these features in coming posts.
Update; Adobe Search & Promote is now Adobe Target

CQ/ AEM Integrating with Adobe Search&Promote

People usually use Adobe search and promote with CQ developed websites.
Below is a good tutorial from Adobe blog on how to integrate search and promote with CQ.

Search and promote can be integrated with CQ very easily if you follow above steps.

One of the major requirement when we deal with product website is, the input feed should be in defined format, also the S&P output XML which will be fed to CQ.

Advantages:

The major advantage of implementing CQ with S&P is both are product of same company, so the integration is quite easy. There are very good help tutorials available for S&P integration related FAQ's.

How long it may take?

An ordinary- less complicated website takes 2 weeks time usually and complications are purely on the facet structure, data, product, content structure.

Will S&P implementation can be done by a CQ guy?

S&P has lots of features to customize. If a new person do the work, it could be minimal usage of the product. So its better to approach a professional from Adobe to implement S&P.

                                               ---------------------------------------
Update; Adobe Search & Promote is now Adobe Target, same tutorial can be referred for AEM Integration with Target.

Thursday, 22 August 2013

Search And Promote FAQ

Frequently asked questions: Adobe S&P

 Below given are some usually questions which we hear before proceeding Search & Promote.
 These questions are the usually first questions heard before any search tool implementation.

1) Which site can integrate with S&P?
Anysite. Any site needs to be implemented with search can be done through s&p.

2) Is Day CQ website a mandate for S&P?

No

3) What components can be done using S&P?

Menu, breadcrumb, paginatione etc any feature to refine the search can be done through S&P.

4) What are the various sites S&P can work with?

Content Search - Crawls the web url and index, then display result
Product search -  Any kind of feeds with product info will be better for such search.

5) Advantage of S&P?

S&P provides better support compared to other searches. They have option to set business rules to promote an item.

6) Procedure to get an S&P Search implementation?

Contact Adobe to get an S&P Account, they also develop it for you and give maintenance and support further .

7) Site search account can be converted to S&P?

Yes Site search is an old version which can be easily converted/migrated into search and promote.  You need to contact Adobe sales team for this.

8) What about Mercado,Google site search migration to S&P?

Any other searches like Mercado, Google search can be also migrated to S&P with some effort.


9) Search And Promote is Free?

No.

10) Is it possible to use attribute loader in CQ as in site search?

Attribute loader is an add on to load additional data from a feed and make it available for index. Answer for the above question is yes. We can use attribute loader in new Search And Promote too.

11) Search and Promote cost?


Contact Adobe Sales Team.

Update; Adobe Search & Promote is now Adobe Target, Refer above page as Adobe Target FAQ.

Wednesday, 31 July 2013

RSS Feeds Vs Search - Promote

Have you ever thought about search & promote with RSS feeds implementation?

Yes it is possible, because RSS feed is an XML with <rss> version title. So its up to the feed reader to read the contents send by search & promote.

How to create RSS feed based search results?

RSS mainly works on its structure. So we need to have the basic structure of RSS and need to finalize the components in a feed (eg:images , title etc). Once this items are finalized use the S&P API to create RSS structure.

Once configured it with search, the new addition will be available through RSS posts for consumption.

Use of RSS with S&P?

When the site owner wants to publish the products or search results based out of each crawl, adding RSS is a very good option.

Update; Adobe Search & Promote is now Adobe Target

Monday, 29 July 2013

Dynamic Facet : facet when its name is not known

Dynamic Facet(facet when its name is not known):

Think a  scenario where user has to create a facet in a search and promote account, but its name is not
known when we start up the S&P configuration. So what we can do?

CQ is going to introduce dynamic facets for this task. So before this let us do a manual work around for the same.

Our requirement is quiet simple. We need a facet which we don't have their name in hand when work is done. Let us fold our sleeves and get into work.
Below are the steps for the same.

1) Define the facets in XML file.

2) Then in index connector we have to access this values to two fields called  test_facet_name,  test_facet_value through record/mapping.

3) This has now to be defined in meta data definition as text fields.Say test_facet_name, test_facet_value
4) In filtering script we need to iterate this name value pair and load the values in some name value fields like test_name1{name,value},test_name2{name,value}.....

5) Now we need to create meta data with text fields test_name1, upto how many unknown named total facets required.

6) There is a limitation in S&P, we need to contact Adobe team to raise the meta data count.

7) Then this name value is is passed to output by creating facets with names  as test_name1, test_name1 etc upto total number of facets.

8) Now display it through presentation layer.(remember to add those in transport layer too.)

Now the dynamic run time generated facets are ready. Actually these facets we are naming in run time, it was created already during configuration.

Wednesday, 12 June 2013

IntelliJ IDEA 11 and CQ5

I was searching in Google for IntelliJ IDEA with CQ5. Found a good tutorial for the same.
Here is a document which explains setup here for anyone else that is interested in setting up IntelliJ and getting started with CQ5.

Requirements:


    IntelliJ IDEA 11
    Apache Maven
    Adobe CQ5 Quickstart – Author Instance
    A knowledge of Apache Maven and how it works


Monday, 10 June 2013

How, When, What - Adobe Search & Promote.


This page contains details of flow of Adobe Search & Promote.

Adobe Search & Promote is one of the leaders in websites Product & Content Searches. How it is different from other technologies is the way we can do customization in search. We can use one of the best feature available in market called promote.

The major aim of any search migration project are given below,

a)    Migration of legacy search system to Search & Promote platform.
b)    Return more relevant results
c)    Use customer-supplied metrics to rank search results

So the flow happens as given below.

•    Create new Search & Promote account for the team.
•    Define metadata schema & configure the URL entry points/ index connector.
•    Using report widgets to see data populated by verifying all results are indexed, verifying all results are returned in the data view & verify that keyword searches are returning best results as offered by S&P.
•    Designing search result pages
•    Facet based search implementation.
•    Implement Sort, facet, breadcrumb, pagination etc.
•    implement best way of navigation by making it easy for users to navigate results using nested facets.
•    More details on content search (data views, sort etc) and transport layer.
•    The output can be configured to deliver HTML or XML as requested by clients.
•    We can do ranking of results based on metrics on previous searches.

Extra Notes:

•    Debug any issues with the search functionality using debug options available and also through analyzing the transport layer output.
•    Then using business rules, direct hits we can display promotional content, such as banners, depending on specific search contexts.

We recommend adobe search & promote for any product/content search in any type of website. If you need assistance, contact Adobe: http://www.adobe.com/in/products/searchandpromote.html

Found we are violating in any of the content of the web page, please contact us through cqguru@gmail.com
Update; Adobe Search & Promote is now Adobe Target

Friday, 24 May 2013

Adobe Search And Promote and performance

Let us see the major things to be taken care to avoid performance issues while implementing Adobe S and P.
As we know search and promote has got many advantages and abundant modes of customization while
implementing for a websearch.

Usually a web can have content search and if it is a website which sells products, there are product searches available to implement. Same time we need to ensure some of the things while we implement it, which can affect the performance of search.

1) Rules implementation.

There are pre and post searches in any search process. So in Search and Promote we should ensure the post search should be minimal and it should not execute many times (need another new search = 0).

2) Templates should be light: There should not be unnecessary loops and keep temlates always light. it helps to improve the performance.

3) Filed table/attribute table implementation: Ensure the field table to be not executed during first page load. ie, always create field table when *only* required.

Wednesday, 27 March 2013

How to use a different Synonym Provider other than Wordnet in CQ?



When we enable spell checker in CQ5, the default synonym provider class is com.day.crx.core.query.wordnet.WordNetSynonyms which is used to perform the spell check.


WordNet uses semantic algorithms to match synonyms. The service that CQ5 is using (WordNet Search - 3.1) works with the Perl implementation of it.


Another way could be,
the spell checker can be configured by using our own properties file as mentioned below

<param name="synonymProviderClass" value="org.apache.jackrabbit.core.query.lucene.PropertiesSynonymProvider"/>

<param name="synonymProviderConfigPath" value="synonyms.properties"/>


Some cases enabling the WordNet synonym providerdo not always meet the spell check need.

Doing semantic analysis programmatically will always create some false positives. If we can live with them we could use WordNet. Otherwise we could look for a different approach based on babelnet.org or just static files.


If we want to implement an additional provider besides the existing one we would need to use a wrapper class for this.

Tuesday, 26 March 2013

How to do automatic versioning of asset in DAY CQ?



Through CQ it can be done as follows : http://dev.day.com/docs/en/cq/current/dam/cq5_dam_version_management.html

Let us see, is there a way where we can configure the versions to be created automatically when an asset is modified externally and uploaded back with same name?


You could do the same using VersionManager API and eventlistner. Please look at http://www.day.com/specs/jcr/2.0/15_Versioning.html. A sample example is provided @ http://wiki.apache.org/jackrabbit/ExamplesPage#Versioning_Basics.

Creating versions of a content element (including assets) is a powerful feature within the content repository API. CQ takes advantage of this feature, e.g. when you activate a page a version is created automatically.

You have to though be aware that creating versions takes a toll on your disk space. Every version created is a snapshot of the last content-element (usually the Web page). And the version folder grows fast and huge.

When you activate a 'page', a version is created automatically. However, you can always have CQ create versions automatically, although we recommend to be cautious with creating versions for assets (due to the asset size and the disk space consumption). If  want to create asset versions automatically, you want to first think when is the best time to do so. This could be e.g. when you update an asset or when you activate an asset. In both cases you can update workflows (DAM Update and/or Activate workflows).

Another way : You can also try to make changes on a page and then check "Sidekick" to see if a version has been created. Then you can do the same thing with an asset, e.g. change some meta data.

jcr:content versus _jcr_content in URL paths of AEM?



AEM seems to use "_jcr_content" when accessing any resource that is part of a page.
This also means the dispatcher seems to expect that in the URLs, since it will create the following file structure:
/page.html
/page/_jcr_content/par/other stuff and images etc.

When a page is activated/flushed/deleted, the dispatcher deletes the HTML file and the complete "_jcr_content" folder that goes with it - and all is fine.
Now when "jcr:content" is used instead, e.g. in a Javascript that loads a json, like:
/page/jcr:content/test.json
this will also work fine, because CQ/Apache Sling is able to figure out the right resource.
But the dispatcher will cache it in a subfolder like
/page/jcr:content/test.json

 The main issue here is with Windows OS that could not create folders with “:” in their name. As a result of this dispatcher cache could not be created.
On publish side CQ converts “Jcr:content” to “_jcr_content”. So always make sure that JS calls to resources in CQ publish instance had “jcr:content” converted to “_jcr_content”.