Posts in Category "CQ/CRX"

CQ5.5 SP2.1: IllegalArgumentException: Servlet must not be null

Issue

If you are updating your CQ5.5 installation to SP2.1 on an application server you may notice the following exception in the logs:

12.11.2012 03:20:21.683 *ERROR* [CQSE HTTP Service] org.apache.felix.http.whiteboard Failed to register servlet
java.lang.IllegalArgumentException: Servlet must not be null
    at org.apache.felix.http.base.internal.service.HttpServiceImpl.registerServlet(HttpServiceImpl.java:88)
    at org.apache.felix.http.whiteboard.internal.manager.ServletMapping.register(ServletMapping.java:54)
    at org.apache.felix.http.whiteboard.internal.manager.ExtenderManager.registerAll(ExtenderManager.java:235)
    at org.apache.felix.http.whiteboard.internal.manager.ExtenderManager.setHttpService(ExtenderManager.java:195)
    at org.apache.felix.http.whiteboard.internal.tracker.HttpServiceTracker.added(HttpServiceTracker.java:37)

After restarting the server you may notice the following errors in the log:

12.11.2012 03:22:14.621 *ERROR* [Thread-1] org.apache.sling.servlets.resolver.internal.SlingServletResolver bindServlet: Unexpected problem initializing component com.day.cq.opensocial.gadgets.servlet.ConcatProxyServlet com.google.inject.ProvisionException: Guice provision errors:
1) Error injecting method, java.lang.IllegalStateException: Servlet already initialized
    at org.apache.shindig.gadgets.servlet.ConcatProxyServlet.setConcatUriManager(ConcatProxyServlet.java:90)
    while locating com.day.cq.opensocial.gadgets.servlet.ConcatProxyServlet
Caused by: java.lang.IllegalStateException: Servlet already initialized
    at com.google.common.base.Preconditions.checkState(Preconditions.java:145)
    at org.apache.shindig.common.servlet.InjectedServlet.checkInitialized(InjectedServlet.java:59)
    at org.apache.shindig.gadgets.servlet.ConcatProxyServlet.setConcatUriManager(ConcatProxyServlet.java:90)

12.11.2012 03:23:10.151 *ERROR* [FelixStartLevel] com.day.cq.wcm.cq-wcm-mobile-core [com.day.cq.wcm.mobile.core.impl.redirect.RedirectFilter] The bindStats method has thrown an exception (java.lang.NullPointerException) java.lang.NullPointerException
    at com.day.cq.wcm.mobile.core.impl.redirect.RedirectFilter.bindStats(RedirectFilter.java:173)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at org.apache.felix.scr.impl.helper.BaseMethod.invokeMethod(BaseMethod.java:227)
    at org.apache.felix.scr.impl.helper.BaseMethod.access$500(BaseMethod.java:38)
    at org.apache.felix.scr.impl.helper.BaseMethod$Resolved.invoke(BaseMethod.java:591)

Reason

These errors occur due to the files for the CQ Servlet Engine which are still deployed.  These files should not be included when deploying CQ to an application server, and there is a step in the SP2.1 release notes describing this.

Solution

  1. Go to /crx/explorer and open the Content Explorer
  2. Go to /libs/system/install, delete the cqse-httpservice-4.1.32.jar node and save your changes
  3. Restart the instance

These steps are listed in the release notes for SP2.1 when deploying to an application server:

http://dev.day.com/docs/en/cq/current/release_notes_service_pack_2.html

VN:F [1.9.22_1171]
Was this helpful? Please rate the content.
Rating: 7.0/10 (2 votes cast)

CQ5: “LDAPException: error result (4); Sizelimit exceeded” when synchronizing users

Issue

If you are using an LDAP connection with your CQ server you may notice that the LDAP users are not imported correctly to CQ with a warning similar to the following in the error.log:

09.11.2012 10:22:57.624 *WARN* POST /system/console/jmx/com.adobe.granite.ldap…DTools/op/syncAllUsers/ HTTP/1.1 com.day.crx.security.ldap.principals.LDAPPrincipalProvider Error finding user * com.day.crx.security.ldap.LDAPRepositoryException: LDAP error: com.day.ldap.LDAPException: error result (4); Sizelimit exceeded
        at com.day.crx.security.ldap.principals.LDAPPrincipalProvider.findUser(LDAPPrincipalProvider.java:396)
        at com.day.crx.security.ldap.principals.LDAPPrincipalProvider.findPrincipals(LDAPPrincipalProvider.java:553)
        at com.day.crx.security.ldap.LDAPUserSync.syncAllUsers(LDAPUserSync.java:182)
        at com.day.crx.security.ldap.LDAPSynchronization$Directory.syncAllUsers(LDAPSynchronization.java:283)
        at com.day.crx.security.ldap.jmx.LDAPUserMBean.syncAllUsers(LDAPUserMBean.java:117)
        at com.day.crx.security.ldap.jmx.LDAPUserMBean.invoke(LDAPUserMBean.java:187)


09.11.2012 10:22:57.625 *INFO* POST /system/console/jmx/com.adobe.granite.ldap…Tools/op/syncAllUsers/ HTTP/1.1] com.day.crx.security.ldap.LDAPUserSync LDAP synchronization: 0 of 0 users synchronized in 0 seconds

Reason

This error is caused by your LDAP settings. In ActiveDirectory (AD), for example, there is a maxpagesize limit set to 1000 by default. This is the maximum number of results returned for any given LDAP query, including CQ user synchronization.  For more information see: http://support.microsoft.com/kb/315071?wa=wsignin1.0

Solution

You have a few options to avoid this problem:

  1. ask your LDAP administrator to increase the maxpagesize on your LDAP server
  2. use filters in your LDAP queries to reduce the number of LDAP entries returned so that you do not hit this limit

reference: (40240/CRX-3043)

VN:F [1.9.22_1171]
Was this helpful? Please rate the content.
Rating: 6.3/10 (4 votes cast)

CQ5.5: When to restart CQ after installing a service pack

Issue

If you are installing a service pack (SP) on top of CQ5.5 you will see a dialog recommending to restart the instance after you have run the SP installation:

Do not restart the instance at this point, as the contents of the service pack are still being extracted and installed in the background.  Restarting at this point could result in unknown problems, and you may have to repeat the SP installation.

Solutions

You can monitor the log output in error.log and wait until the log no longer has new “BundleEvent STARTED” entries, before restarting the instance.  This usually takes 2 – 5 minutes depending on server specifications.

Monitoring log output may not be a good solution for large enterprise organisations which may have many CQ instances to update, and may need to use some kind of automated install script or process documentation.  In this case, you can either add a pause to the installation documentation (e.g. 15 or 30 minutes), or use a script to check for installation completion as described under 2 below.

1. Monitor the log output to figure out when to restart

