XML DB as a RESTful interface?
475642May 31 2007 — edited Jul 6 2009Hi!
We are thinking about offering http (RESTful) access to some departments in our
company.
However, all our data sits in "normal" database tables.
The benefit is that it needs absolutely no installation effort on the clients, we just provide some example VBScripts using MSXML and our customers cann access the data.
Access control is supposed to be done using kerberos and row level security.
So, "we", the inside people and views/packages in other database schemas will mostly use SQL and PL/SQL to upload and process data, but the people of the other departments (the "others") will be using http.
We are just learning to start about web services and such and I'm wondering whether XML DB can offer us something here.
Basically we plan to do this:
- connect using http (typically msxml)
- accessing data like
* http://ourapp...com/partsdb/partsbyname/part_x (delivers XML with all attributes, the node data and hrefs to child nodes)
* http://ourapp...com/partsdb/partsbyname/resistor5K/cost (delivers <cost unit="EUR">0,05</cost>)
* http://ourapp...com/partsdb/partsbyname/resistor5K/datasheet (delivers a pdf document as mime type "application/pdf")
and so on.
I guess I can probably map the tables into hierarchical XML views. But is this suitable for the XML repository folder metaphor? Can I map the tables into a folder structure so that XML DB can serve "get" requests with paths at all?
I'd like to do puts, posts and deletes too, each mapped to the corresponding update/insert/delete statements on the underlying table.
For such requests how to get from a URL path to the corresponding table(s)?
Would resource_view and path_view help me? I've read about using instead of triggers in such a situation. Can I even access the path in an instead of trigger?
If possible at all I'd like to avoid oracle AS. If I need it then still I'd like to keep as much as possible of the application in the database.
Any help is appreciated.
Lots of Greetings!
Volker