Getting
Started
With Kuali Rice 2.0
Perspective
What are Developer Use Cases for Rice 2.0?
- Migrate from Rice 1.0
- New Rice 2.0 Application
- Migrate from other Legacy applications
- Maintain a custom Rice distribution
Maintain a Custom Rice Distribution
What you need
- Version Control
- Build Process
- Change Management Protocols
- Continuous Integration
- Kuali Foundation update proving ground
- Try to model from what the Kuali Foundation uses for the best support
Configuration and Change Management
- Conventions and Principles
- Best Practices
Version Control
- Setup and Configuration
- Capturing updates
Version Control
Setup and Configuration
Setup an SVN repository and follow the vendor branch methodology for setup. Vendor branch creates a separation of concerns between the local development projects and the vendor projects. The vendor projects are where vendor updates are applied and tested before merging into the development projects.
Vendor Branch
Setup
- Create Vendor area
- Export Rice
- Import Rice into vendor area
- Export Rice from vendor area
- Import Rice local project
Vendor Branch Setup
Create Vendor Area
svn mkdir https://svnrepository/vendor/kf/
Should end up with...
vendor
\-> kf
Vendor Branch Setup
Export Rice
svn export https://test.kuali.org/svn/rice/trunk rice-trunk
Vendor Branch Setup
Import Rice into vendor area
mkdir rice
mv rice-trunk rice/trunk
svn import rice https://svnrepository/vendor/kf/rice -m "Inital import of rice project"
Vendor Branch Setup
Import Rice into vendor area
Should end up with...
vendor
\-> kf
\->rice
\->trunk
Vendor Branch Setup
Export Rice from vendor area
svn export https://svnrepository/vendor/kf/rice/trunk rice-vendor-trunk
Vendor Branch Setup
Prepare Rice for maven overlay
Vendor Branch Setup
Import Rice into the custom Rice project repository
Version Control
Capturing software updates
- Merging changes from the Kuali Foundation
- Patch updates
Capturing Software Updates
Merging changes from the Kuali Foundation
Capturing Software Updates
Patch updates
Sometimes you want to be picky about your changes, but this can cause problems later when you decide to merge. Handle with care.
Migrate from other Legacy applications
or a New Rice Application
In both of these cases, the same setup applies
Setup
- Prepare rice project for maven overlay
- Example assumes a project built from createproject.groovy
Prepare rice project for maven overlay
<name>Custom App</name>
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.kuali.rice</groupId>
<artifactId>rice</artifactId>
<version>2.0.0-b2-SNAPSHOT</version>
</parent>
<artifactId>customapp</artifactId>
<packaging>war</packaging>
Continued..
≪plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
Continued..
<configuration>
<overlays>
<overlay>
<groupId>${project.groupId}</groupId>
<artifactId>rice-web</artifactId>
<includes>
<include>${war.overlay.pattern.1}</include>
</includes>
<filtered>true</filtered>
</overlay>
Continued...
<overlay>
<groupId>${project.groupId}</groupId>
<artifactId>rice-web</artifactId>
<excludes>
<exclude>${war.overlay.pattern.1}</exclude>
<exclude>${war.overlay.exclude.2}</exclude>
</excludes>
</overlay>
</overlays>
</configuration>
</plugin>
Continued...
Setup properties for war overlay exclusions
<properties>
<war.overlay.pattern.1>WEB-INF/web.xml</war.overlay.pattern.1>
<war.overlay.exclude.2>DO_NOT_MATCH_ANYTHING_PATTERN</war.overlay.exclude.2>
</properties>
Continued...
Add the rice-web.war dependency
<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>rice-web</artifactId>
<version>${project.version}</version>
<type>war</type>
</dependency>
Conventions and Principles
More specifically: Kuali Rice 2.0
Convention Over Configuration
A software development paradigm insists only unconventional aspects of software needs to be configured. Convention is aggressively established and followed.
Convention Over Configuration
Example
Naming Conventions: By naming classes and packages by convention, it is easier for developers to find the source code they are looking for. Without these conventions, the search would be much more tedious.
Convention Over Configuration
Example
Maven project structure: Due to the numerous conventions attached to a maven project, developers are able to crosstrain easier. Developers acrossed maven projects are more familiar with the project structure and able to learn quicker.
Changes are Incremental
- With each code change, there are other elements that may be coupled
- Spring configuration
- OJB mapping
- Java source
- Database change
- Changes should be distributed and tested together
- Sounds obvious
- Not always practiced with this in mind
Changes are Incremental
More
- Changes should be distributed and tested together
- Sounds obvious
- Not always practiced with this in mind
Changes are Incremental
More
- Focusing on changes are faster than on the entire application, and can provide a more agile view. This will help when setting up more intuitive Continuous Integration
Continuous Integration
Overview
The idea is to provide more agility to your software project by running continually. The Agile development process gives a iterative/incremental perspective onf software development. Continuous Integration facilitates this by breaking your processes down by increment.
Continuous Integration
Processes to Run Continuously
- Build
- Unit and Integration Tests
- Packaging and Distribution
- Deployment
Continuous Integration
Jenkins
This is the CI tool that the Kuali Foundation is supporting and standardizing on.
Jenkins
- Utilizes slaves, so setup a dedicated master
- Intend on concurrent builds
- Concurrently validate with unit tests, integration tests, and smoke testing
- If you are customizing your own rice distribution, plan on concurrently validating each version with your rice projects.
Jenkins
More
- Reports provide views on
- DDL validation
- Generated source validation
- Testing/Code coverage
- Documentation
Database Change Management
- Conventions are your friend
- Support test data
- Support institutional specific changes
- Build conventions around change metadata
- Revision information
- Issue tracking information
- Continuous Integration
- Testing
- Support versioning and change rollback
Database Change Management
Liquibase
- A change management tool that allows one to view database changes incrementally and apply them incrementally
- Offers flexibility of extension
- Custom KIM refactorings
- Custom KNS refactorings
- Database agnostic updates
- Migrate changes directly from one database to another (even across platforms)
- Couple database changes to source code changes
The End
Thank you all
http://www.github.com/r351574nc3