creating a world-class build system, and getting it right

27
Creating a World Class Build System Scott Estes Release Management and Ops Citrix Systems, Inc. Friday, May 27, 2022

Upload: perforce

Post on 15-May-2015

440 views

Category:

Technology


0 download

DESCRIPTION

Build versus buy, mashups, dashboards, multiple teams with competing priorities, reporting, regulating ... how do you make it all come together into a quality product build without getting lost in the shuffle? Join Scott Estes from the Citrix XenApp/XenDesktop build team for this interactive discussion about creating an ideal build and test system with Perforce at its core. Learn about the requirements you'll need to meet, and the pitfalls you'll want to avoid.

TRANSCRIPT

Page 1: Creating a World-Class Build System, and Getting It Right

Creating a World Class Build SystemScott EstesRelease Management and OpsCitrix Systems, Inc.

April 12, 2023

Page 2: Creating a World-Class Build System, and Getting It Right

AGENDA

Getting Started

Planning and Design

Implementation and Execution

Optimizing the System

Maintenance and Evolution

Page 3: Creating a World-Class Build System, and Getting It Right

GETTING STARTED

Creating and maintaining a world class build system involves much more than a few well-written scripts, e.g.

• Know the Stakeholders• Know the Stakeholders’ requirements• Have a vision • Engage, foster and grow support base at all levels• Be a “Center of Excellence”

Page 4: Creating a World-Class Build System, and Getting It Right

GETTING STARTED – Evolution or Revolution?

Pros• Slow, stable change• Can keep pace

Cons• Can be too slow• Can lose momentum

Pros• Mitigates barriers to change• Can facilitate other changes

Cons• Can be disruptive• Unable to keep pace• Unintended side-effects

Page 5: Creating a World-Class Build System, and Getting It Right

GETTING STARTED – Evolution or Revolution?

Leverage both,• Revolution in small doses• Energy from revolution can fuel evolution

across the organization

Page 6: Creating a World-Class Build System, and Getting It Right

GETTING STARTED – Build or Buy?

Depends on,

• Resources• Timeline/schedule

Page 7: Creating a World-Class Build System, and Getting It Right

GETTING STARTED – ONE LAST THING

More than likely there will not be enough resources within the Build team to accomplish the Build Vision.

Use others to help...

Page 8: Creating a World-Class Build System, and Getting It Right

PLANNING AND DESIGN

A great build system facilitates,

• “Determinism”• Performance• Parallel development• Maintenance• Business Continuity• Self-service

Page 9: Creating a World-Class Build System, and Getting It Right

PLANNING AND DESIGN – WHERE ARE THE TEAMS?

Knowing this will prevent support outages.

Page 10: Creating a World-Class Build System, and Getting It Right

PLANNING AND DESIGN – WHAT IS THE PRODUCT?

Knowing the architecture ensures extensibility of the Vision.

At Citrix:• XenApp/XenDesktop use a Technology Component-

based architecture.• Components treated as “black boxes”.• Component visions are not tied to releases.• Features are released to product when ready.• Release process is much more efficient and

dynamic.

Page 11: Creating a World-Class Build System, and Getting It Right

PLANNING AND DESIGN – DEVELOPER REQUIREMENTS

Iterative feedback ensures success.

• Developers are pulled in different directions; don’t add additional stress.

• Provide an “Out of the box” Build experience.• Support as needed.• Build confidence in the System and Vision.

Page 12: Creating a World-Class Build System, and Getting It Right

IMPLEMENTATION AND EXECUTION

At Citrix:

Perforce Linked Automated Network Builder (PLANB)

• Determines when to build.• Creates Build environment.• Builds component binaries.• Creates installers.• Publishes product builds.

Two types of Builds,• SDK• DVD

Page 13: Creating a World-Class Build System, and Getting It Right

IMPLEMENTATION AND EXECUTION - PLANB

Overview:

WatchCreate

environmentBuild

binariesPublish

SDKCreate DVD

Publish/Test

Svr 1 Svr 2 Svr n

Perforce

Save Area

Page 14: Creating a World-Class Build System, and Getting It Right

IMPLEMENTATION AND EXECUTION - BUILDING

Most components can follow these steps:

InputPre-Build

StepsBuild

Post-Build Steps

Output

With these attributes:• Owner(s)• Stakeholder(s)• Input(s)• Control(s)• Output(s)

Page 15: Creating a World-Class Build System, and Getting It Right

IMPLEMENTATION AND EXECUTION - INPUT

Anything that causes a new build, e.g. code submission, SDK update, etc.

