Updating README to include information about adding custom operations

This commit is contained in:
Sean McIlvenna
2021-06-04 15:13:09 -07:00
parent 2467c902bd
commit 0cc6d447fe

View File

@@ -362,3 +362,9 @@ docker build --target=release-distroless -t hapi-fhir:distroless .
Note that distroless images are also automatically build and pushed to the container registry, Note that distroless images are also automatically build and pushed to the container registry,
see the `-distroless` suffix in the image tags. see the `-distroless` suffix in the image tags.
## Adding custom operations
To add a custom operation, refer to the documentation in the core hapi-fhir libraries [here](https://hapifhir.io/hapi-fhir/docs/server_plain/rest_operations_operations.html).
Within `hapi-fhir-jpaserver-starter`, create a generic class (that does not extend or implement any classes or interfaces), add the `@Operation` as a method within the generic class, and then register the class as a provider using `RestfulServer.registerProvider()`.