Wicket and Jetty Persistent Sessions not playing together

2008-12-05 Thread Joel Halbert
Hi, Has anyone had issues when using wicket with Jetty and persistent sessions? Specifically when the server is restarted sessions are intialised before servlets are ready, this causes an exception when wicket deserialises the current page which was in session since the WicketApplication is not

Re: using annotation @AuthorizeInstantiation

2008-12-05 Thread Adriano dos Santos Fernandes
Bruno Borges escreveu: Note that this is really type-safe, and these classes will never be instantiated. I don't think this has any value in this context. Where will the roles x user will be? On the database, certainly... So why declare dummy classes for them? If yon don't want to repeat

Re: IChainingModel

2008-12-05 Thread jWeekend
Jeremy, People will find your blog entry useful, but this issue is a bit more specific. AbstractPropertyModel _should_ implement IChainingModel, that's how you know it _should_ dig values out model objects which r themselves models. Now try this: public class TestPropertyModelsChainingImpl

Re: SpringOne America 2008 in Hollywood, FL

2008-12-05 Thread shetc
shetc wrote: A colleague and I will be attending the SpringOne America 2008 next week in Hollywood, FL. Will any fellow Wicketeers be there as well? Steve -- View this message in context: http://www.nabble.com/SpringOne-America-2008-in-Hollywood%2C-FL-tp20681833p20681833.html

Problem with Application getInitParameter()

2008-12-05 Thread Tauren Mills
Maybe I'm going nuts, but I can't figure out what is wrong. It seems so simple, but it isn't working. I call getInitParameter in my application twice. One time it returns a value, the other it gets a null. And the correct xml is there in web.xml. First, here is the pertinent application code

Re: SpringOne America 2008 in Hollywood, FL

2008-12-05 Thread Nino Saturnino Martinez Vazquez Wael
Hehe cool, I wonder if Martijn ever got around to post the picture he took of me, wearing my wicket merchandise. The Cap and T-shirt at his presentation :) shetc wrote: http://www.nabble.com/file/p20846846/spring.jpg Well, here I am at the SpringOne Conference, where the theme is Weapons

Re: using annotation @AuthorizeInstantiation

2008-12-05 Thread Casper Bang
Yeah, I asked about this last week or so when running into the same problem. I now also do it the class way, and although that does feel better than using strings, in my opinion it still isn't type safe. It gives no syntax lookup and people are free to write Object.class which will compile

Re: using annotation @AuthorizeInstantiation

2008-12-05 Thread Bruno Borges
Yes Adriano, that's what I said on my last reply. :-) So, the only way, for now, to have type-safety is using that Class-thing. I don't vote for this though. A simple class with String constants does de job quite well. :-D Cheers, Bruno Adriano dos Santos Fernandes wrote: Bruno Borges

Re: IChainingModel

2008-12-05 Thread jWeekend
... In my rush to get out I hit post instead of preview. Now I've come back and reviewed it here's a completed and *corrected* version, hopefully a bit clearer and precise. Excuse any confusion caused. Jeremy, AbstractPropertyModel _should_ implement IChainingModel; this tells us about its type

Re: IChainingModel

2008-12-05 Thread jWeekend
Igor, You're right. See my corrected reply to Jeremy; I was looking for property expressions being model-chaining aware. Regards - Cemal http://www.jWeekend.co.uk http://jWeekend.co.uk igor.vaynberg wrote: when you give propertymodel anoter imodel do you have to begin the expression with

Hourglass during Ajax

2008-12-05 Thread Anton Veretennikov
Hello Wicket users, I would like to know how to show some hourglass in a Wicket way during Ajax so user will not click something else. How to do this? Thank you - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional

Re: Hourglass during Ajax

2008-12-05 Thread Cristi Manole
take a look on viel in wicketstuff, if it's still available. i used it, it's nice and easy. On Fri, Dec 5, 2008 at 10:04 AM, Anton Veretennikov [EMAIL PROTECTED] wrote: Hello Wicket users, I would like to know how to show some hourglass in a Wicket way during Ajax so user will not click

Re: Hourglass during Ajax

