RE: Action Handler not being called component

2014-11-14 Thread nhhockeyplayer nashua
Folks,

I attached the console stack trace

the request object is getting totaled

I am hoping someone can make some sense out of it

its almost, and I am guessing, someone is using a t5 Request, when it should be 
an HttpRequest ? just a guess... importing the wrong object could force 
operation on a wrong type at runtime.

Thanks

[INFO] Scanning for projects...
[INFO] Downloading: 
http://download.eclipse.org/rt/eclipselink/maven.repo/org/psi/psi-parent/0.0.1-SNAPSHOT/maven-metadata.xml
[WARNING] Could not transfer metadata 
org.psi:psi-parent:0.0.1-SNAPSHOT/maven-metadata.xml from/to EclipseLink Repo I 
(http://download.eclipse.org/rt/eclipselink/maven.repo): Connection refused: 
connect
[INFO] 
[INFO] Using the builder 
org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder
 with a thread count of 1
[INFO] 
[INFO] 
[INFO] Building PSI Example - psi 1.0-SNAPSHOT
[INFO] 
[INFO] 
[INFO] >>> maven-jetty-plugin:6.1.26:run (default-cli) @ psi >>>
[INFO] Downloading: 
http://download.eclipse.org/rt/eclipselink/maven.repo/org/tynamo/tapestry-hibernate-seedentity/0.1.4-SNAPSHOT/maven-metadata.xml
[INFO] Downloading: 
http://nexus.codehaus.org/snapshots/org/tynamo/tapestry-hibernate-seedentity/0.1.4-SNAPSHOT/maven-metadata.xml
[INFO] Downloading: 
http://nexus.devlab722.net/nexus/content/repositories/snapshots/org/tynamo/tapestry-hibernate-seedentity/0.1.4-SNAPSHOT/maven-metadata.xml
[WARNING] Could not transfer metadata 
org.tynamo:tapestry-hibernate-seedentity:0.1.4-SNAPSHOT/maven-metadata.xml 
from/to EclipseLink Repo I 
(http://download.eclipse.org/rt/eclipselink/maven.repo): Connection refused: 
connect
[WARNING] Could not transfer metadata 
org.tynamo:tapestry-hibernate-seedentity:0.1.4-SNAPSHOT/maven-metadata.xml 
from/to Got5 SNAPSHOTS 
(http://nexus.devlab722.net/nexus/content/repositories/snapshots/): Connection 
refused: connect
[WARNING] Could not transfer metadata 
org.tynamo:tapestry-hibernate-seedentity:0.1.4-SNAPSHOT/maven-metadata.xml 
from/to codehaus-snapshots (http://nexus.codehaus.org/snapshots/): Connection 
refused: connect
[WARNING] Failure to transfer 
org.tynamo:tapestry-hibernate-seedentity:0.1.4-SNAPSHOT/maven-metadata.xml from 
http://download.eclipse.org/rt/eclipselink/maven.repo was cached in the local 
repository, resolution will not be reattempted until the update interval of 
EclipseLink Repo I has elapsed or updates are forced. Original error: Could not 
transfer metadata 
org.tynamo:tapestry-hibernate-seedentity:0.1.4-SNAPSHOT/maven-metadata.xml 
from/to EclipseLink Repo I 
(http://download.eclipse.org/rt/eclipselink/maven.repo): Connection refused: 
connect
[WARNING] Failure to transfer 
org.tynamo:tapestry-hibernate-seedentity:0.1.4-SNAPSHOT/maven-metadata.xml from 
http://nexus.devlab722.net/nexus/content/repositories/snapshots/ was cached in 
the local repository, resolution will not be reattempted until the update 
interval of Got5 SNAPSHOTS has elapsed or updates are forced. Original error: 
Could not transfer metadata 
org.tynamo:tapestry-hibernate-seedentity:0.1.4-SNAPSHOT/maven-metadata.xml 
from/to Got5 SNAPSHOTS 
(http://nexus.devlab722.net/nexus/content/repositories/snapshots/): Connection 
refused: connect
[WARNING] Failure to transfer 
org.tynamo:tapestry-hibernate-seedentity:0.1.4-SNAPSHOT/maven-metadata.xml from 
http://nexus.codehaus.org/snapshots/ was cached in the local repository, 
resolution will not be reattempted until the update interval of 
codehaus-snapshots has elapsed or updates are forced. Original error: Could not 
transfer metadata 
org.tynamo:tapestry-hibernate-seedentity:0.1.4-SNAPSHOT/maven-metadata.xml 
from/to codehaus-snapshots (http://nexus.codehaus.org/snapshots/): Connection 
refused: connect
[INFO] Downloading: 
http://download.eclipse.org/rt/eclipselink/maven.repo/org/tynamo/tynamo-parent/0.0.13-SNAPSHOT/maven-metadata.xml
[INFO] Downloading: 
http://nexus.codehaus.org/snapshots/org/tynamo/tynamo-parent/0.0.13-SNAPSHOT/maven-metadata.xml
[INFO] Downloading: 
http://nexus.devlab722.net/nexus/content/repositories/snapshots/org/tynamo/tynamo-parent/0.0.13-SNAPSHOT/maven-metadata.xml
[WARNING] Could not transfer metadata 
org.tynamo:tynamo-parent:0.0.13-SNAPSHOT/maven-metadata.xml from/to EclipseLink 
Repo I (http://download.eclipse.org/rt/eclipselink/maven.repo): Connection 
refused: connect
[WARNING] Could not transfer metadata 
org.tynamo:tynamo-parent:0.0.13-SNAPSHOT/maven-metadata.xml from/to Got5 
SNAPSHOTS (http://nexus.devlab722.net/nexus/content/repositories/snapshots/): 
Connection refused: connect
[WARNING] Could not transfer metadata 
org.tynamo:tynamo-parent:0.0.13-SNAPSHOT/maven-metadata.xml from/to 
codehaus-snapshots (http://nexus.codehaus.org/snapshots/): Connection refused: 
connect

RE: Action Handler not being called component

2014-11-14 Thread nhhockeyplayer nashua
I connected up the t5-beta-22 source code from my local repo to my run 
environment session

this is where it happens

public ClientPersistentFieldStorageImpl(Request request, ClientDataEncoder 
clientDataEncoder, SessionPersistedObjectAnalyzer analyzer)
{
this.clientDataEncoder = clientDataEncoder;
this.analyzer = analyzer;

// This, here, is the problem of TAPESTRY-2501; this call can predate
// the check to set the character set based on meta data of the page.

String value = request.getParameter(PARAMETER_NAME);

// MIME can encode to a '+' character; the browser converts that to a 
space; we convert it
// back.

clientData = value == null ? null : value.replace(' ', '+');
}

the getParameter gets lost in never never land with NPE blowing everything 
up each time it tries to come thru this code

any ideas ?

Best regards 
and thanks... KEN

From: nhhockeypla...@hotmail.com
To: users@tapestry.apache.org
Subject: RE: Action Handler not being called  component
Date: Fri, 14 Nov 2014 22:52:37 -0500




I attempted enough tries. I hate these corruption bugs

the code is good and something broke it.

here is trace

something is getting mauled

any ideas what to do ? zones wont help... oir will they and if so why

HTTP ERROR 500
Problem accessing /psi/home.galleryform/player. Reason:

org.apache.tapestry5.ioc.internal.OperationException: Error invoking 
constructor public 
org.apache.tapestry5.internal.services.ClientPersistentFieldStorageImpl(org.apache.tapestry5.services.Request,org.apache.tapestry5.services.ClientDataEncoder,org.apache.tapestry5.services.SessionPersistedObjectAnalyzer):
 java.lang.NullPointerExceptionCaused 
by:org.apache.shiro.subject.ExecutionException: 
org.apache.tapestry5.ioc.internal.OperationException: Error invoking 
constructor public 
org.apache.tapestry5.internal.services.ClientPersistentFieldStorageImpl(org.apache.tapestry5.services.Request,org.apache.tapestry5.services.ClientDataEncoder,org.apache.tapestry5.services.SessionPersistedObjectAnalyzer):
 java.lang.NullPointerException
at 
org.apache.shiro.subject.support.DelegatingSubject.execute(DelegatingSubject.java:385)
at 
org.tynamo.security.services.impl.SecurityConfiguration.service(SecurityConfiguration.java:54)
at $HttpServletRequestFilter_1004cee2b454.service(Unknown Source)
at $HttpServletRequestHandler_1004cee2b457.service(Unknown Source)
at 
org.apache.tapestry5.upload.internal.services.MultipartServletRequestFilter.service(MultipartServletRequestFilter.java:45)
at $HttpServletRequestHandler_1004cee2b457.service(Unknown Source)
at 
org.apache.tapestry5.internal.gzip.GZipFilter.service(GZipFilter.java:59)
at $HttpServletRequestHandler_1004cee2b457.service(Unknown Source)
at 
org.apache.tapestry5.internal.services.IgnoredPathsFilter.service(IgnoredPathsFilter.java:62)
at $HttpServletRequestFilter_1004cee2b450.service(Unknown Source)
at $HttpServletRequestHandler_1004cee2b457.service(Unknown Source)
at 
org.apache.tapestry5.modules.TapestryModule$1.service(TapestryModule.java:804)
at $HttpServletRequestHandler_1004cee2b457.service(Unknown Source)
at $HttpServletRequestHandler_1004cee2b44f.service(Unknown Source)
at org.apache.tapestry5.TapestryFilter.doFilter(TapestryFilter.java:166)
at 
org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1212)
at 
org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:399)
at 
org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216)
at 
org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182)
at 
org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:766)
at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:450)
at 
org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:230)
at 
org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114)
at 
org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
at org.mortbay.jetty.Server.handle(Server.java:326)
at 
org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:542)
at 
org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:945)
at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:756)
at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:218)
at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
at 
org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:410)
at 
org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:582)
Caused by: org.apache.tapestry5.ioc.internal.OperationException: Error invoking 
constructor public 
org.apache.tapestry5.i

RE: Action Handler not being called component

2014-11-14 Thread nhhockeyplayer nashua
I attempted enough tries. I hate these corruption bugs

the code is good and something broke it.

here is trace

something is getting mauled

any ideas what to do ? zones wont help... oir will they and if so why

HTTP ERROR 500
Problem accessing /psi/home.galleryform/player. Reason:

org.apache.tapestry5.ioc.internal.OperationException: Error invoking 
constructor public 
org.apache.tapestry5.internal.services.ClientPersistentFieldStorageImpl(org.apache.tapestry5.services.Request,org.apache.tapestry5.services.ClientDataEncoder,org.apache.tapestry5.services.SessionPersistedObjectAnalyzer):
 java.lang.NullPointerExceptionCaused 
by:org.apache.shiro.subject.ExecutionException: 
org.apache.tapestry5.ioc.internal.OperationException: Error invoking 
constructor public 
org.apache.tapestry5.internal.services.ClientPersistentFieldStorageImpl(org.apache.tapestry5.services.Request,org.apache.tapestry5.services.ClientDataEncoder,org.apache.tapestry5.services.SessionPersistedObjectAnalyzer):
 java.lang.NullPointerException
