apache continuum build, test, and...

43
Apache Continuum Build, Test, and Release Wendy Smoak ApacheCon Europe March 27, 2009

Upload: others

Post on 21-Mar-2020

39 views

Category:

Documents


0 download

TRANSCRIPT

Apache ContinuumBuild, Test, and Release

Wendy Smoak

ApacheCon EuropeMarch 27, 2009

• Member, The Apache Software Foundation

• Committer, Apache Continuum, Archiva, Struts, Tiles, Maven, ...

• Solutions Architect, G2iX

[email protected]

http://wsmoak.net

Wendy Smoak

2

How many...

3

Continuous Integration

4

Continuous Integration

... is a software development practice in which members of a team integrate their work frequently.

Usually each person integrates at least daily - leading to multiple integrations per day.

Each integration is verified by an automated build (including tests).

http://www.martinfowler.com/articles/continuousIntegration.html5

Continuous Integration

6

build

check in

test

notify

Why CI?

7

• Save time

• Increase visibility

• Improve coverage

Apache Continuum

8

• Apache top-level project

• More than CI...

• Role-based Access Control

• Release Management

• Parallel and Distributed Builds

• Configurable JVM Wrapper

Apache Continuum

9

Prerequisites

• Java SE 5

• Maven, Ant, Script

• Subversion, CVS, Git

• Tests!

10

• Download

• Install

• Start and Stop

• Configure

• Build Definitions

• Build Environments

• Build Schedules

• Build Queues

• Release

• Project Groups

• Users and Roles

• Notifiers

• JVM Wrapper

• XML-RPC

Demo

11

Download

http://continuum.apache.org12

Install

• Unpack the distribution

• Continuum + Jetty + Derby

13

$ lsLICENSE apps conf derby.log logsNOTICE bin data lib tmp

Pre-Configure

• conf/jetty.xml

• Port number

• SMTP config

• Data sources

14

Start

• bin/continuum start

• Automatically detects platform

• Windows

• bin/continuum.bat console --or--

• bin/continuum.bat install (as a service)

15

Demo Setup

16

svn.example.comhttpd + mod_dav_svn

running locally

build.example.comContinuum + Jetty

running locally

command linedeveloper workstation

repo.example.comArchiva + Jettyrunning locally

Demo!

17

Admin User

18

Configure

19

Add Projects

• Maven 2

• Ant

• Maven 1

• Shell Script

20

Project Groups

• Logical group of projects

• Multi-module Maven project

21

Build

• Build all projects

• Order is determined by dependencies

• Build one or more projects

22

View Results

• Build status

• Build output

• Test results

• Working copy

23

Release

• Web interface

• Prepare, then Perform

• Consistent environment

24

End Demo

25

Installations

• Environment Variable

• Tool (Ant, Maven, JDK)

26

JDK Maven

var=value

Build Environments

27

Build Environment

JDK Maven var=value

Build Schedules

• Hourly by default

• crontab format

28

Schedule

When to run

Max time

Build Queue(s)

Build Definitions

• Build file such as pom.xml

• goals and arguments

• Schedule

• Build Environment

29

Build Queues

• For parallel builds

• Associated with Schedules

30

Build Queue 1

Build Queue 2

Notifiers

• Email, IRC, MSN, Jabber, Wagon

• Configure in Maven pom.xml

• Add directly to Continuum

• Can notify the latest committers

31

32

Parallel Builds

Distributed Builds

33

Users

• Self registration

• Per-project roles

• Web based

• Configurable security rules

34

XML-RPC

• Control Continuum from external scripts or programs

• Java examples available

35

JVM Wrapper

• conf/wrapper.conf

• http://wrapper.tanukisoftware.org

36

SCM Support

http://docs.codehaus.org/display/SCM/SCM+Matrix37

Alternatives

• Bamboo (Atlassian)

• Cruise Control (Thoughtworks)

• Hudson

• ... and many others

http://damagecontrol.codehaus.org/Continuous+Integration+Server+Feature+Matrix38

What’s coming?

• Plugin architecture

• Hosting project websites

• ... what do you need?

39

Where we need help

40

• Discussing and coding features and fixes

• UI Design and Usability

• Writing documentation

• Testing - JUnit, TestNG, Selenium

Where you can find us

41

• http://continuum.apache.org

[email protected]

• #continuum on irc.codehaus.org

• Here at ApacheCon!

Questions?

42

Apache ContinuumBuild, Test, and Release

Wendy Smoak

ApacheCon EuropeMarch 27, 2009