I've been playing with the REST functionality in Railo 4, with limited success...
I have two paths set up, the first works exactly as I'd expect but requests to the second seem to exist outside of the application...
I have two mappings:
/api
and /admin/api
I created /admin/api
first, I'm not sure if that makes a difference, but everything is working fine there and not in /api
.
I have the following components in both:
<cffunction
name="test"
access="remote"
returntype="struct"
returnformat="json"
output="true"
httpmethod="GET"
>
<cfscript>
return Application;
</cfscript>
</cffunction>
In my application I have a bunch of variables that are created onApplicationStart
- if I run this component from /admin/api
they are all available to me, however running the exact same component from /api
I don't have any!
I set up the /admin/api
a while ago and have had it functioning with no problems - I'm wondering if I've missed a step when I set up /api
...
Can anyone explain why I would have access to the application variables in one path, but not in the other?