[jboss-jira] [JBoss JIRA] (WFLY-3212) Access Base URI without CDI
Brian Stansberry (JIRA)
issues at jboss.org
Thu Jul 10 17:22:24 EDT 2014
[ https://issues.jboss.org/browse/WFLY-3212?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Brian Stansberry updated WFLY-3212:
-----------------------------------
Component/s: REST
> Access Base URI without CDI
> ---------------------------
>
> Key: WFLY-3212
> URL: https://issues.jboss.org/browse/WFLY-3212
> Project: WildFly
> Issue Type: Feature Request
> Security Level: Public(Everyone can see)
> Components: REST
> Reporter: Caleb Cushing
> Priority: Minor
>
> I need to get at the baseUri, I'm familliar with this
> @Context
> UriInfo uriInfo;
> my problem is I need the baseUri in a piece of code I can't Inject into, (a sub object of an entity). I could pass `uriInfo` or the builder down but that doesn't seem ideal, as most of the objects have no business knowing about it. The end goal is HATEOAS URI's in my JSON responses, but I don't need it to be a JAX-RS specific solution, I figure if I can just get at the Base URI either in my jackson converters, or entities, I can create the `URIBuilder` from there. It seems to me that once the app is deployed the base uri could be a global singleton.
> This is requesting a feature that allows me to access the base uri in the application or a URIBuilder similar to UriInfo.getBaseUriBuilder() except without requiring that the object be injected, this object would obviously not have request specific information
--
This message was sent by Atlassian JIRA
(v6.2.6#6264)
More information about the jboss-jira
mailing list