at 
org.apache.shiro.subject.support.DelegatingSubject.execute(DelegatingSubject.java:385)
at 
org.tynamo.security.services.impl.SecurityConfiguration.service(SecurityConfiguration.java:54)
at $HttpServletRequestFilter_1004cee2b454.service(Unknown Source)
at $HttpServletRequestHandler_1004cee2b457.service(Unknown Source)
at 
org.apache.tapestry5.upload.internal.services.MultipartServletRequestFilter.service(MultipartServletRequestFilter.java:45)
at $HttpServletRequestHandler_1004cee2b457.service(Unknown Source)
at 
org.apache.tapestry5.internal.gzip.GZipFilter.service(GZipFilter.java:59)
at $HttpServletRequestHandler_1004cee2b457.service(Unknown Source)
at 
org.apache.tapestry5.internal.services.IgnoredPathsFilter.service(IgnoredPathsFilter.java:62)
at $HttpServletRequestFilter_1004cee2b450.service(Unknown Source)
at $HttpServletRequestHandler_1004cee2b457.service(Unknown Source)
at 
org.apache.tapestry5.modules.TapestryModule$1.service(TapestryModule.java:804)
at $HttpServletRequestHandler_1004cee2b457.service(Unknown Source)
at $HttpServletRequestHandler_1004cee2b44f.service(Unknown Source)
at org.apache.tapestry5.TapestryFilter.doFilter(TapestryFilter.java:166)
at 
org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1212)
at 
org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:399)
at 
org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216)
at 
org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182)
at 
org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:766)
at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:450)
at 
org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:230)
at 
org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114)
at 
org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
at org.mortbay.jetty.Server.handle(Server.java:326)
at 
org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:542)
at 
org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:945)
at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:756)
at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:218)
at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
at 
org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:410)
at 
org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:582)
Caused by: org.apache.tapestry5.ioc.internal.OperationException: Error invoking 
constructor public 
org.apache.tapestry5.internal.services.ClientPersistentFieldStorageImpl(org.apache.tapestry5.services.Request,org.apache.tapestry5.services.ClientDataEncoder,org.apache.tapestry5.services.SessionPersistedObjectAnalyzer):
 java.lang.NullPointerException
