Node Server Data Base Connection Lost

I’m developing a web app using express, and MySQL. I was able to publish the app on heroku for testing. The problem came after few minutes or seconds, the server throws the following error:

Error: Connection lost: The server closed the connection.
at Protocol.end (/app/node_modules/mysql/lib/protocol/Protocol.js:112:13)
at Socket.<anonymous> (/app/node_modules/mysql/lib/Connection.js:94:28)
at Socket.<anonymous> (/app/node_modules/mysql/lib/Connection.js:526:10)
at Socket.emit (events.js:327:22)

When I restart the server, I’m able to execute some successful calls to database, but after some minutes, the connection get lost.

This is the connection file I’m currently using, I will, change my credentials for placeholders, only for security purppose.

module.exports = {
HOST: 'mysql5044hostname',
USER: 'myUserName',//root
PASSWORD: 'thisIsMyPassword',
DB: 'default_schema'
};

Any help regarding this matter, will be appreciated.

91 thoughts on “Node Server Data Base Connection Lost”

  1. i need a loan have no credit, i need more loan money for college. i need consolidation loan need loan now i need a loan i need loan, cash payday loans bad credit, cash advances, cash advance loans, money 3 payday loans. Money management describes investment, accepts deposits.

    Reply
  2. pharmacie brest ouverte entre 12h et 14h therapies alternatives et complementaires pharmacie ico angers , therapie cognitivo comportementale caen pharmacie des ormeaux aix en provence , medicaments mal de ventre pharmacie de garde aujourd’hui valence pharmacie de garde issoudun Videx EC prix sans ordonnance, Videx EC Suisse sans ordonnance [url=https://www.bark.com/fr/fr/company/videx-ec-prix-sans-ordonnance-videx-ec-suisse-sans-ordonnance/6kDo0/#]Videx EC prix sans ordonnance, Videx EC Suisse sans ordonnance[/url] Videx EC prix Suisse Videx EC prix sans ordonnance. medicaments xarelto pharmacie de garde marseille 12e Irbesartan sans ordonnance prix, Irbesartan vente libre [url=https://publiclab.org/notes/print/31600#]Irbesartan sans ordonnance prix, Cherche Irbesartan moins cher[/url] Irbesartan sans ordonnance Belgique Equivalent Irbesartan sans ordonnance. pharmacie imbert beauvais sur matha pharmacie de garde dax , therapies des schemas pharmacie angers Vitomanhills livraison rapide, Vitomanhills sans ordonnance en ligne [url=https://www.bark.com/fr/fr/company/vitomanhills-france-sans-ordonnance-vitomanhills-livraison-rapide/GEYbZ/#]Vitomanhills France sans ordonnance, Vitomanhills livraison rapide[/url] Vitomanhills prix sans ordonnance Vitomanhills France sans ordonnance. pharmacie bailly chaussures therapies types .

    Reply

Leave a Comment