The release notes for SP2.1 do contain instructions relating to this process (http://dev.day.com/docs/en/cq/current/release_notes_service_pack_2.html):

Quickstart Install Process

  1. Login to Package Share and download SP2 package: cq-service-pack-5.5.2.zip
  2. Back in Package Manager – Install package
  3. After the package install is done – the PackageManager tells you to restart. DO NOT RESTART. The actual install of the package only starts now in background, given that the packages have been placed in /install folders. The best way to follow the process of the install is to tail the error.log
    The background install starts with “com.day.jcr.vault.packaging.impl.ZipVaultPackage Extracting day/cq550/update:cq-update-pkg:5.5.8″ and stops with bundles been restarted – best seen by “BundleEvent STARTED” log entries.
  4. After the error.log goes quiet with “BundleEvent STARTED” messages
  5. Restart the instance
  6. The Welcome Screen should now show the updated Version String: Adobe CQ, Version 5.5.0.20120220 Service Pack 2

2.  Use a script to automatically check for installation completion

You can use the script below which polls the server to check when the SP contents have been extracted, and then waits another few minutes for the relevant bundles to be started.  You can use the script on its’ own, or you could integrate it into existing scripts which you use to automatically install the CQ servicepack.

1. use a script similar to the following (designer for CQ5.5 SP2.1, you may need to adjust the cq-update-pkg version for other service packs)

count=0
res=1
until [ $res -eq 0 ]
do
    curl -u admin:admin -D- http://<cq_server_hostname>/etc/packages/day/cq550/update/cq-update-pkg-5.5.10.zip/jcr:content/vlt:definition/lastUnpacked.json 2>/dev/null | head -1 | grep -q “HTTP/1.1 200″
    res=$?
    if [ $((count++ % 10)) -eq 0 ]
     then
     echo “Waiting for service pack installation to finish…”
    fi
    sleep 1
done
sleep 300
echo “Service pack installation complete. You can restart the instance now.”

2. start the script in a terminal
3. install SP2.1
4. check the script output and await the completion message

5. restart the instance

reference: (39810/CQ5-22648)

VN:F [1.9.22_1171]
Was this helpful? Please rate the content.
Rating: 8.3/10 (8 votes cast)

CQ5: new page/site buttons disabled in WCM siteadmin

Issue

If you are using WCM siteadmin and wish to create a new page/site using the available buttons, they may appear disabled so that you are unable to click on them.  Firstly, you should check your permissions for these actions and/or check with an administrator or admin account.  If these problems persist it may be related to an issue in your repository structure.

Reason

These buttons can also be disabled if there is an invalid Page node in the /content tree.  A cq:Page node must have a child named jcr:content of type cq:PageContent, otherwise it is invalid and can lead to this issue.  The root /content node is not of type cq:Page and therefore does not require a jcr:content child of type cq:PageContent, but every other Page node below /content should have this structure.

It seems that if the invalid node is a top-level page/site in the content tree (e.g. /content/geometrixx) then it will affect the site actions for all other top-level nodes, and other nodes in that specific tree.
If the invalid node is a sub node (e.g. /content/geometrixx/en/services), then it seems to only affect the site actions for that level in that tree.

Such invalid nodes can appear in the tree if they were created outside of WCM (i.e. using CRXDE, or Content Explorer), or by importing a package containing such invalid nodes.

Solution

Check your content tree for such invalid page nodes, and repair the nodes as required, by creating a jcr:content child node of type cq:PageContent.

reference: (37890)

VN:F [1.9.22_1171]
Was this helpful? Please rate the content.
Rating: 10.0/10 (2 votes cast)

CQ5.5: javax.jcr.RepositoryException: Unable to register data store in cluster

Issue

If you are installing and starting a new CQ instance you may experience the following exception:

*ERROR* [FelixStartLevel] org.apache.jackrabbit.core.RepositoryImpl failed to start Repository: Unable to register data store in cluster.
javax.jcr.RepositoryException: Unable to register data store in cluster.

Caused by: java.net.UnknownHostException: <server_hostname>: <server_hostname>
at java.net.InetAddress.getLocalHost(InetAddress.java:1360)
at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:211)
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:200)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366)
at java.net.Socket.connect(Socket.java:529)
at java.net.Socket.connect(Socket.java:478)
at java.net.Socket.<init>(Socket.java:375)
at java.net.Socket.<init>(Socket.java:218)
… 56 more

Reason

This typically happens if the name returned by the “hostname” command cannot be resolved.

Solution

Add the following entry to /etc/hosts (replacing <server_hostname> with the hostname of the server where the CQ instance is running):

127.0.0.1 <server_hostname>

VN:F [1.9.22_1171]
Was this helpful? Please rate the content.
Rating: 8.8/10 (5 votes cast)

CQ5.5: NullPointerException for wcm-mobile-core after installing SP1 or SP2.1

Issue

If you have installed CQ 5.5 SP1 or SP2.1 and restarted the instance you may notice the following exception in the logs on startup:

ERROR [Background Update com.day.cq.wcm.cq-wcm-mobile-core (219)] com.day.cq.wcm.cq-wcm-mobile-core [com.day.cq.wcm.mobile.core.impl.redirect.RedirectFilter]
The bindStats method has thrown an exception (java.lang.NullPointerException) java.lang.NullPointerException
at com.day.cq.wcm.mobile.core.impl.redirect.RedirectFilter.bindStats(RedirectFilter.java:173)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.felix.scr.impl.helper.BaseMethod.invokeMethod(BaseMethod.java:227)
at org.apache.felix.scr.impl.helper.BaseMethod.access$500(BaseMethod.java:38)
at org.apache.felix.scr.impl.helper.BaseMethod$Resolved.invoke(BaseMethod.java:591)
at org.apache.felix.scr.impl.helper.BaseMethod$NotResolved.invoke(BaseMethod.java:548)
at org.apache.felix.scr.impl.helper.BaseMethod.invoke(BaseMethod.java:472)

Reason

This error is caused by an issue in the mobile redirect servlet in SP1 and SP2.1.  It will only affect this servlet, which gathers usage statistics on various categories of mobile devices.

Solution

If you do not require a fix for this servlet you can ignore this error.  The issue is currently scheduled to be fixed in the next service pack for CQ5.5.  If you require an urgent solution to this issue you can contact support through Daycare.

reference: (CQ5-18788/NPR-2071)

VN:F [1.9.22_1171]
Was this helpful? Please rate the content.
Rating: 0.0/10 (0 votes cast)

CQ5.5: Invalid links to DAM assets containing spaces in the file-name

Issue

If you are using the CQ5.5 authoring environment to add links to DAM assets through the rich-text editor dialog by drag-and-drop, then you may notice that some of these links will be marked invalid after clicking OK on the dialog.

A invalid link appears like the “banking” text below, whereas a valid link appears like the “investors” text.

You may also see errors similar to the following in the error.log:

*ERROR* [0:0:0:0:0:0:0:1 [1344244721052] GET /libs/wcm/core/content/pageinfo.json HTTP/1.1] com.day.cq.wcm.core.impl.servlets.PageInfoServlet Request path does not resolve to a resource: /content/dam/geometrixx/documents/GeoSphere_D%20a%20tasheet.pdf

Reason

The links are marked invalid when the assets in DAM contain spaces, or other characters such as !%$üäö, in the file-name (e.g. GeoSphere_D a tasheet.pdf).  Such file-names are being parsed by a URL encoder and the characters get converted by a URL encoder at the wrong place.

Workaround

You can workaround this issue by creating the link with the in-place editor, and also creating the link manually using the link button in the rte dialog, and selecting the document through the browse function. Only drag&drop directly onto the text in the rte dialog is not working.

Solution

This is a product issue with the rich-text widget and has been fixed in later product versions.

If you wish to resolve this issue in CQ5.5 you should contact support through Daycare and request hotfix “cq-5.5.0-hotfix-2390-1.zip”.  This hotfix has dependencies on other components, so the support team can advise you on installation order and requirements.

reference: (37103/NPR-2390)

VN:F [1.9.22_1171]
Was this helpful? Please rate the content.
Rating: 8.0/10 (1 vote cast)

CQ5.5: MCM emails contain URLs to author instead of publish

Issue

If you are using the Newsletter feature in MCM to send emails to lists of contacts you may notice that the URLs for assets in the email are pointing to the author instance, rather than the publish instance.  The links to the author instance will not work for external users, so the assets in the email will not show up.

Reason

This is a documentation issue as there is some further configuration required to substitute the links in the newsletter email so they point to the publish instance, rather than the author instance.  This will be addressed in a later version of CQ.

Solution

