Re: [Stripes-users] Memory Usage: Stripes Layout vs. Tiles
I've built and run the 1.5.x branch against my applications ( Currently on Stripes 1.5.3 ) running on Tomcat 5.5.27 & 6.0.26. I've run through a few tests and they appear to be working great. I haven't taken a look at the memory usage, but from the end user's perspective, all of our screens seem to be loading and functioning fine. Seth On Thu, May 13, 2010 at 12:23 PM, Ben Gunter wrote: > I just committed the changes to the 1.5.x branch. I'd like this to undergo > some serious testing so anybody who is able, please build from SVN and test > in your existing applications or test setups. I've done some basic tests and > have tested it in my application, and it works really well for me. Let me > know how it goes for you. Thanks! > > -Ben > > > On Wed, May 12, 2010 at 10:51 PM, Ben Gunter wrote: > >> Sorry to truncate your thorough response, but I just wanted to let anyone >> who is interested know that I think I have managed to make the layout tags >> stream output directly to the client instead of buffering it and then >> dumping the whole thing at once. This should eliminate the possibility of a >> memory leak. I will, of course, need people to test the new code. I'll apply >> it to the 1.5.x branch tomorrow and let everyone know when it's ready to >> test. >> >> -Ben >> >> On Wed, May 12, 2010 at 6:32 PM, Nikolaos Giannopoulos < >> nikol...@brightminds.org> wrote: >> >>> Richard (and Ben), >>> >>> Appears like a lot of good work has gone into trying to resolve / fix >>> this >>> >>> Thanks for the info. I hope my comments in-line can assist >>> >>> --Nikolaos >>> >>> >>> >> > > > -- > > > ___ > Stripes-users mailing list > Stripes-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/stripes-users > > -- ___ Stripes-users mailing list Stripes-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/stripes-users
Re: [Stripes-users] Seeking advice on StreamingResolution
I've run into the same issue myself - I have yet to implement any changes, but I was planning on building a process similar to this: I'd like to know if anyone else has any other ideas. 1) The user requests the PDF. 2) The request spawns off a new process to generate the PDF and saves it to a temporary folder ( or saves it into a database ). Another option would be to have the current request save a database record to some sort of "pending" report table. Then, a separate back end process would poll the table for reports to generate and save them off to a temp directory or table. 2a) In the meantime, the request immediately forwards the user a page which presents a "loading" screen. Using javascript the loading page would query the server every 5-10 seconds to see if the PDF has been generated. 3) Once the loading page has determined that the PDF has been generated, it is sent to the user. This could be extended to allow the user to navigate away from the loading page. A separate page which presents a list of reports and their current status could be built. Seth On Thu, Apr 22, 2010 at 10:13 AM, Aaron Stromas wrote: > Hello, > > I realise this is not Stripes question, really. I'm posting to this list in > hope that someone might have faced a similar situation and was able to find > a decent solution. So, here goes... > > I am using the StreamingResolution to fetch a PDF. Unfortunately, the PDF > is generated on the fly and can take seriously long time. I'd like to pop up > one of those javascript busy-wait windows, which would be taken down by the > page that loads if I were able to hook the onload event on that page. > Unfortunately, with the StreamingResolution I can't do that. The problem > needs to be tackled differently. Any suggestions? TIA > > -a > > -- > Aaron Stromas > > > > > -- > > ___ > Stripes-users mailing list > Stripes-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/stripes-users > > -- ___ Stripes-users mailing list Stripes-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/stripes-users
[Stripes-users] Stripes and Log4J Issue?
Could someone please provide an example of how to use Log4J from within a Stripes application? I have the following log4j.properties file on the class path: log4j.rootLogger=INFO, CONSOLE log4j.appender.CONSOLE=org.apache.log4j.ConsoleAppender log4j.appender.CONSOLE.layout=org.apache.log4j.PatternLayout log4j.appender.CONSOLE.layout.ConversionPattern=[%d{dd MMM HH:mm:ss}] [%p] %m%n In one of my ActionBeans, I'm attempting to write a log message using the following: Loggger loggger = Logger.getLogger( MyActionBean.class ); logger.info("This is a test"); In the console I'm getting the following log message: [09 Dec 2009 17:48:06] [INFO] [09 Dec 2009 17:48:06] [INFO] This is a test It appears my log message was caught by stripe's logging before being printed to the console? I'm stumped. Any advise would be appreciated. I've also noticed that if I call System.out.println("This is a test") from within the ActionBean I get the following output to the console: [09 Dec 2009 17:48:06] [INFO] This is a test I wouldn't have expected the println to be caught by log4j. Thanks -- Return on Information: Google Enterprise Search pays you back Get the facts. http://p.sf.net/sfu/google-dev2dev ___ Stripes-users mailing list Stripes-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/stripes-users
[Stripes-users] Stripes Book Example Issue
On page 317 there is an example of adding role checkboxes to a list of users. Next to each user, the JSP adds a "User" and "Administrator" checkbox where you can select roles for the user. Then, at the bottom of the screen, there's a submit button to update all of the user roles in the list. * UserListActionBean.java:* public class UserListActionBean extends BaseActionBean { private List users = userDao.read(); private List getUsers() { return users; } public List getRoles() { return roleDao.read(); } public Resolution save() { for( User user : users ) { userDao.save(user); } userDao.commit(); } } * user_list.jsp:* ... ... Now, the issue I have with this is what happens if the user list changes before the user presses submit? The indexes assigined in "users[${index}].roles" might no longer refer to the correct user. How would you go about actually building something like this? The best solution I can think of would be to define a "Map> userRolesMap" in the action bean. Then, in the table I would set the checkbox name to: "userRolesMap['${user.id}']" Finally, to update the roles when the user presses save, loop through the users, and check to see if the userRolesMap contains the user's id - if it does assign the user roles and update the user. Does anyone else have any better solutions to solve this? Thanks! -- ___ Stripes-users mailing list Stripes-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/stripes-users
[Stripes-users] Including action bean w/ jsp:inlcude issue
Example 3 below is having some unexpected output: The action bean test.MyActionBean contains a list of strings (List stringList) and when included on the page will display the list of strings. Example 1 ( This works correctly ) * EXAMPLE 1 OUTPUT: Value1 Value2 *** Example 2 ( This works correctly ) * EXAMPLE 2 OUTPUT: Value3 *** Example 3 ( This does not work as expected . ) * EXAMPLE 2 OUTPUT: Value3 Value2 *** It seems that the second call to the test.MyActionBean doesnt create a new instance - the values from the first call are still contained in the action bean. How do I make this so it either: a. Creates a new instance of the action bean at the second call in example 3? b. Empties the stringList List before populating w. the params passed in the second call in example 3? -- Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco, CA -OSBC tackles the biggest issue in open source: Open Sourcing the Enterprise -Strategies to boost innovation and cut costs with open source participation -Receive a $600 discount off the registration fee with the source code: SFAD http://p.sf.net/sfu/XcvMzF8H___ Stripes-users mailing list Stripes-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/stripes-users