GithubHelp home page GithubHelp logo

dca-portal's Introduction

dca-portal: Sample Portal

Author: Thomas Heute, Peter Palaga
Level: Beginner
Technologies: GateIn Portal, Portal Container
Summary: Sample Portal
Target Product: GateIn Portal 3.6
Source: https://github.com/gatein/gatein-portal-quickstart

What is it?

This project demonstrates a how to create a new Portal Container from scratch. It covers many aspects of new Portal Container creation, such as:

  • Custom Home Page Portlet
  • Translation resource bundles
  • Pages and Site Layouts
  • Navigation Definitions
  • Custom Sign In Page

For more details, see Portal Containers page of GateIn Portal Developer Guide.

System Requirements

All you need to build this example project is Java 6.0 (Java SDK 1.6) or newer and Maven 3.0 or newer.

The project is designed to be deployed on GateIn Portal 3.6 running on JBoss AS.

Configure Maven

You do not need to touch your settings.xml because of this quickstart. All necessary artifacts are available in public repositories.

Build and Deploy

Portal Extensions and Portal Containers are not hot-deployable. Therefore, it is not possible to deploy them using mvn jboss-as:deploy or copying to the default JBoss AS deployment folder when GateIn Portal is running. Instead of that you will need to:

  1. Make sure that the Portal is not running, e.g. by running

     $JBOSS_HOME/bin/jboss-cli.sh --connect controller=127.0.0.1:9999 command=:shutdown
    
  2. Open a command line and navigate to the root directory of this quickstart.

  3. Run the following command to build the archive:

     mvn clean package
    

    This will create ear/target/dca-portal.ear.

  4. Copy this file into the GateIn Portal extension deployment folder: $JBOSS_HOME/gatein/extensions

Setup JBoss Datasources and Security Policies

In JBoss, Datasources and Security Policies need to be defined on the level of Application Server and they cannot[*] be defined within EARs because otherwise centralized management would not be possible. This is the reason why it is not enough just to deploy dca-portal.ear. You also need to define the Datasources and Security Policies e.g. in $BOSS_HOME/standalone/configuration/standalone.xml.

The standalone.xml available in the out-of-the-box GateIn Portal 3.6 installation contains the needed pieces of XML commented out. Please search for Uncommented this when deploying dca-portal in the file and uncomment the necessary XML code blocks. Note that you should uncomment two datasources and one security-policy.

Except for editting standalone.xml, JBoss Datasources and Security Policies can be defined using CLI or JBoss Web Console as described in JBoss AS 7.1 Admin Guide

[*] Datasources can be defined in EARs but such ones are not managed, see JBoss AS 7.1 Admin Guide.

Access the Sample Portal

To ensure that the Sample Portal has been deployed successfully visit http://127.0.0.1:8080/dca-portal) with your web browser.

Start the Portal

  1. Open a command line and navigate to the root of the JBoss server directory.

  2. The following shows the command line to start the server with the web profile:

     For Linux:   JBOSS_HOME/bin/standalone.sh
     For Windows: JBOSS_HOME\bin\standalone.bat
    

Undeploy the Archive

To delete a Portal Extension or Portal Container:

  1. Delete JBOSS_HOME/gatein/extensions/dca-portal.ear
  2. Restart GateIn Portal

Please note that the content written to the database by the Extension or Portal Container (such as adding new pages) is not reversible.

Use JBoss Developer Studio or Eclipse to Run this Quickstart

Portal Extensions and Portal Containers are not directly deployable from JBoss Developer Studio nor Eclipse at this time. See Build and Deploy section above for an alternative.

Debug the Application

If you want to debug the source code or look at the Javadocs of any library in the project, run either of the following commands to pull them into your local repository. The IDE should then detect them.

mvn dependency:sources
mvn dependency:resolve -Dclassifier=javadoc

Feedback

Please post feedback on this quickstart or GateIn Portal on GateIn Forums.

dca-portal's People

Contributors

bryan-lunt avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.