To resolve this issue in the meantime you should do the following steps:

  1. login to the system console on author (e.g. http://localhost:4502/system/console/configMgr)
  2. in the configuration tab search for the “Day CQ MCM Newsletter” bundle and open it
  3. take note of the fake host name in “Lookup for Sender Host” field (by default it is –publish–), i.e. the field should have http://–publish– in it
  4. open CRXDE Lite and goto /etc/map/http
  5. create a Node named –publish– of type sling:Mapping
  6. add a String property sling:match with value –publish–.80
  7. add a String property sling:redirect with value of your publish instance host name or IP including port(e.g. http://publishhost:4503)
  8. click Save All

Now when you send the newsletter it should substitute the author URL with the publish URL.

reference: (37433/CQ5-15440)

VN:F [1.9.22_1171]
Was this helpful? Please rate the content.
Rating: 8.5/10 (4 votes cast)

CQ5.5 SP1: MalformedPathException: ‘:redirect’ is not a valid path. Prefix must not be empty

Issue

If you have updated to CQ5.5 Update 1 and you attempt to access a user profile page, for example the admin profile, as follows:

http://<server>:<port>/home/users/a/admin/profile.form.html/content/geometrixx/en/toolbar/profiles/edit
or
http://<server>:<port>/home/users/a/admin/profile.form.html/content/geometrixx/en/toolbar/profiles/view

you will see the following exception in the error.log:

*ERROR* GET /home/users/a/admin/profile.form.html/content/geometrixx/en/toolbar/profiles/edit HTTP/1.1] com.day.cq.wcm.core.impl.WCMDebugFilter Exception:  org.apache.sling.api.scripting.ScriptEvaluationException:
    at org.apache.sling.scripting.core.impl.DefaultSlingScript.call(DefaultSlingScript.java:385)

Caused by: java.lang.IllegalArgumentException: javax.jcr.RepositoryException: Failed to resolve path :redirect relative to node /home/users/a/admin/profile

Caused by: org.apache.jackrabbit.spi.commons.conversion.MalformedPathException: ‘:redirect’ is not a valid path. Prefix must not be empty

Reason

This issue is caused by a regression in the 2.1 version of Sling which has been integrated with CQ5.5 SP1: https://issues.apache.org/jira/browse/SLING-2518

The issue does not occur with the 2.0.10 version of Sling included with CQ5.5.

Solution

This issue will be resolved in the next release of CQ5.5 SP2.

reference: (37322/CQ5-18799)

VN:F [1.9.22_1171]
Was this helpful? Please rate the content.
Rating: 10.0/10 (1 vote cast)

CQ5.4: how to force a delay between workflow steps

Information

If you are using workflows in Adobe CQ5.4 you may wish to have a customized delay between certain workflow steps.  It is possible to cause a delay using the timeout functionality which has pre-defined values (immediate, 1h, 2h, 6h etc…), and then select the Auto Advance timeout handler to move the workflow to the next step.

In some cases you may also want to define your own delay intervals rather than use the pre-defined values.  This is possible in CQ5.4 by creating an overlay of:

/libs/cq/workflow/components/model/step/tab_common/items/timeout/items/timeout/options

to:

/apps/cq/workflow/components/model/step/tab_common/items/timeout/items/timeout/options

and then you can make a copy of one of the existing nodes (1h, 2h etc…), and change the values to suit your needs.  The value should be in seconds and not milliseconds.

This new value will then appear in the workflow step configuration dialog, under the list of timeout values, and the step will timeout after the specified interval.

reference: (37175)

VN:F [1.9.22_1171]
Was this helpful? Please rate the content.
Rating: 4.0/10 (4 votes cast)

CQ5: Loading an image from a resource in a custom image renderer

Issue

If you are using a custom image renderer to handle image renders, you may notice that you cannot create a valid Image object from a referenced Asset in the DAM.  You are probably using code similar to the following:

//Note c is an ImageContext object
Resource r = c.request.getResourceResolver().getResource("/content/dam/geometrixx/travel/train_station_woman.jpg");
Image i = new Image(r);
if (!i.hasContent()) {
    resp.sendError(HttpServletResponse.SC_NOT_FOUND);
    return;
}

In the example code snippet above, hasContent() will always return false.

Reason

You cannot simply create an image or a layer directly from an image/file resource as obtained from the resolver.  You must first use the Asset class to get a rendition of the image.  Then you can work with that.

Solution

Use code similar to the following

//Note c is an ImageContext object
Resource  r = c.request.getResourceResolver().getResource("/content/dam/geometrixx/travel/train_station_woman.jpg");
Asset a = r.adaptTo(Asset.class);
Layer layer = ImageHelper.createLayer(
      c.node.getSession(),
      a.getCurrentOriginal().getPath()
)

reference: (36895)

VN:F [1.9.22_1171]
Was this helpful? Please rate the content.
Rating: 5.0/10 (5 votes cast)

CQ5.4: How to display a confirmation dialog when activating pages

Issue

If you are using CQ5.x you will notice that there is a confirmation dialog for deleting/deactivating pages in the WCM console.  No such confirmation dialog is presented when you activate a page.  In some projects it may be a requirement to present such a confirmation dialog for activation also.

Solution

You will have to overlay:
/libs/cq/ui/widgets/source/widgets/wcm/SiteAdmin.Actions.js
to
/apps/cq/ui/widgets/source/widgets/wcm/SiteAdmin.Actions.js
Create the same folder structure in apps and then copy the SiteAdmin.Actions.js node from libs to the same folder in apps. This will ensure the jcr:content node under the JS file is also copied.

Then edit the SiteAdmin.Actions.js from apps.  You should replace the CQ.wcm.SiteAdmin.activatePage function with the lines (435-520) from this SiteAdmin.Actions.js file.

Note

Ideally you should not not completely overlay the siteadmin.Actions.js as you might run into problems when a SP brings a new SiteAdmin.Actions.js with it. Instead just overlay the function you want to change.  Use the clientlib approach and create a new JS file, attach it to the same clientlib as the SiteAdmin.Actions.js and redefine the function you want to change in that new JS file.

reference: (35823)

VN:F [1.9.22_1171]
Was this helpful? Please rate the content.
Rating: 0.0/10 (0 votes cast)

CQ5.4: Files uploaded to DAM saved with incorrect mime-type

Issue

If you are uploading specific types of files (Word, PPT, SWF….) to CQ5 DAM, you may notice the the files are saved to the repository with a different mime-type, for example as images.

You may also notice warnings and errors in the error.log similar to the following:

*WARN* [JobHandler: /etc/workflow/instances/2012-06-20/model_171459455015372:/content/dam/geometrixx/documents/slides.ppt/jcr:content/renditions/original] com.day.cq.dam.commons.handler.StandardImageHandler extractImageInfo: error while reading metadata from image [/content/dam/geometrixx/documents/slides.ppt]:  org.apache.sanselan.ImageReadException: Can’t parse this format.
    at org.apache.sanselan.Sanselan.getImageParser(Sanselan.java:621)
    at org.apache.sanselan.Sanselan.getImageInfo(Sanselan.java:587)
    at org.apache.sanselan.Sanselan.getImageInfo(Sanselan.java:479)
    at com.day.cq.dam.commons.handler.StandardImageHandler.extractImageInfo(StandardImageHandler.java:207)
    at com.day.cq.dam.commons.handler.StandardImageHandler.extractMetadata(StandardImageHandler.java:244)
    at com.day.cq.dam.commons.handler.StandardImageHandler.extractMetadata(StandardImageHandler.java:145)
    at com.day.cq.dam.core.process.ExtractMetadataProcess.execute(ExtractMetadataProcess.java:65)

*ERROR* [JobHandler: /etc/workflow/instances/2012-06-20/model_171459455015372:/content/dam/geometrixx/documents/slides.ppt/jcr:content/renditions/original] com.day.cq.dam.core.impl.cache.CQBufferedImageCache Error while loading image /content/dam/geometrixx/documents/slides.ppt/jcr:content/renditions/original: javax.imageio.IIOException: No decoder available to load the image
*ERROR* [JobHandler: /etc/workflow/instances/2012-06-20/model_171459455015372:/content/dam/geometrixx/documents/slides.ppt/jcr:content/renditions/original] com.day.cq.workflow.impl.job.JobHandler Process execution resulted in an error: java.io.IOException: No decoder available to load the image com.day.cq.workflow.WorkflowException: java.io.IOException: No decoder available to load the image
    at com.day.cq.dam.core.process.CreateThumbnailProcess.execute(CreateThumbnailProcess.java:145)
    at com.day.cq.workflow.impl.job.HandlerBase.executeProcess(HandlerBase.java:172)
    at com.day.cq.workflow.impl.job.JobHandler.process(JobHandler.java:122)
    at org.apache.sling.event.jobs.JobUtil$1.run(JobUtil.java:272)
    at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)