at 
org.apache.tapestry5.ioc.internal.OperationTrackerImpl.logAndRethrow(OperationTrackerImpl.java:184)
at 
org.apache.tapestry5.ioc.internal.OperationTrackerImpl.invoke(OperationTrackerImpl.java:90)
at 
org.apache.tapestry5.ioc.internal.PerThreadOperationTracker.invoke(PerThreadOperationTracker.java:72)
at 
org.apache.tapestry5.ioc.internal.RegistryImpl.invoke(RegistryImpl.java:1258)
at 
org.apache.tapestry5.ioc.internal.util.ConstructionPlan.createObject(ConstructionPlan.java:61)
at 
org.apache.tapestry5.ioc.internal.ConstructorServiceCreator.createObject(ConstructorServiceCreator.java:62)
at 
org.apache.tapestry5.ioc.internal.OperationTrackingObjectCreator$1.invoke(OperationTrackingObjectCreator.java:47)
at 
org.apache.tapestry5.ioc.internal.OperationTrackerImpl.invoke(OperationTrackerImpl

Re: GAE & 5.4-beta22 - access denied for "modifyThreadGroup"

2014-11-14 Thread Alex Kotchnev
Well - it looks like this modifyThreadGroup permission is checked when
getting ThreadGroup.getParent only when it reaches the "rootGroup", which
is supposedly somehow special (
http://grepcode.com/file/repository.grepcode.com/java/root/jdk/openjdk/6-b14/java/lang/SecurityManager.java#SecurityManager.getRootGroup%28%29).
Is there a reason to actually need to show this rootGroup ? In general,
this should only happen when new Threads are created, which is why this is
restricted in GAE:

* Throws a SecurityException if the
 * calling thread is not allowed to modify the thread group argument.
 * 
 * This method is invoked for the current security manager when a
 * new child thread or child thread group is created, and by the
 * setDaemon, setMaxPriority,
 * stop, suspend, resume, and
 * destroy methods of class ThreadGroup.
 * 
 * If the thread group argument is the system thread group (
 * has a null parent) then
 * this method calls checkPermission with the
 * RuntimePermission("modifyThreadGroup") permission.
 * If the thread group argument is not the system thread group,
 * this method just returns silently.
 * 
 * Applications that want a stricter policy should override this
 * method. If this method is overridden, the method that overrides
 * it should additionally check to see if the calling thread has the
 * RuntimePermission("modifyThreadGroup") permission, and
 * if so, return silently. This is to ensure that code granted
 * that permission (such as the JDK itself) is allowed to
 * manipulate any thread.

In general, this is not necessarily a restriction of GAE, this is plain
"java" security check, not something that GAE has added. Granted, this
wouldn't be an issue when running under a servlet container w/o a
SecurityManager.

In any case, I'm just bringing it up for this issue to be known. I know
that in the past , the Tapestry devs have made adjustments to allow for the
widest out-of-the-box compatibility of the framework (e.g. so that it can
work w/ Scala, deploy on AppEngine, etc). As you indicated, there are
workarounds for this, yet for anyone attempting to upgrade from 5.3.7 to
5.4 this would represent a regression in functionality (and really, is it
THAT important to be able to show the list of threads (see attached
screenshot) - at least at first glance, doesn't seem neither too important
or helpful.

[image: Inline image 2]

Cheers - Alex K

On Fri, Nov 14, 2014 at 6:47 PM, Kalle Korhonen 
wrote:

> GAE doesn't like user code calling ThreadGroup.getParent() (line 597 of
> TapestryInternalUtils, in your stack trace) which seems an unnecessary
> restriction given that access to Thread.currentThread().getThreadGroup() is
> allowed. I wouldn't be surprised if there was a bug open against GAE on
> that.
>
> Anyway, you can certainly get it to work on GAE as well. The simple answer
> is that you probably don't want to show the development exception page on
> production anyway. Beyond that, you might need to override
> ExceptionReport.getThreads() to return perhaps just the current thread. I
> don't think the default behavior of Tapestry should change just for GAE.
>
> Kalle
>
> On Fri, Nov 14, 2014 at 3:15 PM, Alex Kotchnev  wrote:
>
> > Bummer, I just confirmed that the same error happens when deployed in
> > AppEngine. At first glance this looked similar to an issue that was
> fixed a
> > couple of years ago (https://issues.apache.org/jira/browse/TAP5-1616),
> but
> > this is definitely different. I do recall that in general in production
> one
> > might want to have a different exception page (than this default), yet I
> > wonder if there is anything that can still be done about this before 5.4
> > goes out (if it's considered important enough for a 5.4 release).
> >
> > Cheers - Alex K
> >
> > On Fri, Nov 14, 2014 at 6:08 PM, Alex Kotchnev 
> wrote:
> >
> > > I took 5.4-beta-22 out for a spin yesterday and I ran into the
> following
> > exception when trying to run the AppEngine local dev server and there is
> an
> > error on the page and Tapestry attempts to display the exception page.
> I'm
> > not yet sure if this is going to work when deployed to AppEngine proper,
> > but I was wondering if there is a way to override either whether the
> > exception page attempts to do this.
> > >
> > >
> > > In the local environment, I can certainly start the local dev server
> > with a -Denable_all_permissions=true option that
> avoids
> > the issue in my local setup, so it's not a massive deal. Yet, this was
> > certainly not happening in 5.3.7 so I wonder what changed.
> > >
> > >
> > > Other than that, 5.4 just looks fantastic - I had been holding off on
> > trying it out , but now I can't wait this release to go out !
> > >
> > > Any ideas ?
> > >
> > >
> > > Cheers -
> > >
> > > org.apache.tapestry5.internal.services.RenderQueueException: Render
> > queue error in SetupRender[core/ExceptionReport:loop_0]: Failur

URL Rewriting to base

2014-11-14 Thread George Christman
Hi guys, so I've managed to find a someone challenging task. I'm creating
profiles and I'd like to create profile domains and do a url rewrite so
those domains appear directly after the baseUrl.

Example domain.com/profile/profiledomain

to

domain.com/profile

now the profiledomain will actually be the context of the profile page and
the context will be stored in the database, so that will need to be
dynamic.

Now I was able to get it to work with this code, but it's a really bad way
of doing it do to the fact a query would take place on every single page in
the app.

 if (path.startsWith("/")) {
String profileDomain = path.substring(path.lastIndexOf("/") +
1, path.length());

UserProfile userprofile = null;

if (profileDomain != null) {
userprofile = crudDAO.getFindByProperty(Profile.class,
"profileDomain", profileDomain);
}

if (userprofile == null) {
return null;
}
return new PageRenderRequestParameters(
"profile",
new URLEventContext(contextValueEncoder, new
String[]{userprofile.getProfileDomain()}),
false);
}

So other than ignoring every package and page, how else could I dynamically
do this?



-- 
George Christman
CEO
www.CarDaddy.com
P.O. Box 735
Johnstown, New York


Re: Minify JS / CSS in production

2014-11-14 Thread George Christman
Thanks guys, I ended up finding it and was able to update it. All fixed.

On Fri, Nov 14, 2014 at 11:17 AM, Kalle Korhonen  wrote:

> Update the version of the offending library, but perhaps not that easy.
> Googling the exception gives you these potential matches:
>
> http://stackoverflow.com/questions/25808115/google-contacts-java-lang-nosuchmethoderror-com-google-common-collect-immutab
>
> http://stackoverflow.com/questions/16475015/nosuchmethoderror-google-common-immutableset-copyof
>
> Kalle
>
>
> On Fri, Nov 14, 2014 at 6:10 AM, Thiago H de Paula Figueiredo <
> thiag...@gmail.com> wrote:
>
> > On Fri, 14 Nov 2014 11:26:54 -0200, George Christman <
> > gchrist...@cardaddy.com> wrote:
> >
> >  So I tried this out last night and ended up with this beautiful
> exception.
> >> Any ideas?
> >>
> >> HTTP Status 500 - java.lang.NoSuchMethodError:
> >> com.google.common.collect.ImmutableSet.of(Ljava/lang/
> >> Object;Ljava/lang/Object;Ljava/lang/Object;Ljava/lang/
> >> Object;Ljava/lang/Object;Ljava/lang/Object;[Ljava/lang/
> >> Object;)Lcom/google/common/collect/ImmutableSet;
> >>
> >
> > This is a Guava dependency version mismatch, not directly related to
> > Tapestry. If you're using Maven, use dependency:tree or the Eclipse
> pom.xml
> > editor to know what's happening.
> >
> >
> > --
> > Thiago H. de Paula Figueiredo
> > Tapestry, Java and Hibernate consultant and developer
> > http://machina.com.br
> >
> > -
> > To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
> > For additional commands, e-mail: users-h...@tapestry.apache.org
> >
> >
>



-- 
George Christman
CEO
www.CarDaddy.com
P.O. Box 735
Johnstown, New York


RE: Action Handler not being called component

2014-11-14 Thread nhhockeyplayer nashua
The gallery widget is geared to collect PLAYERS for now...

when I set items per page (you can try it) to 100 my code works fine and 
refreshes the collection.

when I set items per page to 15

I get the following


http://psinh.ddns.net:9011/psi/home.galleryform/player

The connection was reset

The connection to the server was reset while the page was loading.

The site could be temporarily unavailable or too busy. Try again in a few 
moments.
If you are unable to load any pages, check your computer's network 
connection.
If your computer or network is protected by a firewall or proxy, make sure 
that Firefox is permitted to access the Web.





no error code or anything

cannot even hit a breakpoint.

any thoughts on this are appreciated i am using T5-beta-22
  

RE: Action Handler not being called component

2014-11-14 Thread nhhockeyplayer nashua
Hi Thiago,

Your suggested solution seems fine. But it only goes as far as populating the 
model thru the onChanged event. I dont see theoretically the display being 
rendered again.

My component, in theory, should work fine with parameters and a submit

onchange="galleryForm.submit()"

and historically it has in the past.

I dont understand why its broke or why I NEED to use ZONE. Zones may be fine 
and correct in many other cases but doing the whole refresh thing because my 
collection needs to be structurally re-rendered again seems fine with me.

I guess I am wondering
1. how can I re-render my collection after I populate the model using the zone
 or
2. how can I fix what broke. My code should work as-is. Is galleryForm.submit() 
obsolete ? Some times it works most of time it dont.

Just wondering which way to go with this. If I can get my collection to 
re-render quietly with ajax I will do that but I was ok with the way it was and 
not sure why its broke.

thanks

Best regards 
and thanks... KEN

From: nhhockeypla...@hotmail.com
To: users@tapestry.apache.org
Subject: RE: Action Handler not being called  component
Date: Fri, 14 Nov 2014 18:40:40 -0500




Thank You Thiago,

I will try that this weekend.

If you like you can try my gallery...

its athttp://psinh.ddns.net:9011/psi/home

sometimes when its up its up but other times it might be down.

but its a T5 gallery tynamo version
Best regards 
and thanks... KEN   
  

Re: GAE & 5.4-beta22 - access denied for "modifyThreadGroup"

2014-11-14 Thread Kalle Korhonen
GAE doesn't like user code calling ThreadGroup.getParent() (line 597 of
TapestryInternalUtils, in your stack trace) which seems an unnecessary
restriction given that access to Thread.currentThread().getThreadGroup() is
allowed. I wouldn't be surprised if there was a bug open against GAE on
that.

Anyway, you can certainly get it to work on GAE as well. The simple answer
is that you probably don't want to show the development exception page on
production anyway. Beyond that, you might need to override
ExceptionReport.getThreads() to return perhaps just the current thread. I
don't think the default behavior of Tapestry should change just for GAE.

Kalle

On Fri, Nov 14, 2014 at 3:15 PM, Alex Kotchnev  wrote:

> Bummer, I just confirmed that the same error happens when deployed in
> AppEngine. At first glance this looked similar to an issue that was fixed a
> couple of years ago (https://issues.apache.org/jira/browse/TAP5-1616), but
> this is definitely different. I do recall that in general in production one
> might want to have a different exception page (than this default), yet I
> wonder if there is anything that can still be done about this before 5.4
> goes out (if it's considered important enough for a 5.4 release).
>
> Cheers - Alex K
>
> On Fri, Nov 14, 2014 at 6:08 PM, Alex Kotchnev  wrote:
>
> > I took 5.4-beta-22 out for a spin yesterday and I ran into the following
> exception when trying to run the AppEngine local dev server and there is an
> error on the page and Tapestry attempts to display the exception page. I'm
> not yet sure if this is going to work when deployed to AppEngine proper,
> but I was wondering if there is a way to override either whether the
> exception page attempts to do this.
> >
> >
> > In the local environment, I can certainly start the local dev server
> with a -Denable_all_permissions=true option that avoids
> the issue in my local setup, so it's not a massive deal. Yet, this was
> certainly not happening in 5.3.7 so I wonder what changed.
> >
> >
> > Other than that, 5.4 just looks fantastic - I had been holding off on
> trying it out , but now I can't wait this release to go out !
> >
> > Any ideas ?
> >
> >
> > Cheers -
> >
> > org.apache.tapestry5.internal.services.RenderQueueException: Render
> queue error in SetupRender[core/ExceptionReport:loop_0]: Failure reading
> parameter 'source' of component core/ExceptionReport:loop_0: access denied
> ("java.lang.RuntimePermission" "modifyThreadGroup") [at
> classpath:org/apache/tapestry5/corelib/pages/ExceptionReport.tml, line 110]
> >   at
> org.apache.tapestry5.internal.services.RenderQueueImpl.run(RenderQueueImpl.java:87)
> >   at
> org.apache.tapestry5.internal.services.PageRenderQueueImpl.render(PageRenderQueueImpl.java:114)
> >   at $PageRenderQueue_954065d89e49.render(Unknown Source)
> >   at $PageRenderQueue_954065d89e48.render(Unknown Source)
> >   at
> org.apache.tapestry5.internal.services.MarkupRendererTerminator.renderMarkup(MarkupRendererTerminator.java:37)
> >   at
> org.apache.tapestry5.internal.services.PageNameMetaInjector.renderMarkup(PageNameMetaInjector.java:41)
> >   at $MarkupRenderer_954065d89e4c.renderMarkup(Unknown Source)
> >   at
> org.apache.tapestry5.modules.TapestryModule$29.renderMarkup(TapestryModule.java:1810)
> >   at $MarkupRenderer_954065d89e4c.renderMarkup(Unknown Source)
> >   at
> org.apache.tapestry5.modules.TapestryModule$28.renderMarkup(TapestryModule.java:1800)
> >   at $MarkupRenderer_954065d89e4c.renderMarkup(Unknown Source)
> >   at
> org.apache.tapestry5.modules.TapestryModule$27.renderMarkup(TapestryModule.java:1784)
> >   at $MarkupRenderer_954065d89e4c.renderMarkup(Unknown Source)
> >   at
> org.apache.tapestry5.modules.TapestryModule$26.renderMarkup(TapestryModule.java:1768)
> >   at $MarkupRenderer_954065d89e4c.renderMarkup(Unknown Source)
> >   at
> org.apache.tapestry5.internal.services.javascript.AddBrowserCompatibilityStyles.renderMarkup(AddBrowserCompatibilityStyles.java:45)
> >   at $MarkupRenderer_954065d89e4c.renderMarkup(Unknown Source)
> >   at
> org.apache.tapestry5.internal.services.javascript.ConfigureHTMLElementFilter.renderMarkup(ConfigureHTMLElementFilter.java:45)
> >   at $MarkupRenderer_954065d89e4c.renderMarkup(Unknown Source)
> >   at
> org.apache.tapestry5.modules.JavaScriptModule$1.renderMarkup(JavaScriptModule.java:259)
> >   at $MarkupRenderer_954065d89e4c.renderMarkup(Unknown Source)
> >   at
> org.apache.tapestry5.modules.TapestryModule$25.renderMarkup(TapestryModule.java:1751)
> >   at $MarkupRenderer_954065d89e4c.renderMarkup(Unknown Source)
> >   at $MarkupRenderer_954065d89e47.renderMarkup(Unknown Source)
> >   at
> org.apache.tapestry5.internal.services.PageMarkupRendererImpl.renderPageMarkup(PageMarkupRendererImpl.java:47)
> >   at $PageMarkupRenderer_954065d89e45.renderPageMarkup(Unknown
> Source)
> >   at
> org.apache.tapestry5.int

RE: Action Handler not being called component

2014-11-14 Thread nhhockeyplayer nashua
Thank You Thiago,

I will try that this weekend.

If you like you can try my gallery...

its athttp://psinh.ddns.net:9011/psi/home

sometimes when its up its up but other times it might be down.

but its a T5 gallery tynamo version
Best regards 
and thanks... KEN 

Re: [ANNOUNCEMENT] Project Arras

2014-11-14 Thread françois facon
Nice!

Have you ever been in Arras? It's also a nice place
http://informationfrance.com/arras.php

Congrats!

François

2014-11-12 18:27 GMT+01:00 Felix Scheffer :

> Hi all,
>
> I'm pleased to announce the release of arras-components and arras-cms.
>
> https://github.com/fscheffer/arras/
>
> *Arras-components* is set of components for Tapestry 5.4 (based on beta
> 22).
> Currently the following components are part of the project:
> TabGroup, Dropdown, Lightbox, DataTable, Icon (fontawesome), RemoteSubmit,
> MediumEditor and Player (video and audio).
>
> Hopefully this list will grow further in the future.
>
> *Arras-cms* provides simple functionality to change the content of your
> site without actually having to redeploy it. It's using a WYSIWYG approach
> to change the content and is using tapestry-jpa to read and write content
> from and to a database.
>
> The jar files for both, arras-components and arras-cms, are available on
> Maven Central.
>
> If there are any questions or suggestions or feedback, feel free to contact
> me.
>
> Felix Scheffer
>


Re: GAE & 5.4-beta22 - access denied for "modifyThreadGroup"

2014-11-14 Thread Alex Kotchnev
Bummer, I just confirmed that the same error happens when deployed in
AppEngine. At first glance this looked similar to an issue that was fixed a
couple of years ago (https://issues.apache.org/jira/browse/TAP5-1616), but
this is definitely different. I do recall that in general in production one
might want to have a different exception page (than this default), yet I
wonder if there is anything that can still be done about this before 5.4
goes out (if it's considered important enough for a 5.4 release).

Cheers - Alex K

On Fri, Nov 14, 2014 at 6:08 PM, Alex Kotchnev  wrote:

> I took 5.4-beta-22 out for a spin yesterday and I ran into the following 
> exception when trying to run the AppEngine local dev server and there is an 
> error on the page and Tapestry attempts to display the exception page. I'm 
> not yet sure if this is going to work when deployed to AppEngine proper, but 
> I was wondering if there is a way to override either whether the exception 
> page attempts to do this.
>
>
> In the local environment, I can certainly start the local dev server with a 
> -Denable_all_permissions=true option that avoids the issue 
> in my local setup, so it's not a massive deal. Yet, this was certainly not 
> happening in 5.3.7 so I wonder what changed.
>
>
> Other than that, 5.4 just looks fantastic - I had been holding off on trying 
> it out , but now I can't wait this release to go out !
>
> Any ideas ?
>
>
> Cheers -
>
> org.apache.tapestry5.internal.services.RenderQueueException: Render queue 
> error in SetupRender[core/ExceptionReport:loop_0]: Failure reading parameter 
> 'source' of component core/ExceptionReport:loop_0: access denied 
> ("java.lang.RuntimePermission" "modifyThreadGroup") [at 
> classpath:org/apache/tapestry5/corelib/pages/ExceptionReport.tml, line 110]
>   at 
> org.apache.tapestry5.internal.services.RenderQueueImpl.run(RenderQueueImpl.java:87)
>   at 
> org.apache.tapestry5.internal.services.PageRenderQueueImpl.render(PageRenderQueueImpl.java:114)
>   at $PageRenderQueue_954065d89e49.render(Unknown Source)
>   at $PageRenderQueue_954065d89e48.render(Unknown Source)
>   at 
> org.apache.tapestry5.internal.services.MarkupRendererTerminator.renderMarkup(MarkupRendererTerminator.java:37)
>   at 
> org.apache.tapestry5.internal.services.PageNameMetaInjector.renderMarkup(PageNameMetaInjector.java:41)
>   at $MarkupRenderer_954065d89e4c.renderMarkup(Unknown Source)
>   at 
> org.apache.tapestry5.modules.TapestryModule$29.renderMarkup(TapestryModule.java:1810)
>   at $MarkupRenderer_954065d89e4c.renderMarkup(Unknown Source)
>   at 
> org.apache.tapestry5.modules.TapestryModule$28.renderMarkup(TapestryModule.java:1800)
>   at $MarkupRenderer_954065d89e4c.renderMarkup(Unknown Source)
>   at 
> org.apache.tapestry5.modules.TapestryModule$27.renderMarkup(TapestryModule.java:1784)
>   at $MarkupRenderer_954065d89e4c.renderMarkup(Unknown Source)
>   at 
> org.apache.tapestry5.modules.TapestryModule$26.renderMarkup(TapestryModule.java:1768)
>   at $MarkupRenderer_954065d89e4c.renderMarkup(Unknown Source)
>   at 
> org.apache.tapestry5.internal.services.javascript.AddBrowserCompatibilityStyles.renderMarkup(AddBrowserCompatibilityStyles.java:45)
>   at $MarkupRenderer_954065d89e4c.renderMarkup(Unknown Source)
>   at 
> org.apache.tapestry5.internal.services.javascript.ConfigureHTMLElementFilter.renderMarkup(ConfigureHTMLElementFilter.java:45)
>   at $MarkupRenderer_954065d89e4c.renderMarkup(Unknown Source)
>   at 
> org.apache.tapestry5.modules.JavaScriptModule$1.renderMarkup(JavaScriptModule.java:259)
>   at $MarkupRenderer_954065d89e4c.renderMarkup(Unknown Source)
>   at 
> org.apache.tapestry5.modules.TapestryModule$25.renderMarkup(TapestryModule.java:1751)
>   at $MarkupRenderer_954065d89e4c.renderMarkup(Unknown Source)
>   at $MarkupRenderer_954065d89e47.renderMarkup(Unknown Source)
>   at 
> org.apache.tapestry5.internal.services.PageMarkupRendererImpl.renderPageMarkup(PageMarkupRendererImpl.java:47)
>   at $PageMarkupRenderer_954065d89e45.renderPageMarkup(Unknown Source)
>   at 
> org.apache.tapestry5.internal.services.PageResponseRendererImpl.renderPageResponse(PageResponseRendererImpl.java:64)
>   at $PageResponseRenderer_954065d89dbf.renderPageResponse(Unknown Source)
>   at 
> org.apache.tapestry5.internal.services.DefaultRequestExceptionHandler.renderException(DefaultRequestExceptionHandler.java:261)
>   at 
> org.apache.tapestry5.internal.services.DefaultRequestExceptionHandler.handleRequestException(DefaultRequestExceptionHandler.java:144)
>   at $RequestExceptionHandler_954065d89d7c.handleRequestException(Unknown 
> Source)
>   at 
> org.apache.tapestry5.internal.services.RequestErrorFilter.service(RequestErrorFilter.java:42)
>   at $RequestHandler_954065d89d7e.service(Unknown Source)
>   at 
> org.apache.tapestry5.modules.TapestryModule$3.service(T

GAE & 5.4-beta22 - access denied for "modifyThreadGroup"

2014-11-14 Thread Alex Kotchnev
I took 5.4-beta-22 out for a spin yesterday and I ran into the
following exception when trying to run the AppEngine local dev server
and there is an error on the page and Tapestry attempts to display the
exception page. I'm not yet sure if this is going to work when
deployed to AppEngine proper, but I was wondering if there is a way to
override either whether the exception page attempts to do this.


In the local environment, I can certainly start the local dev server
with a -Denable_all_permissions=true option that
avoids the issue in my local setup, so it's not a massive deal. Yet,
this was certainly not happening in 5.3.7 so I wonder what changed.


Other than that, 5.4 just looks fantastic - I had been holding off on
trying it out , but now I can't wait this release to go out !

Any ideas ?


Cheers -

org.apache.tapestry5.internal.services.RenderQueueException: Render
queue error in SetupRender[core/ExceptionReport:loop_0]: Failure
reading parameter 'source' of component core/ExceptionReport:loop_0:
access denied ("java.lang.RuntimePermission" "modifyThreadGroup") [at
classpath:org/apache/tapestry5/corelib/pages/ExceptionReport.tml, line
110]
at 
org.apache.tapestry5.internal.services.RenderQueueImpl.run(RenderQueueImpl.java:87)
at 
org.apache.tapestry5.internal.services.PageRenderQueueImpl.render(PageRenderQueueImpl.java:114)
at $PageRenderQueue_954065d89e49.render(Unknown Source)
at $PageRenderQueue_954065d89e48.render(Unknown Source)
at 
org.apache.tapestry5.internal.services.MarkupRendererTerminator.renderMarkup(MarkupRendererTerminator.java:37)
at 
org.apache.tapestry5.internal.services.PageNameMetaInjector.renderMarkup(PageNameMetaInjector.java:41)
at $MarkupRenderer_954065d89e4c.renderMarkup(Unknown Source)
at 
org.apache.tapestry5.modules.TapestryModule$29.renderMarkup(TapestryModule.java:1810)
at $MarkupRenderer_954065d89e4c.renderMarkup(Unknown Source)
at 
org.apache.tapestry5.modules.TapestryModule$28.renderMarkup(TapestryModule.java:1800)
at $MarkupRenderer_954065d89e4c.renderMarkup(Unknown Source)
at 
org.apache.tapestry5.modules.TapestryModule$27.renderMarkup(TapestryModule.java:1784)
at $MarkupRenderer_954065d89e4c.renderMarkup(Unknown Source)
at 
org.apache.tapestry5.modules.TapestryModule$26.renderMarkup(TapestryModule.java:1768)
at $MarkupRenderer_954065d89e4c.renderMarkup(Unknown Source)
at 
org.apache.tapestry5.internal.services.javascript.AddBrowserCompatibilityStyles.renderMarkup(AddBrowserCompatibilityStyles.java:45)
at $MarkupRenderer_954065d89e4c.renderMarkup(Unknown Source)
at 
org.apache.tapestry5.internal.services.javascript.ConfigureHTMLElementFilter.renderMarkup(ConfigureHTMLElementFilter.java:45)
at $MarkupRenderer_954065d89e4c.renderMarkup(Unknown Source)
at 
org.apache.tapestry5.modules.JavaScriptModule$1.renderMarkup(JavaScriptModule.java:259)
at $MarkupRenderer_954065d89e4c.renderMarkup(Unknown Source)
at 
org.apache.tapestry5.modules.TapestryModule$25.renderMarkup(TapestryModule.java:1751)
at $MarkupRenderer_954065d89e4c.renderMarkup(Unknown Source)
at $MarkupRenderer_954065d89e47.renderMarkup(Unknown Source)
at 
org.apache.tapestry5.internal.services.PageMarkupRendererImpl.renderPageMarkup(PageMarkupRendererImpl.java:47)
at $PageMarkupRenderer_954065d89e45.renderPageMarkup(Unknown Source)
at 
org.apache.tapestry5.internal.services.PageResponseRendererImpl.renderPageResponse(PageResponseRendererImpl.java:64)
at $PageResponseRenderer_954065d89dbf.renderPageResponse(Unknown Source)
at 
org.apache.tapestry5.internal.services.DefaultRequestExceptionHandler.renderException(DefaultRequestExceptionHandler.java:261)
at 
org.apache.tapestry5.internal.services.DefaultRequestExceptionHandler.handleRequestException(DefaultRequestExceptionHandler.java:144)
at $RequestExceptionHandler_954065d89d7c.handleRequestException(Unknown 
Source)
at 
org.apache.tapestry5.internal.services.RequestErrorFilter.service(RequestErrorFilter.java:42)
at $RequestHandler_954065d89d7e.service(Unknown Source)
at 
org.apache.tapestry5.modules.TapestryModule$3.service(TapestryModule.java:854)
at $RequestHandler_954065d89d7e.service(Unknown Source)
at 
org.apache.tapestry5.modules.TapestryModule$2.service(TapestryModule.java:844)
at $RequestHandler_954065d89d7e.service(Unknown Source)
at 
org.apache.tapestry5.internal.services.StaticFilesFilter.service(StaticFilesFilter.java:89)
at $RequestHandler_954065d89d7e.service(Unknown Source)
at 
org.apache.tapestry5.internal.services.CheckForUpdatesFilter$2.invoke(CheckForUpdatesFilter.java:105)
at 
org.apache.tapestry5.internal.services.CheckForUpdatesFilter$2.invoke(CheckForUpdatesFilter.java:95)
at 
org.apache.tapestry5.ioc.inter

Re: [ANNOUNCEMENT] Project Arras

2014-11-14 Thread Charlouze
haha ! I didn't try that.

Clever :)

2014-11-14 22:30 GMT+01:00 Andreas Ernst :

> Am 14.11.14 um 17:43 schrieb Charlouze:
>
>> Is it possible to have admin login and password for the cms demo ?
>>
>> 2014-11-14 17:28 GMT+01:00 Felix Scheffer :
>>
>>  Demo for arras-components:
>>> https://arras-components.herokuapp.com/
>>>
>>> Demo for arras-cms (should reset every 24h)
>>> http://arras-cms.herokuapp.com/
>>>
>>
> Just click login.
>
> --
> ae | Andreas Ernst | IT Spektrum
> Postfach 5, 65612 Beselich
> Schupbacher Str. 32, 65614 Beselich, Germany
> Tel: +49-6484-91002 Fax: +49-6484-91003
> a...@ae-online.de | www.ae-online.de
> www.tachyon-online.de
>
> -
> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
> For additional commands, e-mail: users-h...@tapestry.apache.org
>
>


Re: [ANNOUNCEMENT] Project Arras

2014-11-14 Thread Andreas Ernst

Am 14.11.14 um 17:43 schrieb Charlouze:

Is it possible to have admin login and password for the cms demo ?

2014-11-14 17:28 GMT+01:00 Felix Scheffer :


Demo for arras-components:
https://arras-components.herokuapp.com/

Demo for arras-cms (should reset every 24h)
http://arras-cms.herokuapp.com/


Just click login.

--
ae | Andreas Ernst | IT Spektrum
Postfach 5, 65612 Beselich
Schupbacher Str. 32, 65614 Beselich, Germany
Tel: +49-6484-91002 Fax: +49-6484-91003
a...@ae-online.de | www.ae-online.de
www.tachyon-online.de

-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org



Re: session invalidate in tapestry

2014-11-14 Thread Thiago H de Paula Figueiredo
On Fri, 14 Nov 2014 18:15:12 -0200, Ivano Luberti   
wrote:



Oh God!
Yes , I messed up with interfaces: too much time using PHP


Hehehe. Actually, even without PHP messing up with your brain, it's easy  
to mistake one of the interfaces for the other . . .



Thanks Thiago


:D


Il 14/11/2014 20:47, Thiago H de Paula Figueiredo ha scritto:

On Fri, 14 Nov 2014 15:27:51 -0200, Ivano Luberti
 wrote:


So B is created in the first page but not bound to the session while
some way is visible across pages
While A is created at server start-up (why?) but is not visible in
the page.
If from web.xml  I remove


it.archicoop.met.obliterazione.beans.User




If you declare your User class like this, for the listening itself,
the servlet container will create a single User instance and invoke
its methods. This is completely unrelated to Tapestry's @SessionState.
Why are you doing that? Using the same class for this listener *and*
as an @SessionState field makes no sense at all, at least at first.

Shouldn't your User class implement HttpSessionBindingListener instead?






--
Thiago H. de Paula Figueiredo
Tapestry, Java and Hibernate consultant and developer
http://machina.com.br

-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org



Re: session invalidate in tapestry

2014-11-14 Thread Ivano Luberti
Oh God!
Yes , I messed up with interfaces: too much time using PHP

Thanks Thiago
 
Il 14/11/2014 20:47, Thiago H de Paula Figueiredo ha scritto:
> On Fri, 14 Nov 2014 15:27:51 -0200, Ivano Luberti
>  wrote:
>
>> So B is created in the first page but not bound to the session while
>> some way is visible across pages
>> While A is created at server start-up (why?) but is not visible in
>> the page.
>> If from web.xml  I remove
>>
>> 
>> it.archicoop.met.obliterazione.beans.User
>>
>> 
>
> If you declare your User class like this, for the listening itself,
> the servlet container will create a single User instance and invoke
> its methods. This is completely unrelated to Tapestry's @SessionState.
> Why are you doing that? Using the same class for this listener *and*
> as an @SessionState field makes no sense at all, at least at first.
>
> Shouldn't your User class implement HttpSessionBindingListener instead?
>

-- 
==
dott. Ivano Mario Luberti
Archimede Informatica societa' cooperativa a r. l.
Sede Operativa
Via Gereschi 36 - 56126- Pisa
tel.: +39-050- 580959
tel/fax: +39-050-9711344
web: www.archicoop.it
==


-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org



Re: session invalidate in tapestry

2014-11-14 Thread Thiago H de Paula Figueiredo
On Fri, 14 Nov 2014 15:27:51 -0200, Ivano Luberti   
wrote:



So B is created in the first page but not bound to the session while
some way is visible across pages
While A is created at server start-up (why?) but is not visible in the  
page.

If from web.xml  I remove


it.archicoop.met.obliterazione.beans.User



If you declare your User class like this, for the listening itself, the  
servlet container will create a single User instance and invoke its  
methods. This is completely unrelated to Tapestry's @SessionState. Why are  
you doing that? Using the same class for this listener *and* as an  
@SessionState field makes no sense at all, at least at first.


Shouldn't your User class implement HttpSessionBindingListener instead?

--
Thiago H. de Paula Figueiredo
Tapestry, Java and Hibernate consultant and developer
http://machina.com.br

-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org



Re: Stacktrace when on Tomcat server

2014-11-14 Thread Daniel Jue
Yes, I'm guessing it's something malformed in your page template.

On Fri, Nov 14, 2014 at 2:03 PM, Andreas Ernst  wrote:

> Am 14.11.14 um 13:44 schrieb Nathan Quirynen:
>
>> Maybe this helps... it's not much more than what I originally sent, but
>> there is no more...
>> This is all I see in the tomcat logs:
>>
>> [ERROR] ioc.Registry java.lang.ArrayIndexOutOfBoundsException
>> [ERROR] ioc.Registry Operations trace:
>> [ERROR] ioc.Registry [ 1] Constructing instance of page class
>> com.example.pages.Index
>> [ERROR] ioc.Registry [ 2] Creating ComponentAssembler for
>> com.example.pages.Index
>> [ERROR] ioc.Registry [ 3] Parsing component template
>> classpath:com/example/pages/Index.tml
>>
>
> Show your Index.tml
>
> --
> ae | Andreas Ernst | IT Spektrum
> Postfach 5, 65612 Beselich
> Schupbacher Str. 32, 65614 Beselich, Germany
> Tel: +49-6484-91002 Fax: +49-6484-91003
> a...@ae-online.de | www.ae-online.de
> www.tachyon-online.de
>
>
> -
> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
> For additional commands, e-mail: users-h...@tapestry.apache.org
>
>


Re: Stacktrace when on Tomcat server

2014-11-14 Thread Andreas Ernst

Am 14.11.14 um 13:44 schrieb Nathan Quirynen:

Maybe this helps... it's not much more than what I originally sent, but
there is no more...
This is all I see in the tomcat logs:

[ERROR] ioc.Registry java.lang.ArrayIndexOutOfBoundsException
[ERROR] ioc.Registry Operations trace:
[ERROR] ioc.Registry [ 1] Constructing instance of page class
com.example.pages.Index
[ERROR] ioc.Registry [ 2] Creating ComponentAssembler for
com.example.pages.Index
[ERROR] ioc.Registry [ 3] Parsing component template
classpath:com/example/pages/Index.tml


Show your Index.tml

--
ae | Andreas Ernst | IT Spektrum
Postfach 5, 65612 Beselich
Schupbacher Str. 32, 65614 Beselich, Germany
Tel: +49-6484-91002 Fax: +49-6484-91003
a...@ae-online.de | www.ae-online.de
www.tachyon-online.de

-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org



Re: session invalidate in tapestry

2014-11-14 Thread Ivano Luberti


Il 14/11/2014 13:13, Thiago H de Paula Figueiredo ha scritto:
> On Fri, 14 Nov 2014 09:25:47 -0200, Ivano Luberti
>  wrote:
>
>> Hi
>
> Hi!
>
>> When I call the Index page in the browser  onPrepare is called
>
> What's your onPrepare() method? You didn't post it here. By the way,
> you could print a stack trace inside the User constructor to know
> exactly which method is instantiating it.
>

Here is the code: is not onPrepare but setupRender , sorry, I had
changed it from onPrepare but the result has not changed, anyway


@Log
public void setupRender(){
   
   
try {
   
Loginform lf=
user.getWsclient().getLoginForm(requestGlobal.getHTTPServletRequest().getRemoteAddr());
   
monumenti=lf.getMonumenti();
   
postazioni=lf.getPostazioni();
   
idMonumentoSelezionato=lf.getIdMonumentoSelezionato();
   
   
user.setIp(requestGlobal.getHTTPServletRequest().getRemoteAddr());
   
} catch (Exception e) {
   
logger.debug(e.getMessage());
}

   
}


Here are the stack traces produced by the constuctor calls and
sessionCreated and session destroyed methods
You can see that

1) an instance A is created when tomcat starts up

2) instance A is bounded to the session when first page is visited

3) when first page is visited also instance B is created but not bound
to any session

4) on logout instance A id unbound from session

5) on redirection to Index instance B is discarded and instance C is
created but not attached to the session

So B is created in the first page but not bound to the session while
some way is visible across pages
While A is created at server start-up (why?) but is not visible in the page.
If from web.xml  I remove


   
it.archicoop.met.obliterazione.beans.User


of course A is not created anymore but neither are called sessionCreated
and sessionDestroy
While B keep on behaving as described

When I start the application an instance is created and printing a stack
trace produces:


I'm it.archicoop.met.obliterazione.beans.User@4e1a70b8 and I'm created here:
it.archicoop.met.obliterazione.beans.User,,34
sun.reflect.NativeConstructorAccessorImpl,newInstance0,-2
sun.reflect.NativeConstructorAccessorImpl,newInstance,39
sun.reflect.DelegatingConstructorAccessorImpl,newInstance,27
java.lang.reflect.Constructor,newInstance,513
java.lang.Class,newInstance0,357
java.lang.Class,newInstance,310
org.apache.catalina.core.StandardContext,listenerStart,4150
org.apache.catalina.core.StandardContext,start,4705
org.apache.catalina.core.ContainerBase,start,1057
org.apache.catalina.core.StandardHost,start,840
org.apache.catalina.core.ContainerBase,start,1057
org.apache.catalina.core.StandardEngine,start,463
org.apache.catalina.core.StandardService,start,525
org.apache.catalina.core.StandardServer,start,754
org.apache.catalina.startup.Catalina,start,595
sun.reflect.NativeMethodAccessorImpl,invoke0,-2
sun.reflect.NativeMethodAccessorImpl,invoke,39
sun.reflect.DelegatingMethodAccessorImpl,invoke,25
java.lang.reflect.Method,invoke,597
org.apache.catalina.startup.Bootstrap,start,289
org.apache.catalina.startup.Bootstrap,main,414



When I load the Index Page, first is invoked sessionCreated()


[DEBUG] pages.Index [ENTER] setupRender()
I'm bounded and I'm: it.archicoop.met.obliterazione.beans.User@4e1a70b8
in session 4CEC6E6D283C89FAEBCBEFF0D578E0DE
it.archicoop.met.obliterazione.beans.User,sessionCreated,104
org.apache.catalina.session.StandardSession,tellNew,392
org.apache.catalina.session.StandardSession,setId,363
org.apache.catalina.session.StandardSession,setId,345
org.apache.catalina.session.ManagerBase,createSession,906
org.apache.catalina.session.StandardManager,createSession,292
org.apache.catalina.connector.Request,doGetSession,2448
org.apache.catalina.connector.Request,getSession,2157
org.apache.catalina.connector.RequestFacade,getSession,833
$HttpServletRequest_18d69c7688d1,getSession,-1
$HttpServletRequest_18d69c7688cf,getSession,-1
org.apache.tapestry5.internal.services.TapestrySessionFactoryImpl,getSession,44
$TapestrySessionFactory_18d69c7688cc,getSession,-1
org.apache.tapestry5.internal.services.RequestImpl,getSession,115
$Request_18d69c7688f3,getSession,-1
$Request_18d69c7688bb,getSession,-1
org.apache.tapestry5.internal.services.SessionApplicationStatePersistenceStrategy,getSession,38
org.apache.tapestry5.internal.services.SessionApplicationStatePersistenceStrategy,getOrCreate,49
org.apache.tapestry5.internal.services.SessionApplicationStatePersistenceStrategy,get,44
$ApplicationStatePersistenceStrategy_18d69c768994,get,-1
org.apache.tapestry5.internal.services.ApplicationStateManagerImpl$ApplicationStateAdapter,getOrCreate,50
org.apache.tapestry5.internal.services.ApplicationStateManagerImpl,get,133
$ApplicationStateManager_18d69c7688fa,get,-1
org.apache.tapestry5.internal.transform.ApplicationStateWorker$1,get,75
it.archicoop.met.

Re: [ANNOUNCEMENT] Project Arras

2014-11-14 Thread Charlouze
Is it possible to have admin login and password for the cms demo ?

2014-11-14 17:28 GMT+01:00 Felix Scheffer :

> Demo for arras-components:
> https://arras-components.herokuapp.com/
>
> Demo for arras-cms (should reset every 24h)
> http://arras-cms.herokuapp.com/
>
>
> Felix
>
>
> 2014-11-13 14:48 GMT+01:00 Nathan Quirynen :
>
>>  Looks nice (looking at the code)!
>>
>> Are there online demos running to show everything?
>>
>> Congratz on the work ;)
>>
>> Nathan
>>
>> On 13/11/14 14:43, George Christman wrote:
>>
>> Excellent, congrats!
>>
>> On Wed, Nov 12, 2014 at 1:44 PM, Kalle Korhonen  
>> 
>> wrote:
>>
>>
>>  Looks nice, congrats!
>>
>> Kalle
>>
>> On Wed, Nov 12, 2014 at 9:27 AM, Felix Scheffer  
>> 
>> wrote:
>>
>>
>>  Hi all,
>>
>> I'm pleased to announce the release of arras-components and arras-cms.
>> https://github.com/fscheffer/arras/
>>
>> *Arras-components* is set of components for Tapestry 5.4 (based on beta
>> 22).
>> Currently the following components are part of the project:
>> TabGroup, Dropdown, Lightbox, DataTable, Icon (fontawesome),
>>
>>  RemoteSubmit,
>>
>>  MediumEditor and Player (video and audio).
>>
>> Hopefully this list will grow further in the future.
>>
>> *Arras-cms* provides simple functionality to change the content of your
>> site without actually having to redeploy it. It's using a WYSIWYG
>>
>>  approach
>>
>>  to change the content and is using tapestry-jpa to read and write content
>> from and to a database.
>>
>> The jar files for both, arras-components and arras-cms, are available on
>> Maven Central.
>>
>> If there are any questions or suggestions or feedback, feel free to
>>
>>  contact
>>
>>  me.
>>
>> Felix Scheffer
>>
>>
>>
>>
>> --
>>
>>
>> Een klare kijk op aanvullende pensioenen
>>
>> *Nathan Quirynen*
>> 03 340 04 60 | 0494 28 45 15
>> nat...@pensionarchitects.be
>>
>> Follow us on Web  | Twitter
>>  | LinkedIn
>>  | RSS
>>  | YouTube
>> 
>>
>>
>


Re: Tapestry Event Bubbling

2014-11-14 Thread Thiago H de Paula Figueiredo
On Fri, 14 Nov 2014 12:26:30 -0200, Robson Pires   
wrote:



Hi guys,


Hi! (Bão? :))



I am handling an event in a page A which was bubbling from a component B:

ComponentB.java

componentResources.triggerEvent(BULK_ACTION_SELECTED, new Object[] {
selectedAction, keys}, null);

PageA.java

 void onBulkActionSelectedFromresourceSearchResults(String context,
  long[] keys) throws IOException {

response.sendRedirect(getPageURL(linkSource, "resource/group",  
keys));


  }


You have absolutely no reason to redirect using Response.sendRedirect().  
Just return the Link directly and Tapestry will take care of the redirect  
for you:


  Object onBulkActionSelectedFromresourceSearchResults(String context,
   long[] keys) throws IOException {

 return getPageURL(linkSource, "resource/group", keys));

  }