2008-12-05 Thread jWeekend
Anton, See IndicatingAjaxLink (and other, similarly named components) and IndicatingAjaxButton. Regards - Cemal http://www.jWeekend.co.uk http://jWeekend.co.uk Anton Veretennikov wrote: Hello Wicket users, I would like to know how to show some hourglass in a Wicket way during Ajax so

Re: Hourglass during Ajax

2008-12-05 Thread Cristi Manole
[but if you need to _make sure_ the user doesn't click anything while the request is processing use the viel] On Fri, Dec 5, 2008 at 10:27 AM, jWeekend [EMAIL PROTECTED]wrote: Anton, See IndicatingAjaxLink (and other, similarly named components) and IndicatingAjaxButton. Regards - Cemal

Re: @SpringBean with page creation patterns

2008-12-05 Thread jWeekend
I assume the getCheese method in your code below is declared public static to keep the example simple and to the point; you wouldn't normally expect to get your cheeses from a Page class. If you're comfortable with your page being coupled to the DAO interface (without, for instance, a service

Re: Hourglass during Ajax

2008-12-05 Thread jWeekend
Cristi, Right, but it's non-trivial to use the veil for this - you'll need to http://javathoughts.capesugarbird.com/2008/03/ajax-button-with-overlay-div-and-wait.html do some work to get it to do just what you need. Also, iirc, veil does not address the IE6 problem with drop-downs being still

Re: @SpringBean with page creation patterns

2008-12-05 Thread quizzical
Thanks, that was exactly what I was looking for. -- View this message in context: http://www.nabble.com/%40SpringBean-with-page-creation-patterns-tp20845794p20854804.html Sent from the Wicket - User mailing list archive at Nabble.com.

Re: Hourglass during Ajax

2008-12-05 Thread Martin Makundi
Combine it nicely with generic busy indicator: http://cwiki.apache.org/WICKET/generic-busy-indicator-for-both-ajax-and-non-ajax-submits.html Just make the div pick the size from the screen and set it on top with cursor type wait. ** Martin 2008/12/5 Martijn Dashorst [EMAIL PROTECTED]: Why not

Re: Hourglass during Ajax

2008-12-05 Thread jWeekend
Martijn, That's nice and it would be ideal to do it with CSS; that is what I too wanted to do when I first thought about a modal busy indicator. But, IE6 is, surprise surprise, the problem - the drop-downs still show through. Do you know of a way to fix that? ModalWindow window seems to just put

Re: Hourglass during Ajax

2008-12-05 Thread Anton Veretennikov
Seems these methods are all acceptable, I'll try them all and choose which to use in which case. Thank you. On Fri, Dec 5, 2008 at 10:04 PM, Martijn Dashorst [EMAIL PROTECTED] wrote: This is just CSS hacking, I guess an iframe insertion is what is necessary which is the usual hack for this

Thread.sleep() for only one session

2008-12-05 Thread Anton Veretennikov
Hello all Wicket users. One more question today. I need to implement appearence of sleep if user (session, IP address) tries incorrect login many times. Thread.sleep() seems to stop all sessions at once. Any ideas? Thank you! -

Re: Thread.sleep() for only one session

2008-12-05 Thread Jeremy Thomerson
You definitely do NOT want to intentionally sleep a thread - that halts the request, and uses up your thread pool. You instead want the request to complete, but you don't want to allow them to continue trying. So, that being said, you could: 1 - add a value to their session like private long

Re: using annotation @AuthorizeInstantiation

2008-12-05 Thread Jeremy Thomerson
I'm not, because as was mentioned elsewhere on the thread, you almost always need to go back to some (or other - int) mechanism because in reality, permissions typically end up being: User has a Role (or multiple roles) Those Role objects have Permission objects User can also have Permission

Re: Wicket integration with good charts api

2008-12-05 Thread Ryan McKinley
I just started one with the implementation I have we can make it better, or perhaps add it to wicketstuff... http://cwiki.apache.org/WICKET/open-flash-chart-and-wicket.html On Nov 5, 2008, at 3:59 PM, Thies Edeling wrote: Maarten Bosteels wrote: I have a similar requirement and played

Re: Thread.sleep() for only one session

2008-12-05 Thread Maarten Bosteels
If you're trying to defend against a brute-force password guessing attack, you could add a captcha to your logon form after x failed login attempts from one IP address. Maarten On Fri, Dec 5, 2008 at 5:20 PM, Jeremy Thomerson [EMAIL PROTECTED]wrote: You definitely do NOT want to intentionally

Re: Wicket integration with good charts api

2008-12-05 Thread Maarten Bosteels
Oops, just started working on it :-) Will see if I can add somet more info to the wiki page. Maarten On Fri, Dec 5, 2008 at 5:57 PM, Ryan McKinley [EMAIL PROTECTED] wrote: I just started one with the implementation I have we can make it better, or perhaps add it to wicketstuff...

Re: Thread.sleep() for only one session

2008-12-05 Thread Anton Veretennikov
Thank you for valuable information! Tony. On Sat, Dec 6, 2008 at 12:36 AM, Maarten Bosteels [EMAIL PROTECTED] wrote: If you're trying to defend against a brute-force password guessing attack, you could add a captcha to your logon form after x failed login attempts from one IP address.

RE: Thread.sleep() for only one session

2008-12-05 Thread Bruno Cesar Borges
I'm totally against captcha. It's annoying for users and just one more obstacle for criminals - they will always find a way to break it. What I really suggest is: 1) use HTTPS (obviously) 2) require your users a strong password 3) if your user tries login in more than X times, disable his/her

