Page 1 of 1

Can we use Node.js (asynchronous) code for the appery server?

Posted: Thu Jan 02, 2014 3:45 am
by Arbab Khan

Can we add node.js javascript for the server code on appery somehow? Since node.js is async, it would be useful in a chat application or something where page loading won't have to be as burdensome. I know about caching pages, it is useful but I don't know how to rely on that for a large project. Please help.


Can we use Node.js (asynchronous) code for the appery server?

Posted: Thu Jan 02, 2014 5:06 am
by maxkatz

Appery.io Server Code is based on Google's V8 JavaScript engine: https://code.google.com/p/v8/. Right now you can send synchronous requests. We are working on allowing asynchronous requests as well.


Can we use Node.js (asynchronous) code for the appery server?

Posted: Thu Jan 02, 2014 5:42 am
by Arbab Khan

Thank you for your prompt reply. Is there a way to have page caching done globally thru one js function or script? Other than adding to each page individually...


Can we use Node.js (asynchronous) code for the appery server?

Posted: Thu Jan 02, 2014 5:59 am
by maxkatz

Page caching or JavaScript data caching?


Can we use Node.js (asynchronous) code for the appery server?

Posted: Thu Jan 02, 2014 6:03 am
by Arbab Khan

Page caching. Like how pages in a paginated list are cached so going prev or next will load faster. But doing that to all the elements of all pages.


Can we use Node.js (asynchronous) code for the appery server?

Posted: Thu Jan 02, 2014 6:10 am
by maxkatz

You could render all pages into one file: http://docs.appery.io/documentation/a...


Can we use Node.js (asynchronous) code for the appery server?

Posted: Thu Jan 02, 2014 6:15 am
by Arbab Khan

Oh ok through jquery. Thank you!


Can we use Node.js (asynchronous) code for the appery server?

Posted: Sun Mar 02, 2014 10:12 pm
by Jamie5245261

Max writes:

[quote:]We are working on allowing asynchronous requests as well. [/quote]

This is great news. I'm trying to build an app that requires similar functionality to what Arbab mentions, above. It seems that the setTimeout function is not available in server code and that's a shame. I've had to (hopefully temporarily) work around this by sending pings often to the server to see if there's been any updates to pass along to my users.

This is a "must have" feature for developers that have any sort of "live" activity going on between two or more app users.

So, in short, I just wanted to give a "thumbs up" or a "bump" or whatever you'd like to call it to this post.