6 Replies Latest reply on Aug 20, 2010 4:11 PM by Fred Curry

    Creating a new portal from sample

    Mark S. Newbie

      [reposting question, as previous one did not have a propert title]




      I downloaded and installed GateIn (JBoss AS 5.1.0 JDK6 (zip)).


      Given that i am not able to find a good quick start tutorial, to get a feel for the moving parts and the process of creating and customizing new portal , I am trying to go through this faq located here: http://community.jboss.org/wiki/StepsToCreateANewPortalFromSample-Portal.


      The first problem I am encountering is project structure referenced in the document. It states:


      Project Structure

      1.      Copy entire jboss-epp-5.0-src/portal directory to a new location, myportal.

      2.      From the myportal directory, run mvn install. This is required at this level to download and build libraries required to build the portal.


      My questions are:


      1. The problem is i do not see any such path or directory with my installation.

      2. Additionally, i did not need to run any mvn script to get the default portal to come up.  All i did was run the run.sh or run.bat files, depending on platform i am on.  Both seem to start the Jboss app server and I'm able to get to the portal app at http://localhost:8080/portal.

      3. Lastly, does the default portal use a database? and if so where is it?


      Thanks much.

        • 1. Re: Creating a new portal from sample
          Matt Wringe Master

          That documentation is refering to using the portal source code, not using the portal binary, this is why you don't see those paths. In order to follow those directions you will need to either download the source zip or checkout the project from svn.


          3. Lastly, does the default portal use a database? and if so where is it?


          Yes, it uses an embeded database by default (HSQL). The Reference Guide has section on how to configure it http://docs.jboss.com/gatein/portal/3.1.0-FINAL/reference-guide/en-US/html/chap-Reference_Guide-Configuration.html#sect-Reference_Guide-Database_Configuration

          • 2. Re: Creating a new portal from sample
            Mark S. Newbie

            Thanks much Matt,


            Are there any quick start or tutorials you can recommend that discusses how to create a new portal from scrath using the binary? It seems such documentation are lacking (likely because this product is relatively new i am guessing).  The documents that are out there seem to assume a level of experience with the product or jboss or do not clearly identify which 'package' they are referring to.


            We are essentially evaluating a number of portal framework for an upcoming enterprise project.  One of these framework is GateIn as you can guess.


            We'd prefer to use the binaries, and we do not want to touch the framework source code since that could cause headaches when upgrading.  The ability to create a new site, skin it and writing custom code (portlets) in a 'pluggable' manner to do what we need  is appealing.  Other things we are looking at are ease of installation, maintenance, and community involvment/support.


            To that end, we've created a few test cases to evaluate these products to see if they meet our needa.  If you don't mind, i'd like to highlight a few of these cases to see if you or anyone else can provide some guidance on how these would be done with GateIn (assuming very little familiarity with the product at this point).


            • Create a new site, implement a tab based layout
            • Add new custom groups and roles
            • Add a new 'power user' who can login and administer the site, including creating roles, permissioning users and pages, etc.
            • Configure GateIn to use a different database (MySQL for prototyping, and likely Sybase after that)
            • Most importantly however, and where i probably would like to focus most is how can i create a portlet that reads from an existing Stripes ActionBean and uses the data returned to render a page.  That stripes action bean communicates with an existing middle business tier that does all the heavy lifting with regards to retrieval and processing of data.   In this scenario, does this middle tier need to run under the same jvm as GateIn/Jboss (assuming they are not exposed as a service)?  If so, where and how do we configure that?


            I confess i am looking for a bit of hand holding here as i get familiar with the product as i am not able to find good tutorials or getting started docs yet for GateIn.


            Thanks much

            • 3. Re: Creating a new portal from sample
              Mark S. Newbie

              Yes, it uses an embeded database by default (HSQL). The Reference Guide has section on how to configure ithttp://docs.jboss.com/gatein/portal/3.1.0-FINAL/reference-guide/en-US/html/chap-Reference_Guide-Configuration.html#sect-Reference_Guide-Database_Configuration


              These docs seem to be out of date.  jcr-configuration file mentioned appears to now be an xml.  it's easy enough to figure out where the entries mentioned in the documentation are in the jcr-configuration.xml, but it looks like it is now designed to be injected/read at startup...now i need to figure out where the 'real' entries might be configured. 


              It would be nice if there was an up-to-date  quick start or installation document out there.  Really, all i would like to do is get this properly installed and configured quickly so that i can start coding and testing.   Very difficult with the current set of docs i'm finding.


              Another gripe is the documentation references environment variables like $JBOSS/server/default/gatein, or $TOMCAT/gatein.  The problem is if you downloaded the binary that includes jboss (and have never used JBOSS to realize how it is structured/organized), you have to play detective to find where the files are it is talking about.  It should simply say something like "$GATEIN_HOME" in these case.


              Difficult to evaluate products like this...it seems you need to know quite a bit about the product to be able to do so.  A shame really.

              • 4. Re: Creating a new portal from sample
                Fred Curry Newbie

                Hi Mark,


                I have similar requirements to you in terms of being able to build a customized portal. However, I also need to be able to run multiple distinct portals on the same application server. While the binary is quite configurable, I was not able to deploy multiple instances of it. To do this, I needed to build the portal from its source.


                While you can certainly configure the binary to meet many of your needs, you will have much more flexiblity if you make the appropriate changes to its source. While this may seem daunting, the first time I did it (while writing the document), I spent a bit less than a day on it. It took about half that the second time I created a custom portal, and I am able to get exactly what I want. I appreciate your desire to use the binary for ease of upgrades et al, so I suppose that will be a personal choice. I have opted for the source-route.



                As for developing on MySQL, but having Sybase in production, I am in a similar situation. I am using MySQL locally (I use a Mac), but will be using SQL Server in test and production. I have however connected to SQL Server, and my only issue seems to be that performance is not as good. This may be environmental or the version of GateIn I was testing. I am also using OpenDS locally for identity management, but will be using Novell eDirectory in test and production; I have very few concerns. I have been able to implement custom groups without any problem. This is also another reason to go with the build-from-source route, as part of the file structure is embeded in the code. For example, the source code references ../war/src/main/webapp/WEB-INF/conf/rlpportal/portal/group, which contains group names. I am still a little foggy on how this works.


                I hope this helps out a bit,



                • 5. Re: Creating a new portal from sample
                  Mark S. Newbie

                  Thanks Fred. I think it is important to us to be able to configure and enhance without touching the source as i'm sure there will be many updates and patches to this framework in the future.  From past experience, once you have touched the source of the core product, upgrading can be a nightware (though there are ways to make it less so, like inherting/extending from core classes are building a layer above the framework).


                  that said, I did checkout the source and attempted to compile and build based on this faq: https://community.jboss.org/wiki/GateInbuildinstallrunandmore.

                  Although the first maven build  stated "Build successful", looking at the maven output, there were a number of tasks that seemed to fail.  Additionally many of the jars it was trying to download could not be found.


                  When attempting to run the second mvn command, a number errors were noted in the output and eventually a fatal out of memory errors occurred.   At that point i threw my hands up and yelled 'uncle'.


                  We'll probably try this again later when it has matured a bit, i think it has great potential, but for a project that is expected to be completed in the next 4- 6 months, it may be a bit risky i feel.

                  • 6. Re: Creating a new portal from sample
                    Fred Curry Newbie

                    I ran into a similar problem with the memory issues using Maven. I solved the issue by using a faster internet connection. Since then, I have not had any problems. I also ran into some error, but they seemed to be problems with the tests not the build (not that that should make you feel any better). When it was all said-and-done, I did not have may errors, and everything seems to be working fine.


                    Good luck with whatever platform you choose,