Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

629
Views
Express.js doesn't allow more than 6 requests. How do I fix this?

I am working on a website where the person has to login first. On login, I make a fetch POST request to an endpoint defined in the server. When I login, and logout 6 consecutive times, i.e. login - logout - login - logout .. at the 6th time, I logout, and can't login again. The server doesn't accept anymore requests from the client until I refresh the browser, and then it works for 6 more times.

I've read that there is a 5 requests limit imposed on HTTP requests that are not consumed, even though many people said this limit has been removed. I am not using the HTTP module. I am creating my endpoints on the express instance.

Here's a snippet of two of my endpoints:

const app = express();

app.get('/', (req, res) => {
    res.json(getPost('all'))
})

app.post('/register/:user', async (req, res)=>{
   addUser(req.params.user)

})

Can anybody tell me how do I fix this issue? Do I try to increase the number of allowed requests ..? Do I "consume" the requests? How do I do that?

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

Add a response to your post request.

app.post('/register/:user', async (req, res)=>{
   addUser(req.params.user); // this function doesn't respond to the request
   res.sendStatus(200); // something like this does!
})
about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!