Rakesh:
For login error, redirect using LoginErrorServlet.
Seems correct, but I cannot contribute much here because it has been a
while since I did much with the login processing. It seems to me that
the existing implementation handles this smoothy, including login
failure counts and other security features. Is there some feature that
is missing here that you'd like to see? If so, it might be general
enough to be added to the product.
For Database connection fail, Jetspeed use ProfilerValveImpl for redirecting.
This seems incorrect. The portlets themselves must take responsibility
for handling errors. In turn, they can redirect and/or modify session
state so that subsequent requests to the portal are routed based on a
different set of profiling rules. The security application uses this
technique to force the end user to change passwords using the
"MyAccount.psml" page. Here, you may want to simply force the display of
a DBIsDown.psml page using a profiling rule override. Note that the
profiler is very flexible and can be used in many different ways to
interpret request urls... all without code modification of any sort. So,
yes, the profiler is performing the "redirection" in a sense, but it
does not require programmatic extension.
HTH,
Randy
The way I tested:
1. Shut down external database (Not Hypersonic Database )
2. In normal, when user login, it goes to user specific psml file. And whatever
portlets mentioned in the psml file gets displayed. The information displayed
by the portlets are from external database.
3. As in step 1 database is down. As database is not available, by default jetspeed call
ProfilerValveImpl (portlet code are not executing) and redirects to jetspeed default
page. So instead of displaying jetspeed default page, I would like to display some error
message as "Database is down".
Please correct me if I am wrong:
I use ProfilerValveImpl for handling psml file Exception (No database available).
Regards
Rakesh
Randy Watler <[EMAIL PROTECTED]> wrote:
Rakesh,
I am afraid I do not understand your needs fully, so it is hard to
suggest the best implementation.
Exactly under what conditions do you want to redirect to an error page
instead of the default page? If it is after a failed login, there might
be a better way to accomplish what you are after.
Randy
Tomba Rakesh wrote:
Hi Randy
Thanks for your quick response. Sorry I really forgot, that's why it was cross
post.
Actually my requirement is redirect to our error page if something goes wrong.
By default it redirect to jetspeed's default-page.psml
Types of Login:
Type 1. Once user sucessfully login to our application, username and password
is redirected to jetspeed's LoginProxyServlet.
Type 2. Login from jetspeed's default page.
For login Type 2, we would like forward to jetspeed default page. For Type 1,
we would like forward to our error page.
So if have a class MyProfilerValveImpl this will always redirected to our page.
Where to put this entry before or after ProfilerValveImpl.
class="org.apache.jetspeed.profiler.impl.ProfilerValveImpl"
init-method="initialize"
Regards
Rakesh
Randy Watler wrote:
Rakesh,
I have asked before... please do NOT cross post to this list and the dev
list.
The ProfilerValveImpl is part of the J2 request pipeline. It is
configured using spring in the assembly/pipelines.xml file.
However, it is non-trivial to replace its functionality. If you simply
want to extend it, you might want to consider adding additional stages
in the pipeline before or after the existing impl instead.
Randy
Tomba Rakesh wrote:
Hi All
1. Which class or servlet calls
org.apache.jetspeed.profiler.impl.ProfilerValveImpl
2. Is it possible to provide a new ProfilerValveImpl, if so where where to
configuration?
Thanks in advance
Regards
Rakesh
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]