Java API accessed from Angular/Node - javascript

I found a project online (Jboss Teiid) that seems to only have a JDBC/Java API for connecting and managing the tool. I want to build a web-app (preferably in Angular) to manage Teiid, but I'm honestly not sure the best way. Would it be best to create a REST API to interact with Teiid since it only has a Java API? The JDBC driver is good for querying data, but the JAVA API is the only way to administer the tool and perform admin functions which i need.
Is there a better way? if there was a javascript client this would be easy, i'm just not sure the best route to connect my javascript web-app to this java tool.
Any thoughts/guidance greatly appreciated!
Thanks
API docs: http://docs.jboss.org/teiid/8.11.0.Final/apidocs/

If you are working with a JBoss stack, then might as well use their tooling. JBoss Forge can scaffold both a JAX-RS REST service and your Angular front-end at the same time.

Related

How to create a web portal using angularJS

Im fresh out of the academy and have been given my first project. I need to create a web portal that can interface with RESTFUL services. Can anyone advise me on where and how to start?
After I create the basic html and css Web page I have to integrate the CRUD module. Should I look at creating a single page application?
Any advise is appreciated, thanks.
As Matus Dubrava as mentioned, this is off-topic and a very broad question. But I can help you with some guideline -
You will be having a database (mysql, postgresql, mongo etc.), an API server (can be built with Java Spring Boot, Python Django, NodeJS, PHP etc.) and lastly a frontend application (can be built with angularjs, reactjs etc.).
First, you have to sort out what you already know among these and then plan ahead what other modules you need to learn. After deciding what technologies you will use, you can google the tutorials and sample code for that technology. If I can help more ask me out.
Hope this helps.

How IBM Filenet Integrated with Angular application

I'm not familiar with Filenet.
I am using IBM FileNet as document management system. How Can I consume Filenet web services Apis in my AngularJs Application.
Please Help me out, if anyone has tried this.
Thanks
Use the FileNet api to develop a class or web service that returns the records from FileNet and then have the Angular app digest the records returned.
See:
http://www.ibm.com/developerworks/data/library/techarticle/dm-0810carpenter/
and
https://www.ibm.com/support/knowledgecenter/SSNW2F_5.2.1/com.ibm.p8.ce.dev.ce.doc/gs_concepts.htm
In very simple terms, FileNet is a just another content Management system.
It has an API that you use to query the backend(Content Engine) for a
documents that matches your criteria.
Each document you get has content(most of the time, a physical file), and properties (In fileNet terms MetaData).
You will need some technology in the middle to translate the data you aquired to a form that is consumable by Angular (JSON). Something that we can call for the moment a Rest Engine.
This "Engine" should help you expose end points (Simple web addresses http:///Path/To/Data) that is attached to java methods that returns the JSONs you made.
To be able to pull that out successfully, you need to have a good grasp of Angular (Services), and then knowledge of one "Rest Engine" (or something you can use similarly, even a servlet would help you for the moment), and finally a very simple knowledge of FileNet basic operations.
A RESTFUL service tier that leverages FileNet EJB API which are much faster than WS APIs (esp. when in a distributed deployed environment) is to be built for this if you are working in an enterprise-level project.

Is it possible to have backend written in Haskell and frontend with Javascript?

currently I'm working on this project (https://github.com/Giegling/addressbook) and for the backend I use Node.js with Express framework, for the frontend Angularjs. Is it possible to "translate" the backend to Haskell without touching the frontend? If it's possible, which framework should I use? (Yesod, scotty...)
Thanks
Your server simply exposes a HTTP API to your angular app. You can implement that functionality in any web framework (or even without a framework) in pretty much any language.
Yesod is probably the most popular and well documented Haskell framework (personal opinion), so I guess you can start with that.

Node.js Rest Framework

I plan to write a rather large-scale web application using JavaScript. I believe I will be developing the webapp using CanJS to organize my client-side pieces.
I am strongly considering using Node.js for my server-side component, but I was wondering what the best way to set up Node to accept and handle REST requests. I did some Googling and came across something called Express. Any comments on this?
Any help/suggestions would be greatly appreciated.
restify is a node.js module built specifically to enable you to build correct REST web services.
http://mcavage.github.com/node-restify/
Express is more directed towards full web application (rendering HTML, etc). Restify is just for web services.
Besides, the guy who created Restify works at Joyent, the company where Ryan Dahl developped Node.js (which is kind of guarantee quality).
For REST request handling, express-resource is a more focused solution than railwayjs that's also built on top of expressjs.
You can try http://railwayjs.com/ it is build on top of http://expressjs.com/
Express is nice and fast :) railway has similar stack to ruby on rails.
http://expressjs.com is the de factor standard, does Sinatra-like routing. If you want real easy automatic generation of resources (sort of Rails-style), try one of those libraries above.
If you want it real simple on top of express, try http://github.com/deitch/booster
Disclosure: I just released Booster this week.

can we use couchdb for web application development?

I was wondering whether we can use java script for application development and use couchdb to serve it. I was also imagining jquery as the java script library. Do you think this is possible?
Check out using CouchApp. CouchApp allows you to build your application in JavaScript and host it out of CouchDB. Its a great way to learn CouchDB and its a very rapid development environment.
CouchApp
Sure you can. Following is a link to a blogging project being developed with couchdb as the backend and PHP as the front. Its open source so you might get some ideas by looking at its code.
Arik Blogging Software
Like others pointed out, CouchApps are one of they key features of CouchDB. CouchDB's built-in admin interface “Futon” is built that way. — The example application in CouchDB: The Definitive Guide (free online book) is also a CouchApp: http://guide.couchdb.org/

Categories