How to connect external XML DB via XQJ driver?

Oxygen general issues.
dsukhoroslov
Posts: 3
Joined: Mon Jul 11, 2016 5:33 pm

How to connect external XML DB via XQJ driver?

Post by dsukhoroslov »

Hi,

I'm trying to connect from Oxygen Editor v.18 to my own XML DB. It does implement XQJ driver, so specified custom XQJ Data Source and XQJ Connection. I set all connection properties and marked the connection as 'Browsable' in Data Source settings. The connection appears in Data Source Explorer panel, but nothing more. I do not see any attempt to connect to my DB on the server side and I don't see any more data in Oxygen. BTW, the URL property in Data Sources/Connections list is also empty, may be that is the reason? Should my driver publish some special property then?
I turned on debug logging, but don't see anything suspicious in the log.

Thanks, Denis.
adrian
Posts: 2879
Joined: Tue May 17, 2005 4:01 pm

Re: How to connect external XML DB via XQJ driver?

Post by adrian »

Hi,

How did you mark the connection as "Browsable"? The GUI doesn't allow it (as tested) for XQJ connections, because that's a feature that's not available for XQJ.
In short, you cannot browse an XQJ connection in the Data Source Explorer view, you can only use the XQJ data source/connection as an XQuery transformer (in XQuery transformation scenarios).

Regards,
Adrian
Adrian Buza
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
dsukhoroslov
Posts: 3
Joined: Mon Jul 11, 2016 5:33 pm

Re: How to connect external XML DB via XQJ driver?

Post by dsukhoroslov »

Hi Adrian,

Yes, initially my connection was not browsable, but after a couple of more edits of connection properties, the browsable checkbox appears, don't know why.
Do I need to implement some standard Oxygen interface in order to make my connection browsable?

Thanks, Denis.
adrian
Posts: 2879
Joined: Tue May 17, 2005 4:01 pm

Re: How to connect external XML DB via XQJ driver?

Post by adrian »

Hi,

The browsable checkbox appears due to a bug. I was able to reproduce the problem and have logged it on our issue tracking tool to be resolved.

I'm afraid that the XQJ connection cannot be made browsable in the Data Source Explorer view. There is no public API for the Data Source Explorer view.

The solution would be to implement a custom view (similar to the Data Source Explorer view) that implements browsing for your database, but that is not a trivial task. The Oxygen SDK can be used for that. It is available here:
https://www.oxygenxml.com/oxygen_sdk.html
You need to implement a workspace access plugin that creates your custom view:
https://www.oxygenxml.com/oxygen_sdk/ox ... ugins.html

Regards,
Adrian
Adrian Buza
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
dsukhoroslov
Posts: 3
Joined: Mon Jul 11, 2016 5:33 pm

Re: How to connect external XML DB via XQJ driver?

Post by dsukhoroslov »

Adrian,

But other native XML DBs (eXist, MarkLogic, ..) are there. Do they provide some kind of plugin, or it was Oxygen's internal implementation?

Thanks, Denis.
adrian
Posts: 2879
Joined: Tue May 17, 2005 4:01 pm

Re: How to connect external XML DB via XQJ driver?

Post by adrian »

Hi,

Oxygen provides native support for each of these XML DBs. There is no generic API that covers all of them.

Regards,
Adrian
Adrian Buza
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
Post Reply