Getting started tutorial??

8 views
Skip to first unread message

Iqbal Yusuf Dipu

unread,
Jun 4, 2010, 10:10:02 AM6/4/10
to nitro-devel
Is there any getting started tutorial ? I'm capable of developing and
deploying on GAEJ using Eclipse with Java. I also like Javascript a
lot.

Thanks.

Iqbal

George Moschovitis

unread,
Jun 4, 2010, 11:17:45 AM6/4/10
to nitro-devel
Sorry, no tutorial at the moment, but I hope to find the time to write
one in the near future.

However, you could have a look at this example:

http://www.nitrojs.org/appenginejs/appengine-blog-example.tar.gz

the basic idea is that nitro applications are just a collection of
plainm, simple JSGI [1] applications. We use a Dispatch middleware to
select which jsgi application will serve the current http request.
Each request url maps to a single application in the dispatch root.
These jsgi applications typically reside in:

root/WEB-INF/src/root

for example the request GET /articles/view maps to the jsgi app root/
WEB-INF/src/root/articles/view.js

if you include the Render middleware, the result of each jsgi
application will be interpolated in a template [2] that resides
typically in root/WEB-INF/src/templates, in our example,

GET /articles/view will use the template in root/WEB-INF/src/templates/
articles/view.html

You can put your static files in root/

You can add aditional commonjs packages in root/WEB-INF/packages.

I hope this will help you get started. If you need more help, do not
hesitate to ask ;-)

-g.


[1] http://www.nitrojs.org/appenginejs/appengine-blog-example.tar.gz
[2] http://www.github.com/gmosx/normal-template

Iqbal Yusuf Dipu

unread,
Jun 25, 2010, 5:24:05 PM6/25/10
to nitro-devel
Hi,

I installed blog-example and started up in my local box. But when I
click "Add Article" link the server throws an error "'/articles' does
not respond to HTTP method 'GET'"

What am I doing wrong?

Thanks



On Jun 4, 10:17 am, George Moschovitis <george.moschovi...@gmail.com>
wrote:

George Moschovitis

unread,
Jun 26, 2010, 2:13:16 AM6/26/10
to nitro...@googlegroups.com
Are you sure you are running the *latest* version?


I remember such an issue when running on Windows, but I have fixed this in the latest version, try to download again from the above link.

-g.


--
You received this message because you are subscribed to the Google Groups "nitro-devel" group.
To post to this group, send email to nitro...@googlegroups.com.
To unsubscribe from this group, send email to nitro-devel...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/nitro-devel?hl=en.




--
http://www.gmosx.com/blog

Iqbal Yusuf Dipu

unread,
Jun 26, 2010, 10:08:25 AM6/26/10
to nitro-devel
I've downloaded the project again from your link and its the same
error I'm getting. Yes I'm running Windows Vista.Do I need to download
the project from source and build it?



On Jun 26, 1:13 am, George Moschovitis <george-moschovi...@gmosx.com>
wrote:
> Are you sure you are running the *latest* version?
>
> http://www.nitrojs.org/appenginejs/appengine-blog-example.tar.gz
>
> I remember such an issue when running on Windows, but I have fixed this in
> the latest version, try to download again from the above link.
>
> -g.
>
> On Sat, Jun 26, 2010 at 12:24 AM, Iqbal Yusuf Dipu <iqbalyusufd...@gmail.com
> > nitro-devel...@googlegroups.com<nitro-devel%2Bunsubscribe@googlegr oups.com>
> > .

George Moschovitis

unread,
Jun 26, 2010, 11:54:43 AM6/26/10
to nitro...@googlegroups.com
I've downloaded the project again from your link and its the same
error I'm getting. Yes I'm running Windows Vista.Do I need to download
the project from source and build it?

very strange, I will try this again on windows and get back to you...

-g.

To unsubscribe from this group, send email to nitro-devel...@googlegroups.com.

For more options, visit this group at http://groups.google.com/group/nitro-devel?hl=en.




--
http://www.gmosx.com/blog

George Moschovitis

unread,
Jul 4, 2010, 3:24:34 AM7/4/10
to nitro...@googlegroups.com, iqbalyu...@gmail.com
Hello Iqbal,

Sorry for the late reply, the example code did not include a windows specific fix:

just edit 

root/WEB-INF/packages/nitro/lib/nitro/middleware/path.js 

and change line 13 to: 

return FS.join(child, p).replace(/\\/, "/"); // windows fix! 

this will fix the problem. 

Btw, I have updated the two examples, so you can just download the new versions instead.


Please let me know if this fixes your problem!

-g.



To unsubscribe from this group, send email to nitro-devel...@googlegroups.com.

For more options, visit this group at http://groups.google.com/group/nitro-devel?hl=en.

IQBAL YUSUF

unread,
Jul 4, 2010, 4:48:01 PM7/4/10
to George Moschovitis, nitro...@googlegroups.com
Yes that fixed the problem.

Thanks.

Reply all
Reply to author
Forward
0 new messages