Caused by: java.io.IOException: No decoder available to load the image
    at com.day.cq.dam.core.process.CreateThumbnailProcess.execute(CreateThumbnailProcess.java:126)
    … 6 more

Reason

This is a product bug in CQ5.4 and earlier versions, as it does not correctly handle the dc:format metadata property in particular files.  When these documents contain images with dc:format=image/jpeg, CQ assumes that this property applies to the whole document. Therefore the file gets uploaded into /content/dam with a node ‘metadata’ which has property dc:format=image/jpeg.

Solution

The issue has been fixed in CQ5.5 as we have re-engineered the component responsible for handling the mime-type detection for files uploaded to DAM.  When you update to CQ5.5 you will have the final solution to this issue.

As a workaround for earlier versions you should follow these steps:
1. create a file reset-mimetype.ecma under etc/workflow/scripts
2. use the script in the attached file: reset-mimetype.ecma
3. save it
4. edit the workflow model (“DAM Update Asset” workflow)
5. add a “Process step” after the “Metadata extraction” step
6. edit the “Process step”
7. select the etc/workflow/scripts/reset-mimetype.ecma script
8. select the “Handler Advance” checkbox
9. save the workflow
Now the file formats should be correctly identified when uploading to DAM.

reference: (35508/CQ5-13504)

