Spectivis Cloud
Next.js
Getting started with the Next.js sample
Deploy a small Next.js 16 app that shows streaming, a server action, after() and a route handler.
The Next.js sample is a small Next.js 16 app with the current App Router patterns: server components, a server action, a section that streams in with Suspense, an after() callback and a route handler.
Deploy it
Section titled “Deploy it”- Choose a plan if your organization does not have one yet.
- Choose New app, then “Deploy a sample”, then Next.js.
- Name the app. The name becomes its address and cannot be changed later.
- Leave the Next.js preset on and choose an instance size. 512 MB is enough for the sample.
- Choose Deploy.
Cloud builds the app, starts it, and switches traffic when / answers. There is no release command and no database for this sample.
Check that it works
Section titled “Check that it works”Open the app’s address.
- Streaming. The heading appears at once. The server details appear about a second and a half later. Cloud does not buffer responses, so the parts reach you as they are ready.
- Server action. Write a note and choose Save. The page shows it. Notes live in memory, so they reset on each deploy.
after(). Open the Logs tab after you save a note. You will see a line from theafter()callback. Cloud gives a stopping app 30 seconds, so these callbacks can finish.- Route handler.
/api/healthreturns{"status":"ok"}.
Next: Next.js on Spectivis Cloud.