Interface ManifestProducer
- Since:
- v3.0
-
Method Summary
Modifier and TypeMethodDescriptiongetManifest(URI url) DuringApplicationLinkregistration via the administrative UI, the user is prompted to choose what type of remote application they are linking to.Returns the current state of the application located at the specified Url.
-
Method Details
-
getManifest
During
ApplicationLinkregistration via the administrative UI, the user is prompted to choose what type of remote application they are linking to. If selected, thisNonAppLinksApplicationTypewill be asked to provide a manifest for theURIprovided by the user.The
Considerations:Manifestcan either be created completely locally with pre-determined values, or with some interaction with the remote application. A local implementation is far simpler to implement, but has the drawback of allowing users to configure spurious, non-functionalApplicationLinks.Manifest.getId()should return a consistent, unique value for a particular application instance.ApplicationIdUtilhas been provided to assist in generating a consistent id for a given base url. Implementations that do not retrieve a unique ID from the remote application should always delegate toApplicationIdUtil.- The
ManifestNotFoundExceptionmay be thrown to indicate that communication with the remote application failed, causing the implementation to be unable to create aManifestobject. Implementations that synthesise theManifestlocally should have no need of this exception.
- Parameters:
url- the base url of the remote application to create or retrieve aManifestfrom.- Returns:
- the created or retrieved
Manifest. Never returns null. - Throws:
ManifestNotFoundException- if no manifest could be obtained.
-
getStatus
Returns the current state of the application located at the specified Url. Since each
ManifestProduceris bound to a specificApplicationType, this method must implement the characteristics of that application type to determine whether it is online or not.Implementations could check for the presence of a known rest endpoint, or anything else that would confirm the application at the specified Url is of the correct type.
For applications that have no feasible way of detecting their state, this method should return
ApplicationStatus.AVAILABLE.- Parameters:
url- baseUrl of the peer.- Returns:
- current state of the application located at the specified Url
-