CQ version | Community
Skip to main content
This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.

13 replies

Level 3
Dec 12, 2022 4:52 PM UTC

For AEM 6.5 - programatically we can get the aem product version using below:

 

com.adobe.granite.license.ProductInfoProvider; 
com.adobe.granite.license.ProductInfo;
@OSGiService
private ProductInfoProvider productInfoProvider;
ProductInfo productInfo = productInfoProvider.getProductInfo(); 
productInfo.getVerion().toString(); //6.5.13.0
productInfo.getShortVersion(); //6.5

 

 

Translate
Level 2
May 10, 2019 2:32 PM UTC

There is a ReST endpoint at /libs/granite/operations/content/systemoverview/export.json. This is used from the operations dashboard. It exposes the product info as well.

Translate
joerghoh
Employee
Sep 11, 2018 5:47 AM UTC

Even if this information is available at some location in the JCR, it is not advised to use read from there. The official API is the ProductInfo, and any other way to to determine the product version might just works by incidence.

Jörg

Translate
arunpatidar
New Participant
Sep 10, 2018 12:36 PM UTC

Hi,

If you need to expose info at client side, then you can do it with java API com.adobe.granite.license.ProductInfo which is suggested by Kautuk to get info and assign to javascript variable, so it can be accessible at client side.

If you are planning to do via reading node using JCR API, then also you won't be able to expose at client side until it is not exposed as javascript variable.

So go ahead and use JAVA API dedicated to access product info and expose value as javascript variable.

Translate
Arun Patidar
rahulj60393424
New Participant
Sep 10, 2018 11:13 AM UTC

Hi kautuksahni​,

I had already found both of them. But the problem is:

In status-productinfo, it is not a perfect json and still need to be parsed a little to get product version.

And in second method, I need to create a servlet first as I want to get product info on client side.

Also, can you tell me where is the info saved now, like earlier there used to be a node in /libs/cq but now I can't find any node.

Translate
rahulj60393424
New Participant
Sep 10, 2018 10:43 AM UTC

This doesn't work in recent AEM versions. Could you please help how to get product info in json format for AEM 6.3/4

Translate
kautuk_sahni
Employee
Nov 25, 2015 3:20 AM UTC

Hi Jorg

This is awesome. This community is enriching all of us. 

Thanks for the information.This is added to my kitty now smiley.

Thanks and Regards

Kautuk Sahni

Translate
Kautuk Sahni
joerghoh
Employee
Nov 24, 2015 5:24 PM UTC

Instead of relying the value in the JCR you can also query the ProductInfoService [1], which also provides you these information.

kind regards,
Jörg

[1] https://docs.adobe.com/docs/en/aem/6-0/develop/ref/javadoc/com/adobe/granite/license/ProductInfoService.html#getInfos%28%29

Translate
kautuk_sahni
Employee
Nov 24, 2015 11:45 AM UTC

Hi

The product information is stored on the node "/libs/cq/core/productinfo" , you can read the information from those nodes.

For Reading JCR nodes, please have a look at any of these options:-

Link:- https://helpx.adobe.com/experience-manager/using/jqom.html

Link:- https://helpx.adobe.com/experience-manager/using/using-query-builder-api1.html (Query Builder)

Link:- https://helpx.adobe.com/experience-manager/using/querying-experience-manager-data-using1.html (JCR API)

 

[Jorg Hoh's Soultion]

Instead of relying the value in the JCR you can also query the ProductInfoService [1], which also provides you these information.

[1] https://docs.adobe.com/docs/en/aem/6-0/develop/ref/javadoc/com/adobe/granite/license/ProductInfoService.html#getInfos%28%29

 

 

 

I hope this would help you.

Thanks and Regards

Kautuk Sahni

Translate
Kautuk Sahni