|
Pentium Dual Core, 2GB RAM
Windows Seven STS-2.8.1-RELEASE JDK7 Grails 2.0RC1 Groovy-1.8 Grails development is very slow. Each time I create a domain/controller (either with the graphical wizard or by typing at the Grails shell) it takes half a minute to execute. Also, almost every change to groovy domain/controller files requires restarting the http server component , otherwise weird things happen, ie I don't see my changes or MissingProperty and other funny exception are thrown. I stop catalina with the red square button, then I run-app (green "play" button) and everything works as expected, but MINUTES are passed! Also, the Grails app is clearly slow in outputting HTML and feels very laggy. All I have is 2 domains/controllers and, in-memory database and automatic scaffolding This must be a problem with my stack, because I can't believe that developing with Grails is so painful |
|
Hi,
My best guess is probably JDK7. Cheers Chanwit On Wed, Jan 4, 2012 at 00:11, raffaele181188 <[hidden email]> wrote: > Pentium Dual Core, 2GB RAM > Windows Seven > STS-2.8.1-RELEASE > JDK7 > Grails 2.0RC1 > Groovy-1.8 > > Grails development is very slow. Each time I create a domain/controller > (either with the graphical wizard or by typing at the Grails shell) it takes > half a minute to execute. Also, almost every change to groovy > domain/controller files requires restarting the http server component , > otherwise weird things happen, ie I don't see my changes or MissingProperty > and other funny exception are thrown. I stop catalina with the red square > button, then I run-app (green "play" button) and everything works as > expected, but MINUTES are passed! Also, the Grails app is clearly slow in > outputting HTML and feels very laggy. All I have is 2 domains/controllers > and, in-memory database and automatic scaffolding > > This must be a problem with my stack, because I can't believe that > developing with Grails is so painful > > -- > View this message in context: http://grails.1312388.n4.nabble.com/Grails-development-is-really-slow-tp4257651p4257651.html > Sent from the Grails - user mailing list archive at Nabble.com. > > --------------------------------------------------------------------- > To unsubscribe from this list, please visit: > > http://xircles.codehaus.org/manage_email > > -- Chanwit Kaewkasi code.google.com/p/zkgrails twitter.com/chanwit --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email |
|
2GB memory could also be a problem....
Java app is really memory monster. On Tue, Jan 3, 2012 at 9:23 AM, Chanwit Kaewkasi <[hidden email]> wrote: Hi, |
|
In reply to this post by raffaele181188
Em 03-01-2012 15:11, raffaele181188 escreveu:
> Pentium Dual Core, 2GB RAM > Windows Seven > STS-2.8.1-RELEASE > JDK7 > Grails 2.0RC1 > Groovy-1.8 > > Grails development is very slow. Each time I create a domain/controller > (either with the graphical wizard or by typing at the Grails shell) it takes > half a minute to execute. Also, almost every change to groovy > domain/controller files requires restarting the http server component , > otherwise weird things happen, ie I don't see my changes or MissingProperty > and other funny exception are thrown. I stop catalina with the red square > button, then I run-app (green "play" button) and everything works as > expected, but MINUTES are passed! Also, the Grails app is clearly slow in > outputting HTML and feels very laggy. All I have is 2 domains/controllers > and, in-memory database and automatic scaffolding > > This must be a problem with my stack, because I can't believe that > developing with Grails is so painful Raffael, if you're new to Grails, I would suggest you to take a look at JRuby on Rails. You'll probably have a much better user experience with it. Grails is really painfully slow and can become very hard to debug in certain cases... But you should be using Grails 2 final anyway instead of Grails 2.0RC1. The Grails interactive shell should you help you too. If you insist on Grails, you should take some time to find out which plugin might be creating issues for you with regards to automatic reloading of your classes. It can take you a lot of time since Grails won't give you any hint about what is going on, but it certainly worths if you find the culprit. I've found recently issues with the mongodb plugin that was affecting the automatic reloading feature and didn't give me a single clue. I've also had issues due to using gVim with swap files enabled (default config) as well with using different package from the default one in a service. So, while it is very time consuming, I would advise you to start with a fresh Grails application and gradually copy your classes to this new application until you see issues with reloading. That way you'll be able to identify what is causing reloading issues for you. Yeah, I know, unfortunately I don't know a better way of debugging such issues. Let me know if you have some better tips for dealing with it. Good luck, Rodrigo. --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email |
|
thats it, throw the baby out with the bath water ....
On Tue, Jan 3, 2012 at 10:57 AM, Rodrigo Rosenfeld Rosas <[hidden email]> wrote: > Em 03-01-2012 15:11, raffaele181188 escreveu: > >> Pentium Dual Core, 2GB RAM >> Windows Seven >> STS-2.8.1-RELEASE >> JDK7 >> Grails 2.0RC1 >> Groovy-1.8 >> >> Grails development is very slow. Each time I create a domain/controller >> (either with the graphical wizard or by typing at the Grails shell) it >> takes >> half a minute to execute. Also, almost every change to groovy >> domain/controller files requires restarting the http server component , >> otherwise weird things happen, ie I don't see my changes or >> MissingProperty >> and other funny exception are thrown. I stop catalina with the red square >> button, then I run-app (green "play" button) and everything works as >> expected, but MINUTES are passed! Also, the Grails app is clearly slow in >> outputting HTML and feels very laggy. All I have is 2 domains/controllers >> and, in-memory database and automatic scaffolding >> >> This must be a problem with my stack, because I can't believe that >> developing with Grails is so painful > > > Raffael, if you're new to Grails, I would suggest you to take a look at > JRuby on Rails. You'll probably have a much better user experience with it. > > Grails is really painfully slow and can become very hard to debug in certain > cases... But you should be using Grails 2 final anyway instead of Grails > 2.0RC1. > > The Grails interactive shell should you help you too. If you insist on > Grails, you should take some time to find out which plugin might be creating > issues for you with regards to automatic reloading of your classes. > > It can take you a lot of time since Grails won't give you any hint about > what is going on, but it certainly worths if you find the culprit. I've > found recently issues with the mongodb plugin that was affecting the > automatic reloading feature and didn't give me a single clue. > > I've also had issues due to using gVim with swap files enabled (default > config) as well with using different package from the default one in a > service. > > So, while it is very time consuming, I would advise you to start with a > fresh Grails application and gradually copy your classes to this new > application until you see issues with reloading. That way you'll be able to > identify what is causing reloading issues for you. > > Yeah, I know, unfortunately I don't know a better way of debugging such > issues. Let me know if you have some better tips for dealing with it. > > Good luck, > > Rodrigo. > > > --------------------------------------------------------------------- > To unsubscribe from this list, please visit: > > http://xircles.codehaus.org/manage_email > > --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email |
|
In reply to this post by rosenfeld
Thanks all for the fast replies. I'll try to change JDK and Grails version, but I was looking for known issues :(
Rodrigo, big thanks for your suggestions. I looked at Rails, but Ruby is a very foreign language and it will take long to be proficient with it. On the other hand, Groovy syntax is very java-friendly, so for this project I prefer the latter. Anyway your mails confirm that the choppiness is not a general problem. I'll try Grails on the Ubuntu box and let you know
Raffaele
2012/1/3 rosenfeld [via Grails] <[hidden email]> Em 03-01-2012 15:11, raffaele181188 escreveu: |
|
In reply to this post by Jason Davis
2012/1/3 Jason Davis [via Grails] <[hidden email]>
thats it, throw the baby out with the bath water .... what do you mean? Raffaele |
|
In reply to this post by Jason Davis
Hi Jason, could you point me out what are the advantages of Grails over
Rails? I'd be curious to listen to your opinion. Em 03-01-2012 16:03, Jason Davis escreveu: > throw the baby out with the bath water --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email |
|
In reply to this post by raffaele181188
Maybe I'm misinterpreting, but it seems that you're not using the standard grails run-app command while developing. Why not? Are you rebuilding and cycling tomcat for every change?
Running STS + any grails app + any browser is going to be truly painful on 2GB of RAM. I strongly suggest getting more RAM or doing your coding in Notepad++ or something lightweight. You're probably living in swap space.
On Tue, Jan 3, 2012 at 11:11 AM, raffaele181188 <[hidden email]> wrote: Pentium Dual Core, 2GB RAM |
|
In reply to this post by raffaele181188
AFAIK, Windows 7 has problems running with 2GB of memory. I believe a minimum of 4GB is recommended. The Grails FAQ also lists JVM arguments with suggested heap settings: http://www.grails.org/FAQ
Hope this helps, Mark
On Tue, Jan 3, 2012 at 10:09 AM, raffaele181188 <[hidden email]> wrote: Thanks all for the fast replies. I'll try to change JDK and Grails version, but I was looking for known issues :( |
|
In reply to this post by raffaele181188
On Tue, Jan 3, 2012 at 11:11 AM, raffaele181188
<[hidden email]> wrote: > Pentium Dual Core, 2GB RAM > Windows Seven > STS-2.8.1-RELEASE > JDK7 > Grails 2.0RC1 > Groovy-1.8 > > Grails development is very slow. Each time I create a domain/controller > (either with the graphical wizard or by typing at the Grails shell) it takes > half a minute to execute. Are you talking about the time it takes to do something like create-controller? If so, something is definitely wrong. 30 seconds is way out of the window of what is expected. On my machine create-controller is a a sub-second operation from within the Grails 2.0 interactive console. jb -- Jeff Brown SpringSource http://www.springsource.com/ Autism Strikes 1 in 166 Find The Cause ~ Find The Cure http://www.autismspeaks.org/ --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email |
|
In reply to this post by raffaele181188
As someone else suggested, the 2gb of memory might be the issue. STS is eclipse-based, so a sizable chunk of memory will go to that before your app ever starts up. If you'd like to test the low memory theory, make sure STS is not even loaded into memory when you test running the grails app from a command line. If it performs any better, then it is likely a memory issue. You might also check your free disk space - if you are low in disk, then the system will perform poorly. Also see if you have any other background processes (such as a browser with a large number of tabs/windows open).
I have run grails apps on comparable hardware and the performance was better than you described so there should be a way to improve things. -terry Sent from my IBM Blue Gene/P Supercomputer. On Jan 3, 2012, at 12:11 PM, raffaele181188 <[hidden email]> wrote: > Pentium Dual Core, 2GB RAM > Windows Seven > STS-2.8.1-RELEASE > JDK7 > Grails 2.0RC1 > Groovy-1.8 > > Grails development is very slow. Each time I create a domain/controller > (either with the graphical wizard or by typing at the Grails shell) it takes > half a minute to execute. Also, almost every change to groovy > domain/controller files requires restarting the http server component , > otherwise weird things happen, ie I don't see my changes or MissingProperty > and other funny exception are thrown. I stop catalina with the red square > button, then I run-app (green "play" button) and everything works as > expected, but MINUTES are passed! Also, the Grails app is clearly slow in > outputting HTML and feels very laggy. All I have is 2 domains/controllers > and, in-memory database and automatic scaffolding > > This must be a problem with my stack, because I can't believe that > developing with Grails is so painful > > -- > View this message in context: http://grails.1312388.n4.nabble.com/Grails-development-is-really-slow-tp4257651p4257651.html > Sent from the Grails - user mailing list archive at Nabble.com. > > --------------------------------------------------------------------- > To unsubscribe from this list, please visit: > > http://xircles.codehaus.org/manage_email > > > --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email |
|
In reply to this post by raffaele181188
Raffaele,
>> Pentium Dual Core, 2GB RAM >> Windows Seven 2 GB is certainly not ideal, but it should be enough RAM to run Java.exe. Can you execute other Java programs without issues? >> STS-2.8.1-RELEASE Stick to the command line for now so you can narrow it down. Especially since you only have 2 GB of RAM. >> JDK7 Can you try JDK 6 from Oracle to rule out any potential issues with JDK 7? >> Grails 2.0RC1 Get the 2.0 Final version. >> Groovy-1.8 You don't need to install Groovy, it comes bundled with Grails. Thanks, Bobby |
|
In reply to this post by xmly
Gavin is both right and wrong.
You would be making you a favor by buying you some 8GB RAM and throwing away your 2GB in whatever environment you might decide to work with. RAM is very cheap nowadays that it pays off very quickly if you count your more efficiently used developer's hours. But Java apps doesn't really need to be memory monsters. It turns out that Grails specifically requires an absurd amount of memory for a good development environment where you'll want to reload your classes many times. There are lots of adjustments that can be done to the JVM. Using default settings in my environment, an IRB session using JRuby will take about 50MB, while a groovysh session will take 140MB. I usually set my GRAILS_OPTS to: -server -Xmx512M -XX:MaxPermSize=512m -Dfile.encoding=UTF-8 -Dserver.port=8081 Your app's memory requirements might be lower than mine. An empty JRuby on Rails application would require about 300MB with default settings in my environment. Em 03-01-2012 15:28, Gavin Yue escreveu: 2GB memory could also be a problem.... |
|
In reply to this post by rosenfeld
I'm saying this as a list subscriber (not as a SpringSource employee) but perhaps this list isn't the best place for yet another Grails/Rails comparison?
Burt On Tuesday, January 03, 2012 04:12:53 PM Rodrigo Rosenfeld Rosas wrote: > Hi Jason, could you point me out what are the advantages of Grails over > Rails? I'd be curious to listen to your opinion. > > Em 03-01-2012 16:03, Jason Davis escreveu: > > throw the baby out with the bath water --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email |
|
In reply to this post by bobbywarner
Tomorrow I'll do the tests and report the results - I'm at home now :)
But I have to say that 2GB *must be* enough to develop a webapp. It can't see my disk swapping, and the system is truly responsive: I can even fire up MS Word and editing a document while grails is running :) So there must be something wrong in the components. I have two more questions:
I noticed STS comes with Groovy, but what if I want to use a "system" Groovy compiler? (Bobby) What is the intended way to run-app within STS? I thought the "run as" button of STS was the only way :) but every time I click, it starts (?) a new Grails instance (???) - at least, this is what appears on the console (jstell)
Raffaele
2012/1/3 bobbywarner [via Grails] <[hidden email]> Raffaele, |
|
In reply to this post by Jeff Brown-3
Are you talking about the time it takes to do something like Yes. 30 seconds is unacceptable :) moreover, it seems that every change to domain/controller requires a restart of catalina and this is very strange. Without restarting, I get MissingPropertyExceptions and other weird things. I remark that my app is not a "real" app: I am only coding after a tutorial I am reading, and all I have is 2 domains and 2 controllers
|
|
In reply to this post by Terry Tompkins
2012/1/3 Terry Tompkins [via Grails] <[hidden email]>
As someone else suggested, the 2gb of memory might be the issue. STS is eclipse-based, so a sizable chunk of memory will go to that before your app ever starts up. If you'd like to test the low memory theory, make sure STS is not even loaded into memory when you test running the grails app from a command line. If it performs any better, then it is likely a memory issue. You might also check your free disk space - if you are low in disk, then the system will perform poorly. Also see if you have any other background processes (such as a browser with a large number of tabs/windows open). I'll do the tests ASAP, anyway 2GB are not so bad :) I can successfully and smoothly develop Android application with this configuration. Obviously one can't expect the speed of light from this machine, but 2GB are definetly 2GB :)
Raffaele |
|
In reply to this post by rosenfeld
Rodrigo, I believe you are wrong. I develop personal grails projects on an hp laptop with 2GB of RAM, Centrino Processor running Ubuntu + WindowMaker and have no issues. It performs just as well as it does on my workstation with 16GB of RAM + Core 2 vPro. I don't use any IDE on my laptop, because those slow me down. The suggestions by Gavin are really good and there is nothing wrong with grails' performance.
On Tue, Jan 3, 2012 at 12:37 PM, Rodrigo Rosenfeld Rosas <[hidden email]> wrote:
The Journey Is The Reward. |
|
In reply to this post by burtbeckwith
On Tue, Jan 3, 2012 at 12:38 PM, Burt Beckwith <[hidden email]> wrote: I'm saying this as a list subscriber (not as a SpringSource employee) but perhaps this list isn't the best place for yet another Grails/Rails comparison? +1
The Journey Is The Reward |
| Powered by Nabble | Edit this page |
