7 Replies Latest reply: Jul 30, 2010 1:30 PM by Quincy Mitchell RSS

Installation of a stable JBoss + Eclipse + Ubuntu

Quincy Mitchell Newbie

JEE development is crazy.  All these projects don't like to talk to each other and everything has bugs with installing and configuring.

 

Please point me in the direction of an article which describes the configuration of a stable (well working) JBoss + Eclipse + Ubuntu.  I've tried countless projects to get working and each have bugs which stop me.  I would prefer the newest versions of those three but more importantly I would like for it to work out of the box.

 

Thanks,

Quincy Mitchell

  • 1. Re: Installation of a stable JBoss + Eclipse + Ubuntu
    Peter Johnson Master

    I think that the closest you will get is if you purchase a support contract and get JBoss EAP 5 (based on JBoss AS 5.1.0) and the JBoss Developer Studio (Eclipse, not sure which version but definitely not 3.6, plus JBoss Tools, probably also not the latest level). Those two products have been tested to work together. However, if you want the latest and greatest of everything, then you are on the bleeding edge and will have to just deal with the problems you run into.

     

    Personally, I just use Eclipse as a glorified text editor and do all of builds/deploys using Ant/Maven. I find that many of the wizards built into some of the JBoss Tools are harder to use that simply editing the pertinent text file, so I avoid most of them. I typically have enough logging in the app to debug any issues that come up but can debug via Eclipse in a pinch. This system works for me on Linux (Fedoira, Ubuntu) and on Windows.

  • 2. Re: Installation of a stable JBoss + Eclipse + Ubuntu
    Quincy Mitchell Newbie

    Peter Johnson,

     

    Thanks for your reply.  I totally support you using Eclipse as a glorified text editor.  Do you still get any benefits of auto-completion?

     

    Could you write out your configuration / installation of your configuration or point me to someone who has written an article of one?

     

    I would really like to have a list of versions at the very least of each product.

     

    Also to note, one really important thing to me is security.  I would like to be confident that all these product work fluently with all the necessary requirements of security and performance.  I'd rather not be hacked in a few months.  So, do you know of any big trustworthy companies who are securely running a particular configuration?  It sounds like anything that needs to be secure must be bought at a high price.

     

    Thanks for your advice and looking forward to hearing more,

    Quincy Mitchell

  • 3. Re: Installation of a stable JBoss + Eclipse + Ubuntu
    Stefano Ficcadenti Newbie

    I am using a Ubuntu Server 8.04 LTS with JBoss 5.1 (installed as a service) and Eclipse 3.6 Galileo as Editor.

  • 4. Re: Installation of a stable JBoss + Eclipse + Ubuntu
    Peter Johnson Master

    >>Do you still get any benefits of auto-completion?

    Yes, I could not live without that.

     

    >>Could you write out your configuration / installation of your  configuration or point me to someone who has written an article of one?

    Check out the source code for JBoss in Action. You can find it at http://code.google.com/p/jbia/

     

    >>I would really like to have a list of versions at the very least of each product.

    JBoss ASA 5.1.0.GA (there is a milestone 4 for AS 6, but that is a beta). Eclipse 3.6 (Helios). For JBoss Tools I always prefer the "Development Milestones" link.

     

    >>Also to note, one really important thing to me is security.

    Out fo the box, JBoss AS binds to localhost which means you can access the app server only from your PC. Before you bind to another address, such as 0.0.0.0, you need to lock down a few things. This FAQ should point you to all the wiki pages on locking things down: http://community.jboss.org/wiki/SecurityFAQ (By the way, JBoss EAP comes withjmost of these settings already locked down)

    Also, you need to make sure that the apps you deploy are not providing huge security holes. OWASP has some good informaiton on that: http://www.owasp.org/index.php/Main_Page

  • 5. Re: Installation of a stable JBoss + Eclipse + Ubuntu
    Quincy Mitchell Newbie

    Thanks to you both.  I was able to get a hello world jsp to work on 5.1.0.GA  right out of the box.

     

    For other's benefit I followed:

    http://www.centerkey.com/jboss/

     

    but using ubuntu you don't need any of those environment paths.  just run ./run.sh and create the war with the jar command then copy the war to the deployment folder.

     

    One thing that I had to fix was having openjdk-java and sun-java.  do:

     

    update-alternatives --list java

     

    to make sure you only have sun-java.  The admin-console didn't work due to it not liking the openjdk libraries while running on sun-java.

     

    A few initial thoughts/questions.  Why does jboss use up sooo much memory?  Once loaded it finally settles at 394MB running the admin-console and a helloworld.  I was impressed however on how well it utilized both of my processors.

  • 6. Re: Installation of a stable JBoss + Eclipse + Ubuntu
    jaikiran pai Master

    Quincy Mitchell wrote:

     


     

    A few initial thoughts/questions.  Why does jboss use up sooo much memory? 

    That's kind of a known problem with JBoss AS-5 and something that needs to be fixed in later versions.

     

    Quincy Mitchell wrote:

     

    Once loaded it finally settles at 394MB running the admin-console and a helloworld. 

    There's one very simple change that you could do to bring down the memory (not sure by how much). JBoss AS-5 by default, enabled some debug level MBeans (which are in most cases meant for JBoss server developer's use). These MBeans are too much in number and are known to increase memory usage. What you can do is, change the following from JBOSS_HOME/server/< servername>/conf/bootstrap/deployers.xml:

     

    <bean name="Deployers">
          <annotation>@org.jboss.aop.microcontainer.aspects.jmx.JMX(name="jboss.deployment:service=DeployersImpl", exposedInterface=org.jboss.deployers.plugins.deployers.DeployersImplMBean.class, registerDirectly=true)</annotation>
          <constructor><parameter><inject bean="jboss.kernel:service=KernelController"/></parameter></constructor>
          <!-- Accept any implementor of deployer -->
          <incallback method="addDeployer"/>
          <uncallback method="removeDeployer"/>
          <property name="mgtObjectCreator"><inject bean="ManagedObjectCreator"/></property>
       </bean>

     

    to:

     

    <bean name="Deployers">
           <!-- Uncomment the following @org.jboss.aop.microcontainer.aspects.jmx.JMX to enable registering
        MC beans as MBeans. These MBeans provide debug level information about which deployers were selected for
        processing the deployment and what attachments were added to the deployment. More details http://www.jboss.org/index.html?module=bb&op=viewtopic&t=155074&start=10#4233874
        -->
        <!--
          <annotation>@org.jboss.aop.microcontainer.aspects.jmx.JMX(name="jboss.deployment:service=DeployersImpl", exposedInterface=org.jboss.deployers.plugins.deployers.DeployersImplMBean.class, registerDirectly=true)</annotation>
          -->
          <constructor><parameter><inject bean="jboss.kernel:service=KernelController"/></parameter></constructor>
          <!-- Accept any implementor of deployer -->
          <incallback method="addDeployer"/>
          <uncallback method="removeDeployer"/>
          <property name="mgtObjectCreator"><inject bean="ManagedObjectCreator"/></property>
       </bean>
    

     

    Notice that I have commented out the "annotation" element in that section. More details can be found in this JIRA https://jira.jboss.org/browse/JBAS-6987. This fix has been done in JBoss AS 6.0 series.

  • 7. Re: Installation of a stable JBoss + Eclipse + Ubuntu
    Quincy Mitchell Newbie

    Thanks that helped a little.  It starts with about 347MB now.