Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » Orion (Archived) » How to get started with OrionNode?
How to get started with OrionNode? [message #1007032] Mon, 04 February 2013 07:37 Go to next message
Joe Or is currently offline Joe OrFriend
Messages: 1
Registered: February 2013
Junior Member
We have just downloaded OrionNode,
We would like to:
a) Read the code, understand the structure
b) see what REST API the node server exposes
c) add our own REST APIs

How do you recommend us to prcced?

Thanks!
Re: How to get started with OrionNode? [message #1007444 is a reply to message #1007032] Tue, 05 February 2013 21:19 Go to previous messageGo to next message
John Arthorne is currently offline John ArthorneFriend
Messages: 176
Registered: July 2009
Senior Member
Quote:

a) Read the code, understand the structure
b) see what REST API the node server exposes
c) add our own REST APIs


a) You can clone the source code here:

git://git.eclipse.org/gitroot/orion/org.eclipse.orion.client.git

The orionode source is all under /modules/orionode

b) Documentation of the server API can be found here:

http://wiki.eclipse.org/Orion/Server_API

c) I'm not sure there is an easy way to plug in your own APIs, but I'll prod Mark to give some suggestions on where to start.

John
Re: How to get started with OrionNode? [message #1007453 is a reply to message #1007444] Tue, 05 February 2013 22:11 Go to previous message
Mark Macdonald is currently offline Mark MacdonaldFriend
Messages: 35
Registered: July 2009
Member
To build on what John said above:

a) Within the modules/orionode folder the code is structured as follows:
 build/     -- client-side build
 lib/       -- REST API handlers, static file support, and socket support are in here.
 test/      -- tests
 server.js  -- reads command-line args, sets up the server with the REST APIs and other middleware we need, then runs it.


b) Keep in mind that the Node server currently only supports a subset of the full REST API that John linked. Look at the REST tests to get an idea of what the Node server supports. (see our doc page for how to run the tests.)

Aside from that, there is a small API related to node development that is quite early and currently undocumented.

c) Currently, you'll have to modify the server code to add additional REST APIs. But ease of consumption is something we want to support. I just opened a bug about refactoring the server so it can be .use()'d like normal middleware modules in Connect or Express.

[Updated on: Tue, 05 February 2013 22:13]

Report message to a moderator

Previous Topic:Why it show nothing on browser
Next Topic:Listener for file and Directory Events
Goto Forum:
  


Current Time: Thu Apr 18 07:01:39 GMT 2024

Powered by FUDForum. Page generated in 0.01873 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top