Class RootResources
- All Implemented Interfaces:
jakarta.servlet.Servlet,jakarta.servlet.ServletConfig,Serializable,BasicUniversalConfig,DefaultConfig,DefaultHtmlConfig
Extends BasicSpringRestServletGroup (i.e. SpringRestServlet) so child resources can be resolved
as Spring beans — required for HelloResource to receive its @Autowired HelloMessageProvider.
Mounts the deployment-agnostic PetStoreResource from juneau-petstore-core alongside the local
HelloResource injection demo.
Note: this Spring Boot deployment intentionally does NOT mount the Jetty/Microservice admin trio
(ConfigResource/LogsResource/ShutdownResource, now in the
juneau-microservice-examples module) — those are Jetty-only and have no meaningful analogue here
(Spring Boot has its own actuator surface). This is the documented non-parity deployment-specific
difference between the two petstore deployments.
See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.juneau.rest.server.servlet.RestServlet
RestServlet.Builder<R extends RestServlet,SELF extends RestServlet.Builder<R, SELF>>, RestServlet.DefaultBuilder<R extends RestServlet> -
Field Summary
Fields inherited from class jakarta.servlet.http.HttpServlet
LEGACY_DO_HEAD -
Constructor Summary
Constructors -
Method Summary
Methods inherited from class org.apache.juneau.rest.server.springboot.SpringRestServlet
createBeanStoreMethods inherited from class org.apache.juneau.rest.server.servlet.RestServlet
builder, createAuthenticator, destroy, doLog, getContext, getPath, getPaths, getRequest, getResponse, getRestBuilder, init, log, log, service, setContextMethods inherited from class jakarta.servlet.http.HttpServlet
doDelete, doGet, doHead, doOptions, doPatch, doPost, doPut, doTrace, getLastModified, isSensitiveHeader, serviceMethods inherited from class jakarta.servlet.GenericServlet
getInitParameter, getInitParameterNames, getServletConfig, getServletContext, getServletInfo, getServletName, init, log, log
-
Constructor Details
-
RootResources
public RootResources()
-
-
Method Details
-
petStore
Registers the onePetStoreshared by the/petstoreAPI and the console tree, seeded with the deterministic demo data set.Child resources inherit the group's beans, so a plain
@Beanmethod is all that is needed.- Returns:
- The seeded
PetStore.
-
index
GET /goes to the console store page.- Parameters:
req- The request.- Returns:
- A 303 to
/console/store.
-