Re: How to add a link to a file stored in directory?

2013-06-04 Thread mailingl...@j-b-s.de
Hi Petr! You are really refering to a file in your src directory? When you use maven to build it the file is copied to target/ and you access it simply by "return.txt" using the classloader because target/resources is stripped when building the jar/war. Set a break point and check if you reall

Re: How to add a link to a file stored in directory?

2013-06-04 Thread Geoff Callender
1. What happens? Is an exception thrown? 2. If you upload to the file system, like the jumpstart example does; then you should download from the file system - but your example, below, is downloading from a path relative to the classpath of the web app. Try this instead: inputStream = ne

Re: FormFragment stops working after refreshing containing zone

2013-06-04 Thread Ilya Obshadko
On Tue, Jun 4, 2013 at 8:50 PM, Lance Java wrote: > Short answer: > Try … > > > > Long answer: > The form's zone parameter refers to the zone's clientId (not to be confused > with the serverside id). Tapestry will auto generate a unique clientId for > your zone unless you provide an explicit clien

Re: FormFragment stops working after refreshing containing zone

2013-06-04 Thread Ilya Obshadko
I'm using multiple zone update. Hence, it's AjaxResponseRenderer and void onSuccessFromForm (). On Tue, Jun 4, 2013 at 8:55 PM, Lance Java wrote: > Also, what are you returning from your submit event? zone or > zone.getBody()? > > You should return the latter > -- Ilya Obshadko

How to add a link to a file stored in directory?

2013-06-04 Thread Petr Janata
Hi, thanks for links with ideas. I am new in Tapestry I use Example App from Jumpstart tutorial . I added File Upload to Example App and HSQL table for up

Tapestry 5.4-alpha-8

2013-06-04 Thread Howard Lewis Ship
Fixed another annoying bug and cleaned up a couple of more things. Maven repository: https://repository.apache.org/content/repositories/orgapachetapestry-071/ -- Howard M. Lewis Ship Creator of Apache Tapestry The source for Tapestry training, mentoring and support. Contact me to learn how I c

Re: Contribute multiple collections in the same service?

2013-06-04 Thread Howard Lewis Ship
There's a huge complexity cost for allowing a single service to expose multiple configurations, and its rare to need. Often, a solution that breaks the single service into two (or more) services, even if just to support the constraint of a single configuration, leads to better, more testable code a

Re: Tapestry Security / page instance / invocation question

2013-06-04 Thread Richard Frovarp
On 06/04/2013 11:03 AM, Dmitry Gusev wrote: Just a note that you always can write your own component like this if you want: That's probably the better long term solution for my environment. On Tue, Jun 4, 2013 at 7:50 PM, Richard Frovarp wrote: That would work. The trick is that I need

Re: Tapestry links not https

2013-06-04 Thread Dmitry Gusev
Here's how I solve this problem with Tomcat and OpenShift: I declare these Symbol values: tapestry.hostname=.rhcloud.com tapestry.hostport=80 tapestry.hostport-secure=443 tapestry.secure-enabled=true I put @Secure to my pages. And I declare RemoteIpValve in my application context like this:

Re: Tapestry Security / page instance / invocation question

2013-06-04 Thread Dmitry Gusev
Just a note that you always can write your own component like this if you want: On Tue, Jun 4, 2013 at 7:50 PM, Richard Frovarp wrote: > That would work. The trick is that I need to compute the permissions > dynamically. I'll have to add in more code to handle those types of > wildcard permiss

Re: Tapestry links not https

2013-06-04 Thread Richard Frovarp
On 05/31/2013 02:45 PM, John wrote: My tapestry app doesn't work with SSL set up, the links have port 443 added but start http://. There must be some configuration missing? John You may also want to look at: MetaDatConstants.SECURE_PAGE. I know even with AJP proxying to Tomcat, we've ran i

Re: Tapestry Security / page instance / invocation question

2013-06-04 Thread Richard Frovarp
That would work. The trick is that I need to compute the permissions dynamically. I'll have to add in more code to handle those types of wildcard permissions. I was hoping for something much more similar to what I can use with the @RequiresPermissions check. But since I don't have an invocation

Re: Contribute multiple collections in the same service?

2013-06-04 Thread Lance Java
Yes, this is a limitation of tapestry contributions. This can be worked around. Create a MapConfigProvider service which has a getter for the MapConfig collection. Contribute MapConfig objects to the MapConfigProvider. Then pass the MapConfigProvider and the second collection to your HazelcastCon

Contribute multiple collections in the same service?

2013-06-04 Thread Ferran Maylinch
Hello, I would like to contribute 2 collections to a service, but I am afraid Tapestry only supports one collection to be contributed. Am I right? My service constructor is like this: public HazelcastConfigServiceImpl( final Collection mapConfigs, final Collection hzConfigurers) { ... } And I

Re: FormFragment stops working after refreshing containing zone

2013-06-04 Thread Lance Java
Also, what are you returning from your submit event? zone or zone.getBody()? You should return the latter

Re: FormFragment stops working after refreshing containing zone

2013-06-04 Thread Lance Java
Short answer: Try … Long answer: The form's zone parameter refers to the zone's clientId (not to be confused with the serverside id). Tapestry will auto generate a unique clientId for your zone unless you provide an explicit clientId.

Re: Tapetsry IoC service constructor

2013-06-04 Thread Kalle Korhonen
I bet this is mentioned somewhere, but you have to use field injection with multiple persistence contexts - it's a limitation of tapestry-jpa. Kalle On Tue, Jun 4, 2013 at 1:44 AM, John wrote: > The following is invalid, how to do it properly please? The docs assume > field level injection and

Tapetsry IoC service constructor

2013-06-04 Thread John
The following is invalid, how to do it properly please? The docs assume field level injection and don't discus contructor based dependency. John public AuditingDAO(@PersistenceContext(unitName = "DBUnit") EntityManager entityManager) { ...