More details here: http://tapestry.apache.org/page-navigation.html. It's  
more common, but equally correct, to @InjectPage the target page, set the  
values you want on it, then return it, supposing the target page class has  
an onPassivate() method.



As you can see I am trying to redirect to another page, is there any
problem in using redirect inside of an event bubbled up for a component ,


Absolutely not. This is 100% valid.


because in my case the page is not submitting.


What do you mean by "submitting"? Redirecting?

Have you checked whether your event handler method has actually been  
invoked?


--
Thiago H. de Paula Figueiredo
Tapestry, Java and Hibernate consultant and developer
http://machina.com.br

-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org



Re: [ANNOUNCEMENT] Project Arras

2014-11-14 Thread Felix Scheffer
Demo for arras-components:
https://arras-components.herokuapp.com/

Demo for arras-cms (should reset every 24h)
http://arras-cms.herokuapp.com/


Felix


2014-11-13 14:48 GMT+01:00 Nathan Quirynen :

>  Looks nice (looking at the code)!
>
> Are there online demos running to show everything?
>
> Congratz on the work ;)
>
> Nathan
>
> On 13/11/14 14:43, George Christman wrote:
>
> Excellent, congrats!
>
> On Wed, Nov 12, 2014 at 1:44 PM, Kalle Korhonen  
> 
> wrote:
>
>
>  Looks nice, congrats!
>
> Kalle
>
> On Wed, Nov 12, 2014 at 9:27 AM, Felix Scheffer  
> 
> wrote:
>
>
>  Hi all,
>
> I'm pleased to announce the release of arras-components and arras-cms.
> https://github.com/fscheffer/arras/
>
> *Arras-components* is set of components for Tapestry 5.4 (based on beta
> 22).
> Currently the following components are part of the project:
> TabGroup, Dropdown, Lightbox, DataTable, Icon (fontawesome),
>
>  RemoteSubmit,
>
>  MediumEditor and Player (video and audio).
>
> Hopefully this list will grow further in the future.
>
> *Arras-cms* provides simple functionality to change the content of your
> site without actually having to redeploy it. It's using a WYSIWYG
>
>  approach
>
>  to change the content and is using tapestry-jpa to read and write content
> from and to a database.
>
> The jar files for both, arras-components and arras-cms, are available on
> Maven Central.
>
> If there are any questions or suggestions or feedback, feel free to
>
>  contact
>
>  me.
>
> Felix Scheffer
>
>
>
>
> --
>
>
> Een klare kijk op aanvullende pensioenen
>
> *Nathan Quirynen*
> 03 340 04 60 | 0494 28 45 15
> nat...@pensionarchitects.be
>
> Follow us on Web  | Twitter
>  | LinkedIn
>  | RSS
>  | YouTube
> 
>
>


