Backend & API's 3rd Project URL-shortener

Url Shortener Microservice does it need a database?
I made an array of pages for returning the values, which does the job. For me and for the LINK of HEROKU app so you can try.
(By the way 2nd 3rd test are not passing so mongoDB needed right?)

But I am unsure, some people have done it with MongoDB.

edit: the link corrected

It may work this way and I’ve seen some projects pass the tests like this but the array you create is specific to that one instance of your server and would be reset every time the server starts. Databases are used to persist the data over different instances of the server, whether that is multiple copies of the server running or the server shutting down and restarting.

Failing the tests doesn’t necessarily mean that the array is the problem and you have to use a database. You’ll need to post a link to the code for further assistance.

1 Like

Here is the repo. Thanks

Thank you jeremy I found the solution on FCC. Later I will be looking first on internet after on FCC for solutions.

Hello @fygen ! Please close this so that people know you have solved the problem.