VN:F [1.9.22_1171]
Was this helpful? Please rate the content.
Rating: 5.0/10 (3 votes cast)

CQ5: NoInitialContextException: Cannot instantiate class: com.day.util.jndi.provider.MemoryInitialContextFactory

Issue

If you have installed the Sharepoint connector for CQ5 you may encounter the following exception in the log:

*ERROR* [FelixStartLevel] com.day.crx.spi.sharepoint.osgi.impl.SharepointRepositoryImpl Failed to bind repository to JNDI: crx2sharepoint.repository javax.naming.NoInitialContextException: Cannot instantiate class: com.day.util.jndi.provider.MemoryInitialContextFactory [Root exception is java.lang.ClassNotFoundException: com.day.util.jndi.provider.MemoryInitialContextFactory]
at com.day.commons.simplejndi.impl.InitialContextProxy.getInitialContext(InitialContextProxy.java:75)
at com.day.commons.simplejndi.impl.InitialContextProxy.getDefaultInitCtx(InitialContextProxy.java:121)
at com.day.commons.simplejndi.impl.InitialContextProxy.getURLOrDefaultInitCtx(InitialContextProxy.java:116)
at com.day.commons.simplejndi.impl.InitialContextProxy.rebind(InitialContextProxy.java:146)
at javax.naming.InitialContext.rebind(InitialContext.java:408)
at com.day.crx.spi.sharepoint.osgi.impl.SharepointRepositoryImpl.registerJNDI(SharepointRepositoryImpl.java:532)
at com.day.crx.spi.sharepoint.osgi.impl.SharepointRepositoryImpl.activate(SharepointRepositoryImpl.java:283)

Reason

This error occurs if you are attempting to configure the Sharepoint connector to connect to Sharepoint 2010.  The Sharepoint connector (currently version 2.0.4) does not support Sharepoint 2010 at the moment.

Ensure you have read the instructions to install and configure the Sharepoint connector from the documentation:

http://dev.day.com/docs/en/crx/connectors/sharepoint/current.html

Solution

Support for Sharepoint 2010 will be added in a later version of the Sharepoint connector.

reference: (35371/CON-737)

VN:F [1.9.22_1171]
Was this helpful? Please rate the content.
Rating: 7.0/10 (2 votes cast)