Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
JavaRanch.com/granny.jsp
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Bear Bibeault
  • Junilu Lacar
  • Martin Vashko
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Knute Snortum
Saloon Keepers:
  • Ron McLeod
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
Bartenders:
  • Scott Selikoff
  • salvin francis
  • Piet Souris

Got Groovy to work, now a problem with Grails - would appreciate help

 
Ranch Hand
Posts: 201
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Good day all,

I have set up Grails and I am trying to follow the tutoral http://www.grails.org/Quick+Start

I am following it exactly and I was able to do these steps apparently successfully:
>grails create-app book-pjct
>grails create-domain-class Book
>edited and changed class Book and class BootStrap appropriately
>grails create-controller book.pjct.Book
>Modified class BookController by adding/commenting:
def scaffold = Book
//def index = { }

Stalled on the next command:
>grails run-app

I get the following error:

Resolving dependencies...
Dependencies resolved in 1391ms.
Running script C:\ ... \grails-1.3.5\scripts\RunApp.groovy
Environment set to development
[groovyc] Compiling 1 source file to C:\ ... \grails_app_01\book-pjct\target\classes
Running Grails application..
2010-10-19 11:17:38,852 [main] ERROR http11.Http11Protocol - Error initializing endpoint
java.net.BindException: Address already in use: JVM_Bind<null>:8080
...

I don't see any instructions as to how to change the port to something else, as I've seen for Tomcat or Orion. I looked through the code and do see several places where port 8080 is specified; but I don't know what affect it will have if I change them, and what steps to take to do so if I should.

Has anyone else encountered this? Can anyone offer any help? Thanks in advance. Regards,
 
Bill Johnston
Ranch Hand
Posts: 201
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is there perhaps a better place to post this?
 
Sheriff
Posts: 14691
16
Eclipse IDE VI Editor Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Instead of trying to change the port number, can't you shutdown the application which already listens to it ? Do you having a running instance of Tomcat of some other web server in the background ?
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE VI Editor Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you want to change the port, you can use -Dserver.port=<port number> with the run-app command.
 
Marshal
Posts: 66502
251
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Bill Johnston wrote:Is there perhaps a better place to post this?

I don't know; this appears to be our Grails forum too.
 
Bill Johnston
Ranch Hand
Posts: 201
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Christophe Verré wrote:Instead of trying to change the port number, can't you shutdown the application which already listens to it ? Do you having a running instance of Tomcat of some other web server in the background ?



Thanks very much Christophe.

I didn't think I had Tomcat running; I had shut it down before running Grails.

I knew I had Java EE 5 running, but I had shut it down (or rather 'exit'ed it on the task bar - Windows).

I generally leave my work PC up for days, and sometimes even weeks because it takes about 10 minutes each reboot and it is nice to have all my folders and environments set from the previous day when I come in in the morning.

But I finally did what tech services always recommends (no not re-imaging my HD, LOL) ... I rebooted. That fixed it ... for now anyway.
 
Bill Johnston
Ranch Hand
Posts: 201
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Christophe Verré wrote:If you want to change the port, you can use -Dserver.port=<port number> with the run-app command.



Thanks, I will keep that information.
 
Bill Johnston
Ranch Hand
Posts: 201
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Campbell Ritchie wrote:

Bill Johnston wrote:Is there perhaps a better place to post this?

I don't know; this appears to be our Grails forum too.



Thanks for your reply.
 
Everybody's invited. Except this tiny ad:
Java file APIs (DOC, XLS, PDF, and many more)
https://products.aspose.com/total/java
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!