File handling, streaming and real-time
36 questions in 12 subtopics.
Multipart uploads
Write a Spring MVC endpoint that accepts a file upload plus a JSON metadata part, and explain the default size limits in Spring Boot.Users need to upload video files of up to 5 GB. Design the upload flow for a Spring Boot service running behind a load balancer with 30-second request timeouts.A security review found that several services accept uploads, store them on local disk and serve them back with the original content type. What risks do you see and what platform-wide approach would you set?Your company stores several petabytes of user files uploaded over 12 years in one cloud provider's object storage, with application code calling the provider SDK directly. How would you assess and reduce the long-term vendor and cost risk?Streaming responses
How do you stream a large CSV export from a Spring MVC endpoint without loading all rows into memory?AStreamingResponseBody export fails after 30 seconds with an AsyncRequestTimeoutException, even though the code is still writing. What is happening and how do you fix it?Several teams build large data exports (millions of rows) synchronously over HTTP and they keep timing out or overloading databases. Propose a standard approach.Server-sent events
Show how to push progress updates to a browser with server-sent events in Spring MVC and in WebFlux.You run 6 instances of a service that pushes notifications over SSE. An event produced on instance A must reach a user connected to instance D. How do you design this?Your product needs real-time updates to web and mobile clients. Compare SSE, WebSocket, long polling and push notifications as a platform standard.WebSocket and STOMP
What does@EnableWebSocketMessageBroker configure, and how do @MessageMapping and SimpMessagingTemplate work together?A STOMP chat works on one instance, but after scaling to three instances users only see messages from people on the same instance. Explain and fix.Design the architecture for 500,000 concurrent WebSocket connections for live sports scores. What limits do you plan for in Spring and the infrastructure?Your product's real-time features were built over the years on three different technologies (STOMP over WebSocket, SSE and a third-party push service). How would you decide whether to consolidate, and what are the long-term risks of each option?Spring for GraphQL
In Spring for GraphQL, how do you implement a query books and a field author on Book, and how do you avoid an N+1 problem for author?A public GraphQL endpoint built with Spring for GraphQL is being hit with deeply nested queries that take down the database. What protections do you add?Product teams want a GraphQL layer over 30 REST services. What do you consider before approving it as a company direction?Five years after adopting GraphQL as the API layer for all clients, your schema has 3,000 fields, many unused, and changes are slow. What does this teach about long-lived API technology choices, and what would you do now?GRPC with Spring
What are the main differences between gRPC and REST over JSON, and what are the four gRPC call types?You are adding gRPC to a Spring Boot service. What options exist for integration, and what operational issues do you plan for?Should a large organisation standardise on gRPC for internal service-to-service calls instead of REST? Discuss the long-term implications.File, Excel and PDF downloads
Write a Spring MVC endpoint that returns a generated PDF report as a download namedreport-2026-11.pdf. Which headers matter, and how do you avoid holding a large file fully in memory?An Excel export built with Apache POI's XSSFWorkbook for 500,000 rows makes the service hit OutOfMemoryError. How do you fix it, and what other options exist?Every product team builds its own report exports (PDF, Excel, CSV) with different libraries, and some libraries have had licensing changes and security fixes. Would you build a shared document generation service, and how would you govern it?RSocket
What is RSocket, what are its four interaction models, and how does Spring support it?A team proposes RSocket for all streaming between 20 internal services, replacing Kafka topics and REST polling. How do you evaluate this?RSS and Atom feeds
Expose an Atom feed of the 20 latest blog posts from a Spring Boot application. Which libraries or approaches would you use, and which HTTP features make feeds cheap for clients that poll?Your public feed endpoint receives 3,000 requests per second from feed readers polling every minute, and each request queries the database. How do you reduce the load?SOAP web services
How do you build a contract-first SOAP endpoint in Spring Boot with Spring Web Services? Mention the XSD, generated classes and the key annotations.After upgrading to Spring Boot 3, a SOAP client generated years ago fails to compile with 'packagejavax.xml.bind does not exist' and at runtime with ClassNotFoundException for com.sun.xml.ws. What changed and how do you migrate?Your company still exposes 60 SOAP services to banks and government partners, and new teams no longer know the stack. Should you modernise them, and how?Legacy remoting: RMI and Hessian
What were Java RMI and Hessian used for, why are they considered legacy, and what has Spring done with its remoting support?A Java 8 desktop client talks to a server through SpringHttpInvoker. The server must move to Spring Boot 3 on Java 21, where HttpInvoker no longer exists. Plan the migration.Java serialization based remoting (RMI, HttpInvoker, Hessian) caused several of the industry's worst Java vulnerabilities. What lessons does this give for choosing integration technologies, and how would you find and retire such endpoints across a large company?Serving a frontend single-page app
A React app built into static files is served from a Spring Boot jar under src/main/resources/static. Deep links like /orders/42 return 404 when refreshed. Fix it without breaking /api routes.Should a single-page app be served from the Spring Boot backend jar or from a CDN with object storage? Discuss deployment, caching, security headers and CORS.No question matches these choices.