At Citrix: A Watcher service is used to receive Perforce change notifications and start the build.

Perforce

Project config

changes?

Get changes

Call VM Creator

Update client specs

Cb

Yes

No

Change received

Page 16: Creating a World-Class Build System, and Getting It Right

IMPLEMENTATION AND EXECUTION – PRE-BUILD

Configure the build environment.

At Citrix: A VM creator service dynamically creates virtual build machines using XenServer® technologies.

VM available

?

Wait for available

VM

Start build script

Connect drives to

VM

Cb

Yes

No

Determine VM type

Assign VM to host

Page 17: Creating a World-Class Build System, and Getting It Right

IMPLEMENTATION AND EXECUTION – BUILD

Developer reviews are critical.

At Citrix: An add-on to Visual Studio provides an “out of the box” experience while preserving company mandates.

Built?

Log error and

continue

Create output

Yes

No

ID what to build

Sign, index

symbols, etc.

Get code

Perforce

Conf.proj/

search

Check/Build deps

Compile

Done?

YesNo

Page 18: Creating a World-Class Build System, and Getting It Right

IMPLEMENTATION AND EXECUTION – BUILD

At Citrix: Non-Windows Builds are make-based.

Built?

Create output

Yes

No

Search for makefiles

Sign, index

symbols, etc.

Get code

Perforce

Compile/Link

Done?

YesNo

Log error and die

Page 19: Creating a World-Class Build System, and Getting It Right

IMPLEMENTATION AND EXECUTION – POST-BUILD

Create a testable image and supporting build artifacts.

At Citrix: A “toolbox” of PowerShell scripts create the DVD and releases the build for testing.

Poll for changes

Create reports

Release to Test

Symbol Server

Layout config

Get layout

info

UpdateSymbolserver

Page 20: Creating a World-Class Build System, and Getting It Right

IMPLEMENTATION AND EXECUTION – OUTPUT

Test the product and report.

At Citrix: A test automation framework executes Build Verification Tests and other test suites.

Execute BVT

Execute additional

testsReport

Provision test env

SkynetSkynet

Pass?

Report

Test config

Yes

No

Page 21: Creating a World-Class Build System, and Getting It Right

OPTIMIZING THE SYSTEM

A World-Class build system optimizes,

• “Determinism”• Performance• Parallel development• Maintenance• Business Continuity• Self-service

A great build system facilitates,

• “Determinism”• Performance• Parallel development• Maintenance• Business Continuity• Self-service

• Standards

Page 22: Creating a World-Class Build System, and Getting It Right

OPTIMIZING THE SYSTEM – WHAT’S IN THE BUILD?

Accurate, fast reporting, i.e. “Determinism”.

At Citrix:• Multiple reports based on audience,

• What binaries changed Test• What code changed Dev/Release

Mgmt/ Test

Page 23: Creating a World-Class Build System, and Getting It Right

OPTIMIZING THE SYSTEM – LUDICROUS SPEED!

Do,• Facilitate Code Coverage

efforts.• Leverage incremental

building and architecture.• Use dedicated Perforce

Proxies.• Use as fast hardware as

can afford.• Isolate Build network.• Review Business

Continuity processes.

Don’t,• Compile code multiple

times.• Compile dead code.• Ignore dependencies.• Ignore the infrastructure.• Ignore Business

Continuity.

Build faster than can be consumed.

Page 24: Creating a World-Class Build System, and Getting It Right

OPTIMIZING THE SYSTEM

At Citrix: a topographical overview:UK

Cam

Devs

US

Business Continuity Center

Build Farm

NAS

1GB

10GB

Servers

Build machines

P4 ProxyDataP4 Proxy

Perforce Svr 1

Builds NAS

Perforce Svr 2

Devs

1GB

Perforce Svr1/Proxy ports

Servers

Build machines (+BC for Chf)

Chf

Devs

Servers

Build machines(+BC for Cam)

1GB

Perforce Svr1/Proxy ports

Builds NAS(+BC for Chf)

Builds NAS(+BC for Cam)

Page 25: Creating a World-Class Build System, and Getting It Right

MAINTENANCE AND EVOLUTION

How to do it:• Stage updates• Automate, automate, automate!• Test to trust• Keep everyone updated

When to do it:• Align with project milestones and schedules• Associate with a specific project

Page 26: Creating a World-Class Build System, and Getting It Right

TAKEAWAYS

• Have a vision• Enable instead of mandate.• Talk to others and back it up.• Provide a simple and maintainable

infrastructure.

Page 27: Creating a World-Class Build System, and Getting It Right