JRS/LQE query usage in custom widgets
We are developing a custom widget that will copy some artifacts from one module to another based on certain conditions. We are using JRS / LQE query that will give this list of artifacts (with filtering done based on conditions) for the selected module.
Is there any consequences if we use LQE query (instead of DNG APIs) in the widget? What do you recommend?
3 answers
Yes you can use a JRS report result as the basis for your widget, and it doesn't matter what data source it was built from.
However, you need to be careful with this approach as your widget will depend completely on the report being publicly accessible, but will also depend on the existence of the report, and on its format, so you need to make sure it's labelled carefully and not able to be edited by anybody.
Use the Report Builder to create the report and save it, and then use the "Export report to ELO Publishing" option. This will give you a URL that can be used in ELO Publishing to create a document, but it can also be used to retrieve the report results as an XML document that you can then use programmatically in your widget.
I don't believe JRS or LQE have public APIs, so that can't be recommended.
You could use OSLC Query - you can query for the artifacts in a module and select the properties that are returned. Use oslc.where value oslc_rm:module=<moduleURI> and oslc.select could be * or the specific properties you want to work from. It's possible, if e.g. the filter has only and terms or can be expressed using OSLC Query in, that you can include the filter in the oslc.where statement, or you can post-process the results yourself for more complicated filters.
Comments
Thank you, Ian for your time. I didn't get "JRS/LQE has no public API". If I create a JRS report and share it with other users can access the LQE query, right? Do you see any issue if we use this query to fetch the data in our custom widget?
Can I make LQE public so that all users can access the JRS query (and in turn we use it in our custom widget to show the data)?
I actually disagree with Ian here. With respect.
It's not a public API, per se, but it does face the user. Create a report in LQE. Save the report. Run the report. Export the report to Excel. One of the three links given for the Excel report is to the query that runs -- if you go to that URL, you get the data in the export in XML format. So while it's not a public API, once you have that link, you essentially get everything you need to use as if it was an API.
That said Vishal, while you can take this approach, if the XML changes because some user goes in and messes with it, or the report is run for configuration A but the widget is in configuration B, you might have some problems.
Good luck!
Kevin Murphy
IBM Champion
Comments
Vishal Kothari
May 23 '25, 1:14 a.m.Can anyone help please?