Questions tagged as 'nodejs'

1
answer

Query generate multiple threads that simulate clients in nodejs

I have n names that simulate clients what I want to do is iterate over each of them and send me requests to an endpoint in nodejs Here I have the part of the code corresponding to what I say to them sensors=["Rimac","Cercado"]; for (se...
asked by 06.07.2016 / 15:02
1
answer

Wait for the result of a function to save

How to execute a function and wait for a result to save the data: I have if (!_.isUndefined(image)){ upload(image).then(function(response) { if (!response.success) return res.status(202).send(upload); image = respon...
asked by 12.09.2016 / 15:41
1
answer

Unable to find module xmlbuilder when I'm installing ionic '

I can not correct this error. Can someone tell me why? Thanks. Error: Cannot find module 'xmlbuilder' at Function.Module._resolveFilename (module.js:338:15) at Function.Module._load (module.js:280:25) at Module.require (module.js:3...
asked by 15.02.2016 / 21:30
2
answers

Local dependencies using the tools for NodeJS in VS2015

I'm trying to compile a project from nodejs, with VS2015. The main project has sub projects in sub folders, that is to say that in each sub-folder there is a package.json with its own code and each one declares the dependencies to th...
asked by 20.01.2016 / 15:47
1
answer

Unix TimeStamp Convert to +02: 00

I have the following date 1535440000 I am converting it in such a way to Timestamp: recvTime: new Date(params.contextResponses[i].contextElement.attributes[j].metadatas[k].value * 1000).toISOString() The problem is that I have to con...
asked by 24.09.2018 / 15:50
1
answer

How to wait for the answer of a query in MongoDB with NodeJS?

I have a MySQL database in which I keep address information that a device goes through. In this table I have the fields "latitude", "longitude" and "direction". And the main idea is to pass those records from MySQL to Mongo, but I want to avoid...
asked by 24.08.2018 / 19:33
1
answer

Help with CORS API NODE JS

How could someone help me with the Cors in nodejs, I am already using the npm of cors but it does not work or I think I am not configuring them in an appropriate way, when consuming other apis that lend themselves to the testing of them it does...
asked by 30.09.2018 / 01:18
1
answer

How not to duplicate data in MongoDB (with NodeJS), migrating from MySQL

I am evaluating the possibility to start working with MongoDB using NodeJS, however, I am formatted to think in SQL and not in noSQL, I find myself with the following dilemma which takes a day chewing and all post / tutorials They seem to ignore...
asked by 30.09.2018 / 17:33
0
answers

RED Node send notification only once

I am learning to use this program and I am in a situation where I do not know how to move forward. I do this to learn. I have the following situation. An API that reads a balanace and passes it to a node which checks what the balance is and if i...
asked by 02.10.2018 / 02:42
0
answers

Error making an SQL query with JavaScript

I'm trying to do a SELECT from node.js to get an error from a table of "errors" but I get the following error and I do not know what else to do or what is due.    UnhandledPromiseRejectionWarning: RequestError: Could not find stored   procedu...
asked by 02.10.2018 / 00:43