Re: Thread.sleep() for only one session

2008-12-05 Thread James Carman
But, if you only show the captcha after so many failed logins, wouldn't that be okay? You let them try a few times and if they are still failing, you initiate the captcha. On Fri, Dec 5, 2008 at 12:48 PM, Bruno Cesar Borges [EMAIL PROTECTED] wrote: I'm totally against captcha. It's annoying

RE: Thread.sleep() for only one session

2008-12-05 Thread Bruno Cesar Borges
Indeed. -Original Message- From: James Carman [mailto:[EMAIL PROTECTED] Sent: Friday, December 05, 2008 3:52 PM To: users@wicket.apache.org Subject: Re: Thread.sleep() for only one session But, if you only show the captcha after so many failed logins, wouldn't that be okay? You let

Re: Thread.sleep() for only one session

2008-12-05 Thread James Carman
That's what Maarten was suggesting, I believe. I agree that captchas are no fun for your users, but if you don't turn them on all the time, I think they can be useful for blocking brute-force attacks. I would think that even with captcha turned on, if the login fails a number of times more that

Re: Wicket and Jetty Persistent Sessions not playing together

2008-12-05 Thread Igor Vaynberg
not sure if we can do much about this. on the one hand jetty is quirky because it initializes objects that belong to the webapp before actually initializing the webapp itself. on the other hand wicket is quirky because it stores things in session that depend on objects outside the session. try

Possible to retrieve previous page from PageMap

2008-12-05 Thread pixologe
Hi there, is there a way to retrieve the previous page from the PageMap? Or at least its class? I can see that it is in there (private), but as I see it the API does not seem to let me access it... or did I miss something? In our current case we would need to display a specific info only if

Re: Possible to retrieve previous page from PageMap

2008-12-05 Thread pixologe
For once, I can answer my own question. I just realized that I can cast the PageMap to SecondLevelCachePageMap, which lets me access lastPage. Don't know if this is the best solution, but it should work as long as I do not provide another PageMap myself. If there is a more elegant solution,

Re: Possible to retrieve previous page from PageMap

2008-12-05 Thread Jeremy Thomerson
Here's a post from Jon Locke about this: http://web.mac.com/jonathan.locke/iWeb/JonathanLocke/Blog/C68818AE-E983-4D7A-B6BF-E95CD886BFF2.html On Fri, Dec 5, 2008 at 1:40 PM, pixologe [EMAIL PROTECTED] wrote: Hi there, is there a way to retrieve the previous page from the PageMap? Or at least

Re: Adding jquery effects to paging navigator

2008-12-05 Thread Daniel Peters
Serkan Camurcuoglu wrote: just noticed I forgot to add the behavior to the link, but still the javascript does not show up.. I know your mail was some time ago, but I just had the same problem and found a solution. Maybe it helps somebody else in future... The problem is that the fadeOut()

Re: Problem with Application getInitParameter()

2008-12-05 Thread Nav Che
Maybe you want to try this : ((WebRequest)getRequestCycle().getRequest()).getHttpServletRequest().getServerName() //Naveen On Fri, Dec 5, 2008 at 6:58 AM, Tauren Mills [EMAIL PROTECTED] wrote: Maybe I'm going nuts, but I can't figure out what is wrong. It seems so simple, but it isn't

RE: Thread.sleep() for only one session

2008-12-05 Thread Hoover, William
If you need to do these kind things at least utilize java.util.concurrent.* class MyCallable implements CallableMyReturnObject { final public MyReturnObject call() { // calling the another thread; do something and return your object } } final ExecutorService es =

Re: Wicket integration with good charts api

2008-12-05 Thread Maarten Bosteels
Hello Ryan, I have just added some more code to the wiki page, and a working quickstart project. http://cwiki.apache.org/WICKET/open-flash-chart-and-wicket.html My OpenFlashChart implementation is almost exactly the same as yours. Only differences I found: * You use an *ofc4j.model.Chart* as

Re: Possible to retrieve previous page from PageMap

2008-12-05 Thread pixologe
Ah - I see, SLCPM is private :( Thanks for the link, this solution works fine :) Jeremy Thomerson-5 wrote: Here's a post from Jon Locke about this: http://web.mac.com/jonathan.locke/iWeb/JonathanLocke/Blog/C68818AE-E983-4D7A-B6BF-E95CD886BFF2.html On Fri, Dec 5, 2008 at 1:40 PM, pixologe

CheckGroupSelector not working at all in a Wizard

2008-12-05 Thread jchappelle
I have followed the example exactly(from what I can see) and when I click my Select All button nothing happens to the other buttons. Here is the code: This is in the constructor of a WizardStep: Form form = new Form(form) {

create clickable icons (serving as external links) - Sends server into a endless loop

2008-12-05 Thread Ed _
I am trying to create clickable icons that would link to an external page. I came across - http://cwiki.apache.org/WICKET/how-to-load-an-external-image.html - But the server just goes into an endless loop. pointers? Ed ExternalLink link = new ExternalLink(partnerLink, partnerLink);

Re: create clickable icons (serving as external links) - Sends server into a endless loop

2008-12-05 Thread Jeremy Thomerson
I don't see anything right away wrong with your code below. So, maybe a couple questions will help: Goes into an endless loop when? When it's rendering? When loading image? When clicking on link? Also - what HTML does your code below produce? -- Jeremy Thomerson

RE: create clickable icons (serving as external links) - Sends server into a endless loop

2008-12-05 Thread Ed _
The problem occers when it is rendering. The images / page render fine when the src is hardcoded in the html file. It also works when I use the web markupcontainer and manipulate the src attribute as shown below. ExternalLink link = new ExternalLink(partnerLink, partnerLink); final

Re: create clickable icons (serving as external links) - Sends server into a endless loop

2008-12-05 Thread Jeremy Thomerson
Help me out a little more... If it's truly while rendering (on the server), and enters an infinite loop - must be a stack overflow, in which case, send the stack trace. I think you mean that it's while rendering **in the browser**, for instance by requesting the page again and again, etc.. If

how to invoke javascript method after form validation?

2008-12-05 Thread novotny
Hi, I have markup like li class=noerrorEnter textinput type=text wicket:id=sometext/ And I'm using FeedbackPanel currently, but instead of showing all the errors at the top, we want to change class=noerror to class=error which seems easier to do in javascript. But how can I indicate to

CheckGroup model only has one element

2008-12-05 Thread jchappelle
I have a CheckGroup inside of a WizardStep panel. In the constructor I am giving it a PropertyModel like this: final CheckGroup group = new CheckGroup(group, new PropertyModel(RegistrationWizard.this, contacts)); My wizard class has a setContacts and a getContacts that take a Set and return a