Re: Minify JS / CSS in production

2014-11-14 Thread Kalle Korhonen
Update the version of the offending library, but perhaps not that easy.
Googling the exception gives you these potential matches:
http://stackoverflow.com/questions/25808115/google-contacts-java-lang-nosuchmethoderror-com-google-common-collect-immutab
http://stackoverflow.com/questions/16475015/nosuchmethoderror-google-common-immutableset-copyof

Kalle


On Fri, Nov 14, 2014 at 6:10 AM, Thiago H de Paula Figueiredo <
thiag...@gmail.com> wrote:

> On Fri, 14 Nov 2014 11:26:54 -0200, George Christman <
> gchrist...@cardaddy.com> wrote:
>
>  So I tried this out last night and ended up with this beautiful exception.
>> Any ideas?
>>
>> HTTP Status 500 - java.lang.NoSuchMethodError:
>> com.google.common.collect.ImmutableSet.of(Ljava/lang/
>> Object;Ljava/lang/Object;Ljava/lang/Object;Ljava/lang/
>> Object;Ljava/lang/Object;Ljava/lang/Object;[Ljava/lang/
>> Object;)Lcom/google/common/collect/ImmutableSet;
>>
>
> This is a Guava dependency version mismatch, not directly related to
> Tapestry. If you're using Maven, use dependency:tree or the Eclipse pom.xml
> editor to know what's happening.
>
>
> --
> Thiago H. de Paula Figueiredo
> Tapestry, Java and Hibernate consultant and developer
> http://machina.com.br
>
> -
> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
> For additional commands, e-mail: users-h...@tapestry.apache.org
>
>


Tapestry Event Bubbling

2014-11-14 Thread Robson Pires
Hi guys,

I am handling an event in a page A which was bubbling from a component B:

ComponentB.java

componentResources.triggerEvent(BULK_ACTION_SELECTED, new Object[] {
selectedAction, keys}, null);

PageA.java

 void onBulkActionSelectedFromresourceSearchResults(String context,
  long[] keys) throws IOException {

response.sendRedirect(getPageURL(linkSource, "resource/group", keys));

  }

...

public String getPageURL(PageRenderLinkSource linkSource, String page,
  long[] context) {

Link link = linkSource.createPageRenderLinkWithContext(page, context);
return link.toAbsoluteURI();
  }

As you can see I am trying to redirect to another page, is there any
problem in using redirect inside of an event bubbled up for a component ,
because in my case the page is not submitting.


Re: Minify JS / CSS in production

2014-11-14 Thread Thiago H de Paula Figueiredo
On Fri, 14 Nov 2014 11:26:54 -0200, George Christman  
 wrote:


So I tried this out last night and ended up with this beautiful  
exception.

Any ideas?

HTTP Status 500 - java.lang.NoSuchMethodError:
com.google.common.collect.ImmutableSet.of(Ljava/lang/Object;Ljava/lang/Object;Ljava/lang/Object;Ljava/lang/Object;Ljava/lang/Object;Ljava/lang/Object;[Ljava/lang/Object;)Lcom/google/common/collect/ImmutableSet;


This is a Guava dependency version mismatch, not directly related to  
Tapestry. If you're using Maven, use dependency:tree or the Eclipse  
pom.xml editor to know what's happening.


--
Thiago H. de Paula Figueiredo
Tapestry, Java and Hibernate consultant and developer
http://machina.com.br

-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org



Re: Action Handler not being called component

2014-11-14 Thread Thiago H de Paula Figueiredo
On Fri, 14 Nov 2014 11:07:13 -0200, nhhockeyplayer nashua  
 wrote:



@Component(id = "itemsPerPageSelect", parameters =
{ "value=itemsPerPage", "clientId=itemsPerPageSelect" })
private Select itemsPerPageSelect;


For the valueChanged event from Select to be triggered, you need to use  
the zone parameter (of Select).


--
Thiago H. de Paula Figueiredo
Tapestry, Java and Hibernate consultant and developer
http://machina.com.br

-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org



Re: Minify JS / CSS in production

2014-11-14 Thread George Christman
So I tried this out last night and ended up with this beautiful exception.
Any ideas?

HTTP Status 500 - java.lang.NoSuchMethodError:
com.google.common.collect.ImmutableSet.of(Ljava/lang/Object;Ljava/lang/Object;Ljava/lang/Object;Ljava/lang/Object;Ljava/lang/Object;Ljava/lang/Object;[Ljava/lang/Object;)Lcom/google/common/collect/ImmutableSet;
--

*type* Exception report

*message* *java.lang.NoSuchMethodError:
com.google.common.collect.ImmutableSet.of(Ljava/lang/Object;Ljava/lang/Object;Ljava/lang/Object;Ljava/lang/Object;Ljava/lang/Object;Ljava/lang/Object;[Ljava/lang/Object;)Lcom/google/common/collect/ImmutableSet;*

*description* *The server encountered an internal error that prevented it
from fulfilling this request.*

*exception*

org.apache.shiro.subject.ExecutionException:
java.lang.NoSuchMethodError:
com.google.common.collect.ImmutableSet.of(Ljava/lang/Object;Ljava/lang/Object;Ljava/lang/Object;Ljava/lang/Object;Ljava/lang/Object;Ljava/lang/Object;[Ljava/lang/Object;)Lcom/google/common/collect/ImmutableSet;

org.apache.shiro.subject.support.DelegatingSubject.execute(DelegatingSubject.java:385)

org.tynamo.security.services.impl.SecurityConfiguration.service(SecurityConfiguration.java:54)
$HttpServletRequestFilter_10bf3e22901.service(Unknown Source)
$HttpServletRequestHandler_10bf3e22904.service(Unknown Source)

org.apache.tapestry5.upload.internal.services.MultipartServletRequestFilter.service(MultipartServletRequestFilter.java:45)
$HttpServletRequestHandler_10bf3e22904.service(Unknown Source)

org.apache.tapestry5.internal.gzip.GZipFilter.service(GZipFilter.java:59)
$HttpServletRequestHandler_10bf3e22904.service(Unknown Source)

com.cardaddy.auto.services.photo.impl.AjaxUploadServletRequestFilter.service(AjaxUploadServletRequestFilter.java:29)
$HttpServletRequestHandler_10bf3e22904.service(Unknown Source)

org.apache.tapestry5.internal.services.IgnoredPathsFilter.service(IgnoredPathsFilter.java:62)
$HttpServletRequestFilter_10bf3e228fd.service(Unknown Source)
$HttpServletRequestHandler_10bf3e22904.service(Unknown Source)

org.apache.tapestry5.modules.TapestryModule$1.service(TapestryModule.java:804)
$HttpServletRequestHandler_10bf3e22904.service(Unknown Source)
$HttpServletRequestHandler_10bf3e228fb.service(Unknown Source)
org.apache.tapestry5.TapestryFilter.doFilter(TapestryFilter.java:166)



On Thu, Nov 13, 2014 at 4:14 PM, Thiago H de Paula Figueiredo <
thiag...@gmail.com> wrote:

> On Thu, 13 Nov 2014 17:28:10 -0200, Kalle Korhonen <
> kalle.o.korho...@gmail.com> wrote:
>
>  It's tapestry-webresources (
>> http://repo1.maven.org/maven2/org/apache/tapestry/tapestry-webresources/
>> ).
>>
>
> Ouch, I copied that from http://tapestry.apache.org/assets.html. Gotta
> fix that. Good catch, Kalle!
>
>
> --
> Thiago H. de Paula Figueiredo
> Tapestry, Java and Hibernate consultant and developer
> http://machina.com.br
>
> -
> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
> For additional commands, e-mail: users-h...@tapestry.apache.org
>
>


-- 
George Christman
CEO
www.CarDaddy.com
P.O. Box 735
Johnstown, New York


RE: Action Handler not being called component

2014-11-14 Thread nhhockeyplayer nashua
Apologies...

I listed the wrong java code handler

here it is

@Component(id = "itemsPerPageSelect", parameters =
{ "value=itemsPerPage", "clientId=itemsPerPageSelect" })
private Select itemsPerPageSelect;

@OnEvent(value = EventConstants.VALUE_CHANGED, component = 
"itemsPerPageSelect")
public void onActionFromItemsPerPageSelect(Integer value)
{
logger.debug("In onValueChangedItemsPerPageSelect : ");

if (itemsPerPage < tableColumns)
{
tableColumns = itemsPerPage;
} else
{
/**
 * Use case, items is larger than columns, need to back cursor off
 * if in endzone
 */
int i = cursor + itemsPerPage;
while (i > (collection.size() - Math.min(collection.size(), 
itemsPerPage + tableColumns)))
{
i--;
}
cursor = (i);
}
// return homePage;
}



Best regards 
and thanks... KEN 

Action Handler not being called component

2014-11-14 Thread nhhockeyplayer nashua
Hi Folks,

Can anyone explain this stack trace ?

I am implementing a select component within my template.


Items Per Page




and here is my handler
@Component(id = "tableColumnsSelect", parameters =
{ "value=tableColumns", "clientId=tableColumnsSelect" })
private Select tableColumnsSelect;

@OnEvent(value = EventConstants.VALUE_CHANGED, component = 
"tableColumnsSelect")
public Object onActionFromTableColumnsSelect()
{
logger.info("In tableColumnsChangeListener : ");
onActionFromItemsPerPageSelect(itemsPerPage);
return homePage;
}

I cannot get eclipse to hit my breakpoint and this stack trace results

I am basing my premise on the notion that components have parameters and pages 
have properties.

This is a GalleryWidget I designed and handler is failing.

Am happy to share this component after. Its a nice one... my handlers are in 
hiccup right now.

Thanks


- cut here -

HTTP ERROR 500
Problem accessing /psi/home.galleryform/player. Reason:

org.apache.tapestry5.ioc.internal.OperationException: Error invoking 
constructor public 
org.apache.tapestry5.internal.services.ClientPersistentFieldStorageImpl(org.apache.tapestry5.services.Request,org.apache.tapestry5.services.ClientDataEncoder,org.apache.tapestry5.services.SessionPersistedObjectAnalyzer):
 java.lang.NullPointerExceptionCaused 
by:org.apache.shiro.subject.ExecutionException: 
org.apache.tapestry5.ioc.internal.OperationException: Error invoking 
constructor public 
org.apache.tapestry5.internal.services.ClientPersistentFieldStorageImpl(org.apache.tapestry5.services.Request,org.apache.tapestry5.services.ClientDataEncoder,org.apache.tapestry5.services.SessionPersistedObjectAnalyzer):
 java.lang.NullPointerException
at 
org.apache.shiro.subject.support.DelegatingSubject.execute(DelegatingSubject.java:385)
at 
org.tynamo.security.services.impl.SecurityConfiguration.service(SecurityConfiguration.java:54)
at $HttpServletRequestFilter_29b933e9b867.service(Unknown Source)
  

Re: Stacktrace when on Tomcat server

2014-11-14 Thread Nathan Quirynen
Maybe this helps... it's not much more than what I originally sent, but
there is no more...
This is all I see in the tomcat logs:

[ERROR] ioc.Registry java.lang.ArrayIndexOutOfBoundsException
[ERROR] ioc.Registry Operations trace:
[ERROR] ioc.Registry [ 1] Constructing instance of page class
com.example.pages.Index
[ERROR] ioc.Registry [ 2] Creating ComponentAssembler for
com.example.pages.Index
[ERROR] ioc.Registry [ 3] Parsing component template
classpath:com/example/pages/Index.tml
[ERROR] TapestryModule.RequestExceptionHandler Processing of request
failed with uncaught exception:
org.apache.tapestry5.ioc.internal.OperationException
org.apache.tapestry5.ioc.internal.OperationException
at
org.apache.tapestry5.ioc.internal.OperationTrackerImpl.logAndRethrow(OperationTrackerImpl.java:121)
at
org.apache.tapestry5.ioc.internal.OperationTrackerImpl.invoke(OperationTrackerImpl.java:88)
at
org.apache.tapestry5.ioc.internal.PerThreadOperationTracker.invoke(PerThreadOperationTracker.java:87)
at
org.apache.tapestry5.ioc.internal.RegistryImpl.invoke(RegistryImpl.java:1124)
at
org.apache.tapestry5.internal.services.TemplateParserImpl.parseTemplate(TemplateParserImpl.java:57)
at $TemplateParser_160e7709e302da.parseTemplate(Unknown Source)
at
org.apache.tapestry5.internal.services.ComponentTemplateSourceImpl.parseTemplate(ComponentTemplateSourceImpl.java:175)
at
org.apache.tapestry5.internal.services.ComponentTemplateSourceImpl.getTemplate(ComponentTemplateSourceImpl.java:147)
at $ComponentTemplateSource_160e7709e302d9.getTemplate(Unknown
Source)
at
org.apache.tapestry5.internal.pageload.PageLoaderImpl$4.invoke(PageLoaderImpl.java:229)
at
org.apache.tapestry5.internal.pageload.PageLoaderImpl$4.invoke(PageLoaderImpl.java:222)
at
org.apache.tapestry5.ioc.internal.OperationTrackerImpl.invoke(OperationTrackerImpl.java:74)
at
org.apache.tapestry5.ioc.internal.PerThreadOperationTracker.invoke(PerThreadOperationTracker.java:87)
at
org.apache.tapestry5.ioc.internal.RegistryImpl.invoke(RegistryImpl.java:1124)
at
org.apache.tapestry5.internal.pageload.PageLoaderImpl.createAssembler(PageLoaderImpl.java:221)
at
org.apache.tapestry5.internal.pageload.PageLoaderImpl.getAssembler(PageLoaderImpl.java:211)
at
org.apache.tapestry5.internal.pageload.PageLoaderImpl$3.invoke(PageLoaderImpl.java:183)
at
org.apache.tapestry5.internal.pageload.PageLoaderImpl$3.invoke(PageLoaderImpl.java:178)
at
org.apache.tapestry5.ioc.internal.OperationTrackerImpl.invoke(OperationTrackerImpl.java:74)
at
org.apache.tapestry5.ioc.internal.PerThreadOperationTracker.invoke(PerThreadOperationTracker.java:87)
at
org.apache.tapestry5.ioc.internal.RegistryImpl.invoke(RegistryImpl.java:1124)
at
org.apache.tapestry5.internal.pageload.PageLoaderImpl.loadPage(PageLoaderImpl.java:177)
at $PageLoader_160e7709e302c6.loadPage(Unknown Source)
at
org.apache.tapestry5.internal.services.PageSourceImpl.getPage(PageSourceImpl.java:104)
at $PageSource_160e7709e302c3.getPage(Unknown Source)
at
org.apache.tapestry5.internal.services.NonPoolingRequestPageCacheImpl.get(NonPoolingRequestPageCacheImpl.java:82)
at $RequestPageCache_160e7709e302c2.get(Unknown Source)
at $RequestPageCache_160e7709e302bd.get(Unknown Source)
at
org.apache.tapestry5.internal.services.PageRenderRequestHandlerImpl.handle(PageRenderRequestHandlerImpl.java:55)
at
org.apache.tapestry5.services.TapestryModule$38.handle(TapestryModule.java:)
at $PageRenderRequestHandler_160e7709e302c1.handle(Unknown Source)
at $PageRenderRequestHandler_160e7709e302bb.handle(Unknown Source)
at
org.apache.tapestry5.internal.services.ComponentRequestHandlerTerminator.handlePageRender(ComponentRequestHandlerTerminator.java:48)
at
org.apache.tapestry5.services.InitializeActivePageName.handlePageRender(InitializeActivePageName.java:47)
at
$ComponentRequestHandler_160e7709e302bc.handlePageRender(Unknown Source)
at
$ComponentRequestHandler_160e7709e3028f.handlePageRender(Unknown Source)
at
org.apache.tapestry5.internal.services.PageRenderDispatcher.dispatch(PageRenderDispatcher.java:45)
at $Dispatcher_160e7709e30292.dispatch(Unknown Source)
at $Dispatcher_160e7709e3028c.dispatch(Unknown Source)
at
org.apache.tapestry5.services.TapestryModule$RequestHandlerTerminator.service(TapestryModule.java:302)
at
org.apache.tapestry5.internal.services.RequestErrorFilter.service(RequestErrorFilter.java:26)
at $RequestHandler_160e7709e3028d.service(Unknown Source)
at
org.apache.tapestry5.services.TapestryModule$3.service(TapestryModule.java:902)
at $RequestHandler_160e7709e3028d.service(Unknown Source)
at
org.apache.tapestry5.services.TapestryModule$2.service(TapestryModule.java:892)
at 

Re: Stacktrace when on Tomcat server

2014-11-14 Thread Chris Mylonas
Put logback in your pom.XML
Presuming u use 5.4
On 14/11/2014 11:36 pm, "Nathan Quirynen" 
wrote:

> The problem is that's all I see in the logs of tomcat... Maybe my
> logging is not setup correctly?
>
> On 14/11/14 12:21, Thiago H de Paula Figueiredo wrote:
> > On Fri, 14 Nov 2014 07:48:34 -0200, Nathan Quirynen
> >  wrote:
> >
> >> Hi,
> >
> > Hi!
> >
> >> *root cause*
> >>
> >> java.lang.ArrayIndexOutOfBoundsException
> >
> > You left out exactly where the real information in this stack trace is
> > . . .
> >
>
>
> -
> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
> For additional commands, e-mail: users-h...@tapestry.apache.org
>
>


Re: Stacktrace when on Tomcat server

2014-11-14 Thread Nathan Quirynen
The problem is that's all I see in the logs of tomcat... Maybe my
logging is not setup correctly?

On 14/11/14 12:21, Thiago H de Paula Figueiredo wrote:
> On Fri, 14 Nov 2014 07:48:34 -0200, Nathan Quirynen
>  wrote:
>
>> Hi,
>
> Hi!
>
>> *root cause*
>>
>> java.lang.ArrayIndexOutOfBoundsException
>
> You left out exactly where the real information in this stack trace is
> . . .
>


-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org



Re: session invalidate in tapestry

2014-11-14 Thread Thiago H de Paula Figueiredo
On Fri, 14 Nov 2014 09:25:47 -0200, Ivano Luberti   
wrote:



Hi


Hi!


When I call the Index page in the browser  onPrepare is called


What's your onPrepare() method? You didn't post it here. By the way, you  
could print a stack trace inside the User constructor to know exactly  
which method is instantiating it.



So it seems that the field of type User is not persisted between
different pages.


Yes, it is. But I guess you're using the same field for @SessionState  
(storing authentication information) and login form. If yes, that's  
exactly what's messing up with your code.



As I sadi before: there are other ways to centrailize session boundign
and unbounding


Not in Tapestry itself.


but I wanted to know if in Tapestry I can use the
HTTPSessionListener inteface for object persisted in the session


Yes, you can use it.

--
Thiago H. de Paula Figueiredo
Tapestry, Java and Hibernate consultant and developer
http://machina.com.br

-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org



Re: session invalidate in tapestry

2014-11-14 Thread Ivano Luberti
Hi

Il 13/11/2014 15:24, Thiago H de Paula Figueiredo ha scritto:
> On Thu, 13 Nov 2014 12:16:03 -0200, Ivano Luberti
>  wrote:
>
>> Hi all, I have a question about session handling in Tapestry5.
>> I have a
>>
>> @SessionState
>> protected User user;
>
> Shouldn't it be @SessionState(create = false) so user isn't
> instantiated automatically and is null until you set the field?
>

well in my case authentication and authorization is verified using
information that are popultaed only after login, so from my point of
view I had not advantage.
Anyway I followed you  on this.
But nothing changed.

>>
>> that works as expected
>>
>> I wanted to perform some cleanup when calling a logout link: the action
>> link listener is made as this:
>>
>> public Object onActionFromLink() {
>>requestGlobals.getHTTPServletRequest().getSession().invalidate();
>>return Index.class;
>>}
>
> You can (and should) @Inject Request. There's absolutely no reason in
> the last 5 years to use RequestGlobals to get the request object. You
> can also @Inject HttpServletRequest and HttpServletResponse directly
> if needed.
>
> @Inject
> private Request request;
>
> ...
>
> Session session = request.getSession(false);
> if (session != null) {
> session.invalidate();
> }
>

I have done also this but to no avail.
So I try to explain what happens.

I have the following class

package it.archicoop.met.obliterazione.base;

import it.archicoop.met.obliterazione.beans.User;

import org.apache.tapestry5.annotations.Property;
import org.apache.tapestry5.annotations.SessionState;
import org.apache.tapestry5.ioc.annotations.Inject;

public class BasePage implements IPage{
   
@SessionState(create=false)
@Property
protected User user;


User is defined as this:

package it.archicoop.met.obliterazione.beans;

import javax.servlet.http.HttpSessionEvent;
import javax.servlet.http.HttpSessionListener;


public class User implements HttpSessionListener {
   
public  User() {
}
   
public void sessionCreated(HttpSessionEvent se) {
   
System.out.println("session started "+se.getSession().getId());
   
}


public void sessionDestroyed(HttpSessionEvent se) {

System.out.println("session ended "+se.getSession().getId());

}
}


Then I have

package it.archicoop.met.obliterazione.pages;
public class Index extends BasePage
{

and

package it.archicoop.met.obliterazione.pages;
public class BarCode extends BasePage
{


Logout link is implemented using  a component

package it.archicoop.met.obliterazione.components;

import it.archicoop.met.obliterazione.pages.Index;

import org.apache.tapestry5.ioc.annotations.Inject;
import org.apache.tapestry5.services.Request;
import org.apache.tapestry5.services.Session;


public class Logout
{
@Inject
private Request request;
   
public Object onActionFromLink() {
   
 
Session session = request.getSession(false);
if (session != null) {
session.invalidate();
}
   
return Index.class;
 
}
   
}


public Object onActionFromLink() {
   
 
Session session = request.getSession(false);
if (session != null) {
session.invalidate();
}
   
   
return Index.class;
 
}


What happens


startup app

User constuctor called

it.archicoop.met.obliterazione.beans.User@2a801059

When I call the Index page in the browser  onPrepare is called

session created

it.archicoop.met.obliterazione.beans.User@2a801059

user field is null so constructor is called explicitly:

it.archicoop.met.obliterazione.beans.User@50862b70

login form submission

it.archicoop.met.obliterazione.beans.User@50862b70

Logout link

BarCode is the container of the Logout component

and user is null (WTF!?)

after session.invalidate is called

Session Destroyed

it.archicoop.met.obliterazione.beans.User@2a801059

Since I redirect to Index, again

onPrepare

user is initially

it.archicoop.met.obliterazione.beans.User@50862b70

then

user null

then recreated

it.archicoop.met.obliterazione.beans.User@4c057cc6

SessionCreated called

it.archicoop.met.obliterazione.beans.User@2a801059


So it seems that the field of type User is not persisted between
different pages.
And there is no relation between the user instances managed by the
servlet containt via SessionListener interface and the one in the pages

As I sadi before: there are other ways to centrailize session boundign
and unbounding but I wanted to know if in Tapestry I can use the
HTTPSessionListener inteface for object persisted in the session




-- 
==
dott. Ivano Mario Luberti
Archimede Informatica societa' cooperativa a r. l.
Sede Operativa
Via Gereschi 36 - 56126- Pisa
tel.: +39-050- 580959
tel/fax: +39-050-9711344
web: www.archicoop.it
==



---

Re: Stacktrace when on Tomcat server

2014-11-14 Thread Thiago H de Paula Figueiredo
On Fri, 14 Nov 2014 07:48:34 -0200, Nathan Quirynen  
 wrote:



Hi,


Hi!


*root cause*

java.lang.ArrayIndexOutOfBoundsException


You left out exactly where the real information in this stack trace is . .  
.


--
Thiago H. de Paula Figueiredo
Tapestry, Java and Hibernate consultant and developer
http://machina.com.br

-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org



Stacktrace when on Tomcat server

2014-11-14 Thread Nathan Quirynen
Hi,

A simple application with 1 page containing some static text won't work
on Tomcat for some reason and I can't figure out why.
It works when running in Eclipse with maven jetty plugin, but when I
deploy it on my Tomcat server I get the stacktrace below when I access
the page.

Anyone an idea what I could have done wrong; never had this before and
can't find the problem.

org.apache.tapestry5.ioc.internal.OperationException

org.apache.tapestry5.ioc.internal.OperationTrackerImpl.logAndRethrow(OperationTrackerImpl.java:121)

org.apache.tapestry5.ioc.internal.OperationTrackerImpl.invoke(OperationTrackerImpl.java:88)

org.apache.tapestry5.ioc.internal.PerThreadOperationTracker.invoke(PerThreadOperationTracker.java:87)

org.apache.tapestry5.ioc.internal.RegistryImpl.invoke(RegistryImpl.java:1124)

org.apache.tapestry5.internal.services.TemplateParserImpl.parseTemplate(TemplateParserImpl.java:57)
$TemplateParser_160e7709e302da.parseTemplate(Unknown Source)

org.apache.tapestry5.internal.services.ComponentTemplateSourceImpl.parseTemplate(ComponentTemplateSourceImpl.java:175)

org.apache.tapestry5.internal.services.ComponentTemplateSourceImpl.getTemplate(ComponentTemplateSourceImpl.java:147)
$ComponentTemplateSource_160e7709e302d9.getTemplate(Unknown Source)

org.apache.tapestry5.internal.pageload.PageLoaderImpl$4.invoke(PageLoaderImpl.java:229)

org.apache.tapestry5.internal.pageload.PageLoaderImpl$4.invoke(PageLoaderImpl.java:222)

org.apache.tapestry5.ioc.internal.OperationTrackerImpl.invoke(OperationTrackerImpl.java:74)

org.apache.tapestry5.ioc.internal.PerThreadOperationTracker.invoke(PerThreadOperationTracker.java:87)

org.apache.tapestry5.ioc.internal.RegistryImpl.invoke(RegistryImpl.java:1124)

org.apache.tapestry5.internal.pageload.PageLoaderImpl.createAssembler(PageLoaderImpl.java:221)

org.apache.tapestry5.internal.pageload.PageLoaderImpl.getAssembler(PageLoaderImpl.java:211)

org.apache.tapestry5.internal.pageload.PageLoaderImpl$3.invoke(PageLoaderImpl.java:183)

org.apache.tapestry5.internal.pageload.PageLoaderImpl$3.invoke(PageLoaderImpl.java:178)

org.apache.tapestry5.ioc.internal.OperationTrackerImpl.invoke(OperationTrackerImpl.java:74)

org.apache.tapestry5.ioc.internal.PerThreadOperationTracker.invoke(PerThreadOperationTracker.java:87)

org.apache.tapestry5.ioc.internal.RegistryImpl.invoke(RegistryImpl.java:1124)

org.apache.tapestry5.internal.pageload.PageLoaderImpl.loadPage(PageLoaderImpl.java:177)
$PageLoader_160e7709e302c6.loadPage(Unknown Source)

org.apache.tapestry5.internal.services.PageSourceImpl.getPage(PageSourceImpl.java:104)
$PageSource_160e7709e302c3.getPage(Unknown Source)

org.apache.tapestry5.internal.services.NonPoolingRequestPageCacheImpl.get(NonPoolingRequestPageCacheImpl.java:82)
$RequestPageCache_160e7709e302c2.get(Unknown Source)
$RequestPageCache_160e7709e302bd.get(Unknown Source)

org.apache.tapestry5.internal.services.DefaultRequestExceptionHandler.handleRequestException(DefaultRequestExceptionHandler.java:77)
$RequestExceptionHandler_160e7709e3028b.handleRequestException(Unknown 
Source)

org.apache.tapestry5.internal.services.RequestErrorFilter.service(RequestErrorFilter.java:42)
$RequestHandler_160e7709e3028d.service(Unknown Source)

org.apache.tapestry5.services.TapestryModule$3.service(TapestryModule.java:902)
$RequestHandler_160e7709e3028d.service(Unknown Source)

org.apache.tapestry5.services.TapestryModule$2.service(TapestryModule.java:892)
$RequestHandler_160e7709e3028d.service(Unknown Source)

org.apache.tapestry5.internal.services.StaticFilesFilter.service(StaticFilesFilter.java:90)
$RequestHandler_160e7709e3028d.service(Unknown Source)
$RequestHandler_160e7709e30282.service(Unknown Source)

org.apache.tapestry5.services.TapestryModule$HttpServletRequestHandlerTerminator.service(TapestryModule.java:253)

org.apache.tapestry5.internal.gzip.GZipFilter.service(GZipFilter.java:53)
$HttpServletRequestHandler_160e7709e30284.service(Unknown Source)

org.apache.tapestry5.internal.services.IgnoredPathsFilter.service(IgnoredPathsFilter.java:62)
$HttpServletRequestFilter_160e7709e30280.service(Unknown Source)
$HttpServletRequestHandler_160e7709e30284.service(Unknown Source)

org.apache.tapestry5.services.TapestryModule$1.service(TapestryModule.java:852)
$HttpServletRequestHandler_160e7709e30284.service(Unknown Source)
$HttpServletRequestHandler_160e7709e3027f.service(Unknown Source)
org.apache.tapestry5.TapestryFilter.doFilter(TapestryFilter.java:171)

*root cause*

java.lang.ArrayIndexOutOfBoundsException




Re: [5.4] javascript - simplify the new paradigm please

2014-11-14 Thread Paul Stanton

Thanks Geoff,

Im going to have to play around with this and see what is happening 
under the covers.


I'll get back...

cheers, p.

On 14/11/2014 3:06 PM, Geoff Callender wrote:

I accidentally left out the object's state vars. Added below.

On 14 Nov 2014, at 10:00 am, Geoff Callender 
 wrote:


Yep, that's a valid case, and it's one I have to put into JumpStart.

Here's the way I handle it. I'd like to see what others do.

Have the module keep an array of objects, identified by a key. The server-side 
can provide the key when initialising and later whenever invoking a function. 
The component can use any value for the key as long as it is unique on the page 
and as long as it is repeatable (eg. the component might need to derive the key 
from its container or context).

Here's an example snippet from a module I called "activate-selectables". More 
than one component on my page uses this module. A typical case is when I have a list of 
items on the page, and a button that pops up a modal with another list of items. When an 
item is selected, the server-side has to set the currentElement on the correct list.

define([ "jquery", "t5/core/console" ], function($, console) {

var selectablesContainers = [];

SelectablesContainer = function() {

var containerId = "", selectableClass = "", selectedClass = "", 
currentClass = "";


init = function(params) {
containerId = params.containerId;
selectableClass = params.selectableCssClass;
selectedClass = params.selectedCssClass;
// etc
var $container = $('#' + containerId);
$container.on('click', '.' + selectableClass, 
doSelected);
};

doSelected = function() {
var $clicked = $(this);
$clicked.addClass(selectedClass);
$clicked.trigger('selected');
};

setCurrentElement = function(selectableName) {
// etc.
};

return {
init : init,
setCurrentElement : setCurrentElement
};
};

init = function(key, params) {
var selectablesContainer = new SelectablesContainer();
selectablesContainer.init(params);
selectablesContainers[key] = selectablesContainer;
};

setCurrentElement = function(key, currentElementName) {
var selectablesContainer = selectablesContainers[key];
selectablesContainer.setCurrentElement(currentElementName);
};

return {
init : init,
setCurrentElement : setCurrentElement
};

});

And some corresponding java:

void afterRender() {
JSONObject params = new JSONObject();
params.put("containerId", thingsDiv.getClientId());
//etc

javaScriptSupport.require("activate-selectables").invoke("init").with(SELECTABLES_KEY,
 params);
}

Object onThingSelected(Integer thingId) {
this.thingId = thingId;
// etc

ajaxResponseRenderer.addCallback(makeScriptToSetCurrentElement(selectableName));
// etc
}

private JavaScriptCallback makeScriptToSetCurrentElement(final String 
selectableName) {

return new JavaScriptCallback() {

public void run(JavaScriptSupport javaScriptSupport) {

javaScriptSupport.require("activate-selectables").invoke("setCurrentElement")
.with(SELECTABLES_KEY, 
selectableName);
}

};

}

In this case I get away with SELECTABLES_KEY being a constant but, as I said 
above, sometimes you have to derive its value from its container or event 
context.

Geoff

On 14 Nov 2014, at 9:18 am, Paul Stanton  wrote:


Oh,

so calling
require("modal").invoke("activate")

and then later
require("modal").invoke("deactivate")

.. both re-construct a seperate "modal" js object and then call one of the two 
published functions...

what if you have two different modals? what if they are init-ed differently:

java:afterRender() {
require("modal").invoke("init").with("message 1");
require("modal").invoke("init").with("message 2");
}

and then later
java:onSomeEvent() {
require("modal").invoke("activate");
}

this flow would essentially construct the modal module instance 3 times, and the "activate" 
wouldn't know about "message 1" or "message 2".

Therefore, how would I re-aquire a handle to a specific module instance later 
on? for eg:

java:onSomeEvent(){
// activate modal with "message 1"
require("modal").invoke("activate