Skip to main content

All Questions

Tagged with
3 votes
1 answer
117 views

Consuming sharded database using node.js

I think the only big improvement that can be made is to check which shard to query based on the userIds of the followed users. One easy way is to check the last ...
user avatar
2 votes
1 answer
182 views

NODE JS Unlink and delete MySQL data

Here is my revised code from my other review question Node JS delete multiple MySQL linked records and delete physical file Just would like to hear some reviews if I have the right logic. ...
DeveloperLV's user avatar
4 votes
1 answer
275 views

Correctly using promises with node-mysql

I have been trying to do a simple query and return the results with node-mysql however I had several problems. Originally I wrote it where there was no promise, but ...
Ian's user avatar
  • 141
0 votes
1 answer
61 views

Scrape page and send user only new results

Review Wanted Application Summary The application is a simple screen scraper which is to notify the user when new items are posted. The code is run as a CRON job every ten minutes. It will scrape the ...
John S.'s user avatar
  • 171
2 votes
0 answers
154 views

Querying Aurora via Node.js

Function queries data from an Aurora database. Aurora database is the MySQL engine therefore, I'm querying it with a MySQL NPM module. If there is something better, I'm all ears. The calling function ...
Adam's user avatar
  • 153
1 vote
1 answer
138 views

Authentication using express-session

I'm making an online shopping store or e-commerce and I use an express session for many things. Example: Shopping Cart, Authentication user* I store the data chart list in the database based on the ...
Faris Dewantoro's user avatar
2 votes
0 answers
876 views

Async/await Mysql wrapper

I used MySQL, but it was inconvenient so I made a wrapper. It works, but I'm unsure if there are any issues. Used node module - mysql2, bluebird sqlWarpper.js ...
AKIMOTO TAKUMI's user avatar
3 votes
1 answer
63 views

Handling download requests using PM2

I Using Nodejs v9.10.1 for handle download operation from another application. When using PM2 in fork mode to make alive my code. After 50 minutes, this will show high memory usage. Server Config is ...
Pasha Aleayoob's user avatar
1 vote
2 answers
1k views

Router for quering MySQL results in NodeJS

What should I consider in order to refactor the following code ? It seems very close to proudly become a Pyramid of Doom: ...
Cadmos's user avatar
  • 111
1 vote
2 answers
17k views

Displaying MySQL table data using Node.js

I'm trying Node.js for the first time, everything works, but i'm not sure that my approach is right, can you tell me if it's ok? In this test, i've tried to get ...
Marco Salerno's user avatar
5 votes
1 answer
624 views

NodeJS/Express/socket.io backend

I have the backend of a socket.io script running in NodeJS for a web application. A user can login to the site and join a project collaboration (group of users linked to a project). Each project has a ...
LeDoc's user avatar
  • 151
3 votes
0 answers
71 views

A function that debits a virtual wallet and calls an API to disburse to a real account

I am trying to determine if there is a better way to handle reversals for this function. This is how it works: A user inputs in amount, bank, and account number this would be used to debit his ...
temiloluwa adesina's user avatar
3 votes
1 answer
12k views

Convert all dates in an array to date format

I'm returning an array containing dates (and other things) from an API, then looping through the array on the front end to convert them into dates The backend uses Node.Js and queries a mySql ...
Geraint's user avatar
  • 273
2 votes
0 answers
466 views

Chat application built with Node

In an effort to teach myself Node.JS and truly delve into its communication capabilities, I elected to recreate a previous chatting project. It took a bit of forethought to acclimate code to the ...
Legato's user avatar
  • 9,839
7 votes
1 answer
24k views

Passing Node.js SQL connection to multiple routes

Here are the app.js, users.js and user.js routes of a node application I am building. As you can see I am connecting to the SQL DB in each route, and this is not ideal. I have tried passing the ...
SeanQuinn781's user avatar

15 30 50 per page