Vercel: Task timed out after 10.01 seconds - mongodb

I recently deployed a Next.js application for a software engineering boot camp. I am using Vercel for hosting the web app. The problem I am having has been spoken about on the internet before. However, I couldn't find much helpful information.
When I look at the real-time logs for my application from my Vercel dashboard, a 504 error gets thrown for multiple API routes I have created. I am aware that Vercel places restrictions on requests depending on the hosting plan someone subscribes to. However, I can't help but wonder if I have overlooked an important step when deploying my application.
When deploying my application, I did the following things:
Connected a session store to my MongoDB database.
Created a password-protected MongoDB Atlas account (credentials are environment variables).
White-listed all IP addresses so that any user can interact with their portion of the database.
I would appreciate help finding out if these errors are my fault and if there is anything I can do about them or if they are solely caused by the restrictions of the "Hobby" plan.
Thank you very much in advance,
-Sam
Screen Shot:

I had a similar issue, turned out, it was just the fact that I did not add the vercel ip addr to the network access page on mongodb so momgodb was blocking vercel from accessing data.

You need to integrate MongoDB in your project on Vercel.
Go to your project settings in Vercel and go to the Integrations tab. Click the Browse Marketplace button and find MongoDb. Click Add Integration button and follow the instructions.
Hope this helps... I know this was asked quite a while ago.

You have to troubleshoot the issue by doing the following
Eliminate the NextJS app out of the equation - Using postman https://www.postman.com/downloads/ - Confirm the output of your API, what is the time the API takes? Given function invocation has a limit, you need to optimize the API to meet the threshold.
If the API times are fine and resolution occurs outside of your app, the next step is to troubleshoot the API route, remove the DB parts and just echo back a success message and check the function invocation time.
If #2 turns out to be the issue, reach out to vercel support - Another option could be hosting it outside and whitelisting the cross domain API ask from your application.

Related

Deploy Sveltekit on own Windows/Linux Server?

I am almost done with my first Test Sveltekit Application and want deploy the App in the next Days in my private Network. When I google for this I get flooded with "Deploy to Vercel, Netlify.... and so on" but I dont see much for deploying it the Application to an Server.
Can somebody explain what to do? The Application uses Endpoints.
You would likely want to run it through a Node server, for this you can use the adapter-node package, see the documentation for it for more information.
https://github.com/sveltejs/kit/tree/master/packages/adapter-node

ArcGIS Portal inaccessible externally on AWS esri instance

I've been installing our very own ArcGIS Enterprise instance on AWS.
The instance I chose is ArcGIS Enterprise on Ubuntu.
It is important to mention that this installation was conducted without using Cloudbuilder. I know it is a tool that automates the process but I was introduced to it only after I have already started to attack my current instance problems head-on. So, please don't advise me to restart the whole process from scratch using it.
The current status of my instance is that my ArcGIS Server is working. I can access it, upload services and we have already started using it in out Staging environment.
I have authorized all of the software on the server and verified it is licensed. The Portal for ArcGIS is my main problem.
Whenever I try to access it externally(from my office computer) it seems to redirect to the internal IP for some reason, and then times out on that request.
for example typing(from my browser):
https://[dns address]:7443/arcgis/home
redirects to:
https://[internal IP]:7443/arcgis/home
and this times out. (...took too long to respond error)
The funny thing is I can access the portaladmin area.
it's only the portal itself which doesn't work.
Also, another curious thing is that if I type without using the ports, I can access a window but exceptions are thrown in the browser.
For example:
https://[dns address]/arcgis
This will lead to a window where the ArcGIS world icon can be seen but nothing else loads and there are exceptions for "resource not found" 404 on some of the components of this page.
Any ideas? What further information should I include to answer this question?
I've looked everywhere but Esri's documentation is not very forthcoming with examples and information to understand what it is I did wrong.
Also, I don't think this is a ArcGIS software issue. It looks like this might be a proxy issue. Anyone else experienced something like this?
Thanks!
I found the solution.
It was a combination of two problems:
Tomcat that was running the web adaptor service was crashing because of an entirely different and unrelated issue.
The Portal was missing a web adaptor configuration and therefore did not have the WebContext property set with the web adaptor URL.
After fixing both of these problems, I was able to access the portal correctly.

Error Accessing Bluemix Node-RED Editor

I'm using Node-RED Starter to build my app. My app URL can be accessed here.
should appear on my browser, but I got an
instead.
The app however seems to be working fine on my dashboard. Can anyone point me in the right direction? Thank you.
Your app is throwing a 500 error which basically means that your app is very much broken. How did you build it? Which starter did you use?
As you are running in the IBM Cloud, I would drop what you already have, and recreate using the starter from the IBM Cloud catalog. Unless of course if that is what you used to create it in the first place. In which case as per the other suggestions look at the server side logs, from the options on IBM Cloud for your application.

Refreshing Cloud Foundry app page on Bluemix "Stopped" the app

#ibm,
I observed the slowness while running the Cloud Foundry app on Bluemix. Sometimes, it gets really irritated so when I tried to refresh the app, it even stopped the app which was very frustrating. Could you please let us know the root cause of this and is there any way to avoid this in future ?
Refreshing the cloud Foundry page has nothing to do with crashing of your app. Could you please provide some more details like:
Functionality you are trying.
Deployment Approach.
Whether the application is Liberty Java, NodeJS or something else.
And lastly your application logs. If you cannot copy directly from the logs, you can use the Log Analysis Service to copy the logs.
NOTE: I should have added this as a comment but I am still 35 reputation short.

Bluemix Create App Error

Getting the below error while creating app on Bluemix dashboard, irrespective of using unique App names
BXNUI0005E: The 'MyFirstMobileAppTest' application could not be added.
See the Troubleshooting topics in the IBM Bluemix Documentation to
check service status, review troubleshooting information, or for
information about getting help.
I have been able to create a mobile application without any problems. This issue was most likely due a temporary outage.
If you experience this again, be sure check the Bluemix status page for any known issues and/or try again in a few minutes.