You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by evan <sp...@eustace.net> on 2005/02/28 19:53:30 UTC
Running Tapestry 3.1
Perhaps I am getting ahead of myself - Is it even possible to run 3.1 yet?
My first attempts using the alpha binary distribution have failed, I
get the following startup error from Tomcat:
2005-02-28 13:38:05 StandardContext[/taptest5]Servlet /taptest5 threw
load() exception <snip>
Caused by: org.apache.hivemind.ApplicationRuntimeException: Element
provider (at
jar:file:/E:/Tomcat5/Tomcat%205.0/webapps/taptest5/WEB-INF/lib/tapestry-3.1-alpha-1.jar!/META-INF/tapestry.enhance.xml,
line 281, column 64) contains errors: Value for attribute 'prefix'
('class') duplicates a prior instance at
jar:file:/E:/Tomcat5/Tomcat%205.0/webapps/taptest5/WEB-INF/lib/hivemind-1.1-alpha-2.jar!/META-INF/hivemodule.xml,
line 707, column 64.
[jar:file:/E:/Tomcat5/Tomcat%205.0/webapps/taptest5/WEB-INF/lib/tapestry-3.1-alpha-1.jar!/META-INF/tapestry.enhance.xml,
line 281, column 64]
If is is possible to run Tapestry 3.1 can anyone give me pointers - what
particular jars to include, any necessary configs to get it running?
tia,
evan
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
Re: Tracking login with declerative security.
Posted by Matt Raible <li...@raibledesigns.com>.
You could just use request.getRemoteUser() - that'll give you the
username of the logged in user.
Matt
On Feb 28, 2005, at 2:44 PM, Anastasios Angelidis wrote:
> So I have manged to get friendly URLs working. I also have my security
> working. So when a specific URL is accessed, a user is presented with
> the basic auth window...
>
> What I would like to do, is once that user has been authed to track
> that principal so I can use to query for data realted to that user.
>
> So I figure once the home page of the secured resource is hit, to get
> the principal from the servlet context and store it into the Visit
> object.
>
> This should be done in the init phase of the home page right? Also I
> would check that the principal is not null in the Visit object and
> only add if it hasn't?
>
> Thanks
>
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
Re: Tracking login with declerative security.
Posted by Anastasios Angelidis <vo...@videotron.ca>.
Ok I see...
I had to add the servlet jar to the build path... Iguess this is an
eclipse bug :|
But shouldn't code complition still show all message signatures anyways?
Anastasios Angelidis wrote:
> Humm I see... at least in eclipse code complition...
>
> String cycle.getRequestContext.getRequestURI()
>
> Paul Ferraro wrote:
>
>> Yup.
>> cycle.getRequestContext().getRequest();
>>
>> Paul
>>
>> Anastasios Angelidis wrote:
>>
>>> Cool the HttpServletRequest is available through what class?
>>>
>>> It's not IRequestCycle is it?
>>>
>>> Paul Ferraro wrote:
>>>
>>>> There is really no reason to store the Principal in your Visit
>>>> object. Once authenticated, HttpServletRequest.getUserPrincipal()
>>>> will return the appropriate value every request.
>>>>
>>>> Paul
>>>>
>>>> Anastasios Angelidis wrote:
>>>>
>>>>> So I have manged to get friendly URLs working. I also have my
>>>>> security working. So when a specific URL is accessed, a user is
>>>>> presented with the basic auth window...
>>>>>
>>>>> What I would like to do, is once that user has been authed to
>>>>> track that principal so I can use to query for data realted to
>>>>> that user.
>>>>>
>>>>> So I figure once the home page of the secured resource is hit, to
>>>>> get the principal from the servlet context and store it into the
>>>>> Visit object.
>>>>>
>>>>> This should be done in the init phase of the home page right? Also
>>>>> I would check that the principal is not null in the Visit object
>>>>> and only add if it hasn't?
>>>>>
>>>>> Thanks
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
>>>>> For additional commands, e-mail:
>>>>> tapestry-user-help@jakarta.apache.org
>>>>>
>>>>
>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
>>>> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>>>>
>>>>
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
>>> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
>> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>>
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
Re: Tracking login with declerative security.
Posted by Anastasios Angelidis <vo...@videotron.ca>.
Humm I see... at least in eclipse code complition...
String cycle.getRequestContext.getRequestURI()
Paul Ferraro wrote:
> Yup.
> cycle.getRequestContext().getRequest();
>
> Paul
>
> Anastasios Angelidis wrote:
>
>> Cool the HttpServletRequest is available through what class?
>>
>> It's not IRequestCycle is it?
>>
>> Paul Ferraro wrote:
>>
>>> There is really no reason to store the Principal in your Visit
>>> object. Once authenticated, HttpServletRequest.getUserPrincipal()
>>> will return the appropriate value every request.
>>>
>>> Paul
>>>
>>> Anastasios Angelidis wrote:
>>>
>>>> So I have manged to get friendly URLs working. I also have my
>>>> security working. So when a specific URL is accessed, a user is
>>>> presented with the basic auth window...
>>>>
>>>> What I would like to do, is once that user has been authed to track
>>>> that principal so I can use to query for data realted to that user.
>>>>
>>>> So I figure once the home page of the secured resource is hit, to
>>>> get the principal from the servlet context and store it into the
>>>> Visit object.
>>>>
>>>> This should be done in the init phase of the home page right? Also
>>>> I would check that the principal is not null in the Visit object
>>>> and only add if it hasn't?
>>>>
>>>> Thanks
>>>>
>>>>
>>>>
>>>>
>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
>>>> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>>>>
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
>>> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>>>
>>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
>> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
Re: Tracking login with declerative security.
Posted by Paul Ferraro <pm...@columbia.edu>.
Yup.
cycle.getRequestContext().getRequest();
Paul
Anastasios Angelidis wrote:
> Cool the HttpServletRequest is available through what class?
>
> It's not IRequestCycle is it?
>
> Paul Ferraro wrote:
>
>> There is really no reason to store the Principal in your Visit
>> object. Once authenticated, HttpServletRequest.getUserPrincipal()
>> will return the appropriate value every request.
>>
>> Paul
>>
>> Anastasios Angelidis wrote:
>>
>>> So I have manged to get friendly URLs working. I also have my
>>> security working. So when a specific URL is accessed, a user is
>>> presented with the basic auth window...
>>>
>>> What I would like to do, is once that user has been authed to track
>>> that principal so I can use to query for data realted to that user.
>>>
>>> So I figure once the home page of the secured resource is hit, to
>>> get the principal from the servlet context and store it into the
>>> Visit object.
>>>
>>> This should be done in the init phase of the home page right? Also I
>>> would check that the principal is not null in the Visit object and
>>> only add if it hasn't?
>>>
>>> Thanks
>>>
>>>
>>>
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
>>> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
>> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>>
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
Re: Tracking login with declerative security.
Posted by Anastasios Angelidis <vo...@videotron.ca>.
Cool the HttpServletRequest is available through what class?
It's not IRequestCycle is it?
Paul Ferraro wrote:
> There is really no reason to store the Principal in your Visit object.
> Once authenticated, HttpServletRequest.getUserPrincipal() will return
> the appropriate value every request.
>
> Paul
>
> Anastasios Angelidis wrote:
>
>> So I have manged to get friendly URLs working. I also have my
>> security working. So when a specific URL is accessed, a user is
>> presented with the basic auth window...
>>
>> What I would like to do, is once that user has been authed to track
>> that principal so I can use to query for data realted to that user.
>>
>> So I figure once the home page of the secured resource is hit, to get
>> the principal from the servlet context and store it into the Visit
>> object.
>>
>> This should be done in the init phase of the home page right? Also I
>> would check that the principal is not null in the Visit object and
>> only add if it hasn't?
>>
>> Thanks
>>
>>
>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
>> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
Re: Tracking login with declerative security.
Posted by Paul Ferraro <pm...@columbia.edu>.
There is really no reason to store the Principal in your Visit object.
Once authenticated, HttpServletRequest.getUserPrincipal() will return
the appropriate value every request.
Paul
Anastasios Angelidis wrote:
> So I have manged to get friendly URLs working. I also have my security
> working. So when a specific URL is accessed, a user is presented with
> the basic auth window...
>
> What I would like to do, is once that user has been authed to track
> that principal so I can use to query for data realted to that user.
>
> So I figure once the home page of the secured resource is hit, to get
> the principal from the servlet context and store it into the Visit
> object.
>
> This should be done in the init phase of the home page right? Also I
> would check that the principal is not null in the Visit object and
> only add if it hasn't?
>
> Thanks
>
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
Tracking login with declerative security.
Posted by Anastasios Angelidis <vo...@videotron.ca>.
So I have manged to get friendly URLs working. I also have my security
working. So when a specific URL is accessed, a user is presented with
the basic auth window...
What I would like to do, is once that user has been authed to track that
principal so I can use to query for data realted to that user.
So I figure once the home page of the secured resource is hit, to get
the principal from the servlet context and store it into the Visit object.
This should be done in the init phase of the home page right? Also I
would check that the principal is not null in the Visit object and only
add if it hasn't?
Thanks
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
Re: Running Tapestry 3.1
Posted by evan <sp...@eustace.net>.
Thanks, working now.
Hugo Palma wrote:
> You can't use hivemind alpha-2 with tapestry alpha-1. Use hivemind
> alpha-1 instead.
>
> evan wrote:
>
>> Perhaps I am getting ahead of myself - Is it even possible to run 3.1
>> yet?
>> My first attempts using the alpha binary distribution have failed, I
>> get the following startup error from Tomcat:
>>
>> 2005-02-28 13:38:05 StandardContext[/taptest5]Servlet /taptest5 threw
>> load() exception <snip>
>> Caused by: org.apache.hivemind.ApplicationRuntimeException: Element
>> provider (at
>> jar:file:/E:/Tomcat5/Tomcat%205.0/webapps/taptest5/WEB-INF/lib/tapestry-3.1-alpha-1.jar!/META-INF/tapestry.enhance.xml,
>> line 281, column 64) contains errors: Value for attribute 'prefix'
>> ('class') duplicates a prior instance at
>> jar:file:/E:/Tomcat5/Tomcat%205.0/webapps/taptest5/WEB-INF/lib/hivemind-1.1-alpha-2.jar!/META-INF/hivemodule.xml,
>> line 707, column 64.
>> [jar:file:/E:/Tomcat5/Tomcat%205.0/webapps/taptest5/WEB-INF/lib/tapestry-3.1-alpha-1.jar!/META-INF/tapestry.enhance.xml,
>> line 281, column 64]
>>
>>
>> If is is possible to run Tapestry 3.1 can anyone give me pointers -
>> what particular jars to include, any necessary configs to get it running?
>>
>> tia,
>> evan
>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
>> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
Re: Running Tapestry 3.1
Posted by Hugo Palma <hp...@digitalis.pt>.
You can't use hivemind alpha-2 with tapestry alpha-1. Use hivemind
alpha-1 instead.
evan wrote:
> Perhaps I am getting ahead of myself - Is it even possible to run 3.1
> yet?
> My first attempts using the alpha binary distribution have failed, I
> get the following startup error from Tomcat:
>
> 2005-02-28 13:38:05 StandardContext[/taptest5]Servlet /taptest5 threw
> load() exception <snip>
> Caused by: org.apache.hivemind.ApplicationRuntimeException: Element
> provider (at
> jar:file:/E:/Tomcat5/Tomcat%205.0/webapps/taptest5/WEB-INF/lib/tapestry-3.1-alpha-1.jar!/META-INF/tapestry.enhance.xml,
> line 281, column 64) contains errors: Value for attribute 'prefix'
> ('class') duplicates a prior instance at
> jar:file:/E:/Tomcat5/Tomcat%205.0/webapps/taptest5/WEB-INF/lib/hivemind-1.1-alpha-2.jar!/META-INF/hivemodule.xml,
> line 707, column 64.
> [jar:file:/E:/Tomcat5/Tomcat%205.0/webapps/taptest5/WEB-INF/lib/tapestry-3.1-alpha-1.jar!/META-INF/tapestry.enhance.xml,
> line 281, column 64]
>
>
> If is is possible to run Tapestry 3.1 can anyone give me pointers -
> what particular jars to include, any necessary configs to get it running?
>
> tia,
> evan
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org