Hi,

On Sun, Dec 5, 2010 at 8:52 AM, Unmesh Joshi <[email protected]> wrote:
> I my example a valid thing to do in apache sling? Because nothing
> there is a JCR resource node.. So I probably need to write a custom
> resource resolver which resolves my application urls to resources and
> then write a servlet which acts on these resources...

IIUC your examples has two main parts:

1) Login to Sling using credentials coming from an external system
For this you might want to study how Sling authentication works, start
at http://sling.apache.org/site/authentication.html

There should be sufficient extension points to plugin any type of
authentication.

2) Displaying user profiles that mix Sling data with external data
As you say, you could implement a resource resolver for the external
data, that's the most integrated way of doing it.

You could also just call up that data on demand, from the script or
servlet that does the rendering of the user profile, and just
integrate the external data in the rendered output.

> ...The tricky bit is
> I do not get any support for DI the way MVC frameworks like spring-mvc
> or struts provide. So I need to write custom servlets for all the
> resources and somehow integrate with Dependency injection framework....

>
> If I have an existing application that uses spring-mvc or struts..
> There is no way to fit that on Day CQ then?...

We do not answer questions specific to Day CQ here. About "fitting
such apps on Sling", I guess it depends how much integration you need.
To me, and without deep knowledge of either Spring MVC or Struts,
running those in distinct webapps and collaborating with the Sling app
might be the less risky option.

-Bertrand

Reply via email to