Ok, if we don't want to change API, I'm fine with keeping it called
nextTick. In a way it is the next tick before any scheduled real events,
but after any already schedules nextTicks. Technically all ticks are all
part of the same root stack, there is a blocking uv.run() call they all
originate
What is lost here is that you're doing something you shouldn't if you starve IO
this way.
We need a guard, no doubt, but I think it should throw so people can fix this,
not try to let some IO in with 1 second of bad processing in between each.
-Mikeal
On May 27, 2012, at May 27, 201211:38 AM,
Jorge,
They're not rare cases. Virtually every use of nextTick is
specifically designed to allow the attachment of event handlers before
IO occurs, and every time we use it that way, it leads to sporadic
failures under load.
We're not going to change the name of the method. We're just going to
On May 27, 2012, at May 27, 20121:41 PM, Isaac Schlueter wrote:
Jorge,
They're not rare cases. Virtually every use of nextTick is
specifically designed to allow the attachment of event handlers before
IO occurs, and every time we use it that way, it leads to sporadic
failures under load.
I don't think it's fair to say that a recursive nextTick is a bug, any
more than it is to say a recursive function is a bug.
We can add some kind of guard on it so that it'll throw a RangeError
if you recurse 10,000 times or something.
On Sun, May 27, 2012 at 1:49 PM, Mikeal Rogers
+1 async
On Saturday, May 26, 2012 11:54:13 AM UTC-7, Davis Ford wrote:
There does not appear to be a shortage of libraries out there that help
with flow control. I'm looking for something that is well tested,
maintained, and has the capability to deal with parallel and sequential
Like what?
On 27.05.2012, at 1:55, Jarka est.ri...@gmail.com wrote:
Well there are programming cases where you can not use async way.
On Saturday, 26 May 2012 22:59:17 UTC+3, Tim Caswell wrote:
I recommend not using one, but if you prefer to have a library for this,
async is the most
I thought this page would be of interest. It introduces ss.load.code()
that allows you to require modules in the browser in an asynchronous
manner. (Of course that is different from an asynchronous require on the
server)
Loading Assets On Demand (in socketstream)
@mscdex that's it.
I need this to parse config files, and now I can require() my parser from
everywhere without the need to send the app path :)
--
Att,
Alan Hoffmeister
2012/5/27 Anand George mranandgeo...@gmail.com
Ok. I get it now. And thanks for both solutions offered. Guess it's useful
Be sure to check also: https://github.com/medikoo/deferred a very
*functional* promise/deferred concept implementation.
On Saturday, May 26, 2012 8:54:13 PM UTC+2, Davis Ford wrote:
There does not appear to be a shortage of libraries out there that help
with flow control. I'm looking for
Coming back to your question
npm install -g mymodule will not be available when you require it using
mymodule = require('mymodule')
See http://blog.nodejs.org/2011/03/23/npm-1-0-global-vs-local-installation/
On Sun, May 27, 2012 at 5:14 PM, Alan Hoffmeister alanhoffmeis...@gmail.com
wrote:
I recommend using no flow control library, but I recommend to learn
how the async library does what it does.
If things are going to become a real mess, I recommend the
reorganization of the code.
If things are still a mess, well, start again from scratch :-)
The async library: npm install async
@Anand, yep, but you can use `npm link mymodule`
--
Att,
Alan Hoffmeister
2012/5/27 Anand George mranandgeo...@gmail.com
Coming back to your question
npm install -g mymodule will not be available when you require it using
mymodule = require('mymodule')
See
Yes Micheil !
I want to build a proxy server in Node.js that will be stored in my
local server and cache all website visited
so , how can i do ?
can you so me any guides, please ?
thank for help !
nice a weekend .
On 25 Tháng Năm, 21:01, Garcia Souza garcia.rso...@gmail.com wrote:
I think you
Hello,
it's my first post in this group, i'm new on nodejs field.
I have done an ssjs code with wakanda server , the code use a
synchronous socket. i want to use it in nodeJS but i dont find
synchronous Socket.
there is a native Socket sync that i can use for nodejs. i wont reDo
my code with a
Hope you don't mind my asking... but do you really need a parser for a
config file. Couldn't it just be required as below:
config.js
module.exports = {
host: localhost,
port: 8000
}
app.js
var c = require('./config')
console.log(c.host + c.port);
On Sun, May 27, 2012 at 7:18 PM, Alan
Yup, I could do this, but I'm writting a MVC framework and splitting
routes, views, rpc, models, configs, validations, translations an other
things between multiple folders, that's because I really don't like to have
my huge app inside one big js.
My main idea is to maintain a simple module that
Why don't you take a look at socket.io? It isn't sync but it's event driven
and easy like a pie to understand :)
Em domingo, 27 de maio de 2012, Serti Ayoub escreveu:
Hello,
it's my first post in this group, i'm new on nodejs field.
I have done an ssjs code with wakanda server , the code use
Hey guyz!
I think that I found my answer!
1) Register an dinamic helper:
md5 = require('crypto').createHash 'md5'
app.locals.use (req, res) -
app.locals.crop = (image, width, height) -
res.crops = new Object if !res.crops
key = md5.update(image + width + height).digest
On May 27, 7:35 am, Serti Ayoub ayb.se...@gmail.com wrote:
it's my first post in this group, i'm new on nodejs field.
I have done an ssjs code with wakanda server , the code use a
synchronous socket. i want to use it in nodeJS but i dont find
synchronous Socket.
You won't find synchronous
var root = process.cwd() + '/';
if you run the /home/myuser/app.js then the root will be /home/myuser/
you may also share this as global
var root = global.root = process.cwd() + '/';
and then get it from any required file as global.root, this is what i'm
doing in my framework
Thank's
What i need a library for using synchronous socket, so i wont to use event
such as (on 'data' ).
as an example of what i have:
var socket = new SocketSync();
socket.open('localhost', 8856);
socket.write('my request');
var mydata= socket.read();
socket.end();
instead of
var
On Sunday, May 27, 2012 10:26:30 AM UTC-7, Serti Ayoub wrote:
What i need a library for using synchronous socket, so i wont to use event
such as (on 'data' ).
We understand that. The answer is that it can't be done without making
changes to node itself. What few synchronous functions
Amen. I went through the same thing. I wish this had been a higher design
priority for node, but I think I see why it wasn't. Moving JavaScript out
of the browser and onto the server comes with some challenges.
On May 27, 2012 9:00 AM, Alan Hoffmeister alanhoffmeis...@gmail.com
wrote:
Yup, I
+1 for async. Only thing it is missing is a simple promise creation
functionality, but you have others for that.
On May 27, 9:40 am, Oliver Leics oliver.le...@gmail.com wrote:
I recommend using no flow control library, but I recommend to learn
how the async library does what it does.
If
@Shogun very nice! I thought global was some evil thing..
@Mundi, yes, I came from PHP and I really miss this folder pattern...
Em domingo, 27 de maio de 2012, C. Mundi escreveu:
Amen. I went through the same thing. I wish this had been a higher
design priority for node, but I think I see
so, what can be the solution?
2012/5/27 Eric S e...@geekzilla.org
On Sunday, May 27, 2012 10:26:30 AM UTC-7, Serti Ayoub wrote:
What i need a library for using synchronous socket, so i wont to use
event such as (on 'data' ).
We understand that. The answer is that it can't be done
Starting a new blocking child process that does the async socket operation.
Shelljs has a method for blocking child process:
https://github.com/arturadib/shelljs
On Sunday, May 27, 2012 at 9:51 PM, Serti Ayoub wrote:
so, what can be the solution?
2012/5/27 Eric S e...@geekzilla.org
the project have already be done with wakanda ssjs and it's was done with
synchronous socket, and i you know asynchronous socket it's an other logic,
so that will require major change in my project if i use asynchronous
socket.
2012/5/27 Alan Hoffmeister alanhoffmeis...@gmail.com
@Serti, if you
Hi,
I'm currently working on a node.js project in Madrid and want to find other
people to share node.js experience and knowledge.
Anyone interested?
--
Job Board: http://jobs.nodejs.org/
Posting guidelines:
https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
You received this
I'm organizing LXJS (lxjs.org) where you will be able to find lots of
Iberian node.js devs :)
Nuno
On Sun, May 27, 2012 at 7:57 PM, Elio Capella eliocape...@gmail.com wrote:
nterested?
--
Job Board: http://jobs.nodejs.org/
Posting guidelines:
On May 27, 2012, at 8:57 PM, Elio Capella wrote:
Hi,
I'm currently working on a node.js project in Madrid and want to find other
people to share node.js experience and knowledge.
Anyone interested?
Yo voy a Madrid al menos una vez al mes. Nos vemos cuando quieras!
--
Jorge.
--
Job
So I thought about what you had said and I came up with this
https://gist.github.com/2816361. What tips can you give me if any on making
the Stream's?
On Monday, April 30, 2012 6:36:22 PM UTC-4, Marco Rogers wrote:
There are several potential issues I'm seeing here. But it looks like you
these are both read/write streams but you don't appear to be emitting end
after end() is called. that's an issue.
On May 27, 2012, at May 27, 20124:19 PM, Tim Dickinson wrote:
So I thought about what you had said and I came up with this
https://gist.github.com/2816361. What tips can you
Anything else you can think of? I don't really understand now the streams
should end.
On Sunday, May 27, 2012 7:23:10 PM UTC-4, Mikeal Rogers wrote:
these are both read/write streams but you don't appear to be emitting
end after end() is called. that's an issue.
On May 27, 2012, at May 27,
I think the Spain.JS conferences are taking place in Madrid this July.
Should be a place to be for local nodejs developers.
On Sunday, May 27, 2012 8:57:51 PM UTC+2, Elio Capella wrote:
Hi,
I'm currently working on a node.js project in Madrid and want to find
other people to share node.js
Max did a pretty good writeup.
http://maxogden.com/node-streams
On May 27, 2012, at May 27, 20124:31 PM, Tim Dickinson wrote:
Anything else you can think of? I don't really understand now the streams
should end.
On Sunday, May 27, 2012 7:23:10 PM UTC-4, Mikeal Rogers wrote:
these are
On Sunday, May 27, 2012 12:51:54 PM UTC-7, Serti Ayoub wrote:
so, what can be the solution?
Well, I can see two solutions, the first of which you've already dismissed
(switching to async IO), and the second, I couldn't even begin to estimate
the amount of work needed. That would be to
I love JSON, but writing it by hand has always been a pain.
Needing to (double-)quote keys, not being able to document the data with
comments, and not having support for trailing commas or multi-line strings
-- all of which are available and work perfectly well on modern ES5
engines, including
Hi Rohit,
Thanks for your reply. I guess what you mean is to avoid this by sharig the
load. If so can you tell me how we can do this load sharing.
Regards
Kapil
On Thu, May 24, 2012 at 5:39 PM, Rohit Singh rohitishe...@gmail.com wrote:
This happens when the object you are using/manipulating
Hi,
just share the code with me.
Regards,
Rohit
On Mon, May 28, 2012 at 9:54 AM, kapil gopinath kapilgopin...@gmail.comwrote:
Hi Rohit,
Thanks for your reply. I guess what you mean is to avoid this by sharig
the load. If so can you tell me how we can do this load sharing.
Regards
Kapil
On May 24, 1:30 am, kapil gopinath kapilgopin...@gmail.com wrote:
Please help me in solving this issue which is causing the node file to
hang.
FATAL ERROR: CALL_AND_RETRY_2 Allocation failed - process out of memory.
What node version and OS are you using? Can you also provide a
simplified
42 matches
Mail list logo