0bf139eafbd7faea34469984f9a91084.ppt
- Количество слайдов: 38
Perforce @ SAP Vladimir Velinov Build Engineering Team SAP Labs Bulgaria
Perforce SCM Perforce@SAP Demo Q&A
Perforce SCM Perforce@SAP Demo Q&A
Glossary of terms Perforce (P 4) calls it… Other SCMs… add check in, extract part branch codeline, project, stream changelist changeset client workspace project, view, sandbox, family + release + component + work area depot repository, archive edit check out (for edit) head revision tip revision, head integrate merge, branch resolve revert merge uncheckout, undo checkout, unlock revision or part submit checkin, put sync check out tip, refresh, extract part, get version ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 4
How Perforce works Master file repository ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 5
Perforce server § Changeslists § Integration history § Labels § Client workspaces §… ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 6
P 4 users and clients P 4 users n Unique name (case sensitive) n Can be organized in groups n Security is managed by protection tables (admins only) P 4 Clients (client workspace) n Mapping P 4 server depot -> local FS n Have a local root n Client view of depot n Stored in Server DB and keeps the file versions on developers FS n Write permission is enabled when you edit file and disabled when you submit changes n Line ending (CR/LF) is determined automatically ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 7
P 4 File management File structure - herarchical n Example: //depot/project/release/… File operations n Add - add new file to depot n Edit - modifies existing file n Delete – marks file as deleted n Obliterate – physically delete file (admins only) n Branch/Integrate – merge changes from another branch File types n Base types – text, binary, symlink, unicode, apple n File type modifiers n Storage method ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 8
P 4 Changelists What are changelists? n n Logical units to organize your changes Atomic change transactions Ensure consistency of your work – related changes in files are checked in together Unique numbers Creating changelists n Default changelist n Lock/unlock files or shared locks Submiting changelists n Enter some description Resolving conflicts n Manual – merge tool n Auto resolve Properties n n n Number (unique) Description – text info List of affected files user@client Timestamp ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 9
P 4 Jobs Basic defect tracking mechanism n Description n Status n Link to a changelist(s) ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 10
P 4 Labels Snapshot of current state of set of files n Use names instead of numbers n Can be used when creating releases n Can be used to restore older releases ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 11
Branching n Managing changes between two or more sets of related files n Inter-File branching n Uses codelines (file sets) n Source -> Target codeline n Low overhead - Lazy copy ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 12
Integration n Propagate changes between two or more codelines n Keep track of fixes n Integration history Next: Revision graph ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 13
Revision graph New feature codeline Dev codeline Released codeline ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 14
Revision graph – Real life example Dev codelines Milestone codelines Delivery codelines New feature codelines Special customer codelines ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 15
Perforce vs. CVS Attribute CVS Perforce Branching and merging CVS offers branching, but requires manual tracking of merge history. Perforce branching automatically tracks the history of all branching operations. Distributed development No performance solutions for remote development are available. The Perforce Proxy offers caching for remote users. Atomic transactions Doesn’t have an atomic change mechanism and cannot group changes to related files. Changelists - enabling users to track file versions associated with a feature addition or issue resolution. Scalability and performance Metadata is appended and maintained in the content of each file. Centralized metadata records all user and file activity. Defect tracking Not part of CVS; need to use a Perforce provides a basic defect separate defect tracking solution. tracking - jobs, and integrates with several 3 rd party defect tracking systems. Integration with related tools Integrations are available via the open source community. ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 17 Many third-party tools are designed specifically to work with Perforce.
Perforce vs. Subversion Attribute Subversion Perforce Branching and merging Subversion offers branching, but requires manual tracking of merge history. Perforce branching automatically tracks the history of all branching operations. Distributed development No performance solutions for remote development are available. The Perforce Proxy offers caching for remote users. Platform dependencies Compatibility issues exist with line ending of files in Unix and Windows environments. Line ending issues are solved automatically. Scalability and performance Limited due to file binary diff versioning process. Architected for speed, which scales linearly. Defect tracking Not part of Subversion; need to use a separate defect tracking solution. Perforce provides a basic defect tracking - jobs, and integrates with several 3 rd party defect tracking systems. Integration with related tools Integrations are available via the open source community. Perforce integrates with most leading IDEs, build tools, Microsoft Office, Adobe Photoshop, and many others. ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 18
Perforce vs. Microsoft VSS Attribute VSS Perforce Platform dependencies Works over network shares slowing response times. Limited to Microsoft platforms only. Client/server architecture. Response times are much faster for most operations. Scalability and performance MS recommends that VSS DB doesn’t exceed 3 to 5 GB, for perf. and stability reasons. The Perforce repository can scale to the multiterabyte range easily. Atomic transactions Doesn’t have an atomic change mechanism, and cannot group changes to related files. Changelists - enabling users to track file versions with a new feature or issue resolution. Branching and merging Limited support. Branching relationships aren’t maintained. Perforce branching automatically tracks the history of all branching operations. Distributed development Doesn’t offer a scalable The Perforce Proxy offers distributed development solution. caching for remote users. Integration with related tools Only available for IDEs that support the SCC interface. ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 19 Many available tools are designed specifically to work with Perforce, including defect tracking tools.
P 4 Installation & Toolset Installation n Download from www. perforce. com n Trial version supports 2 users/clients n Support for most major platforms - Win/UNIX/Mac. OS Toolset n n n n n P 4 D – Perforce server P 4 S – Perforce server service (Windows only) P 4 – command line client P 4 Win – GUI for Windows P 4 V – cross platform GUI P 4 Web – Web GUI for remote access P 4 Proxy – Caching for distributed development P 4 Merge – Perforce merge tool P 4 Diff – Perforce diff tool ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 20
Perforce SCM Perforce@SAP Demo Q&A
History of Perforce within SAP 1998 ü ü Evaluation of SCM systems 1999 ü Productive move from Clear. Case, SCCS into Perforce ’ 00 -’ 04 ü Tool infrastructure development & maintenance First Perforce server at SAP ü 2005 Major Hardware investments & performance improvements + P 4 MS – Perforce. Management. System running on SAP Net. Weaver 80+ 2006. 1 4, 600+ Perforce server instances Upgrade of all instances Registered Perforce users ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 22
SAP's Global R&D Organization Canada Montréal Germany 45. 79% Walldorf and satellites Hungary 3. 69% China Budapest Shanghai Bulgaria Sofia 4. 57% North America Israel Palo Alto and satellites Ra’anana 13. 52% 17. 74% India 6. 55% Bangalore Location Outbound Inbound Bulgaria 31. 45 GB 0. 68 GB India 11. 70 GB 0. 18 GB Israel 954. 55 GB 13. 72 GB 9. 31 TB 2. 74 TB Overall Monthly transfered volume via P 4 protocol ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 23
Key figures – User/License growth USERS SERVERS +11. 6% users last year ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 24 LEVELS FILES/REV Perforce users & licenses CURRENT
Key figures – Server growth USERS SERVERS +11, 6% users last year ~8 new servers per year ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 25 LEVELS FILES/REV Perforce servers CURRENT
Key figures – Project & codeline growth USERS SERVERS +11, 6% users last year ~8 new servers per year ~2, 000 new projects last year ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 26 LEVELS FILES/REV CURRENT Perforce projects (2 nd) & codelines (3 rd)
Key figures – File & revision growth USERS SERVERS +11, 6% users last year ~8 new servers per year ~2. 000 new projects last year >10 Mio files added last year ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 27 LEVELS FILES/REV Perforce files & revisions CURRENT
Key figures – Current overview USERS SERVERS +11, 6% users last year ~8 new servers per year ~2. 000 new projects last year >10 Mio files added last year ~27 p 4 calls per second LEVELS FILES/REV CURRENT Current overview n Active Users / Licenses 4, 399 n Server instances 80 n Depots (1 st level) 333 n Projects (2 nd level) 6, 143 n Codelines unique 6, 498 n Codelines overall (3 rd level) n Files n Revisions n Filesystem consumption n Average number of p 4 calls per day ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 28 55, 787 46, 972, 123 116, 482, 290 1. 80 TB 2, 303, 174
Hardware setup n Cluster node 1 & 2: n FSC Prime. Power 450 N – CPU: – Memory: – OS: 4 x 1320 MHz 32 GB Sun. OS 9 n Cluster node 3 & 4: n FSC Prime. Power 650 HA ensured by PRIMECLUSTER – CPU: – Memory: – OS: 8 x 675 MHz 32 GB Sun. OS 9 n Shared Storage (SAN): n 2 x EMC Clariion CX 500 (mirrored) – Size: 3 TB each ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 29
HA Setup Location II Location I Cluster Node 1 Cluster Node 2 Cluster Node 3 Cluster Node 4 2 Fibre Channel SAN switches EMC I Redundant 2 Gbit/s Fibre Channel connections Redundant Gbit/s Ethernet connections ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 30 Mirroring filesystem per service EMC II
Production process (development phase) Dev n Submit changes to ‚dev‘ after local test n nightly build, central deployment to test system and test n Release change for transport to ‚export‘ cons Maturity delivery Export n Collect changes of ‚dev‘ (gate to patch) patch n Transport (copy) content to ‚patch‘ in regular intervals (e. g. weekly cycle) using a timestamp export last call collect, synchronize Patch n Small group of developers is allowed to apply fixes for stabilization n approval by Quality Manager(s) n Transport (copy) content to ‚cons‘ Cons (consolidated code line) n ready to be used by dependent components/products ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 31 develop t
Dependencies – single project ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 32
Java projects dependencies – real life example 79 projects ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 33
Depot/Directory Structure depot project codeline ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 34
Real life example for a change list dependency graph ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 35
Source transports between the code lines Integration n n Manual transport (p 4 integrate) Tools provided by Perforce (p 4. exe, P 4 Win and P 4 V) Ignores dependencies between changes Used to create identical codelines = full copy e. g. initial creation of (remote) maintenance codelines out of development codelines (P 4 MS) Perforce@SAP Consolidation n n Controlled integration Tools developed within SAP based on „p 4 integrate“ Takes dependencies between changes into account Allows bundling of changes – bundle = set of changes that have to be transported together (e. g. c 1 and c 2) n Shows status, user and timestamp of a transport – N (new), P (consolidation in process), E (error), W (waiting for dependent change), C (consolidated) n No multi-server so far ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 36
Perforce SCM Perforce@SAP Demo Q&A
Perforce SCM Perforce@SAP Demo Q&A
Questions? Q&A ã SAP Labs Bulgaria 2006, Perforce@SAP / Vladimir Velinov / 39
0bf139eafbd7faea34469984f9a91084.ppt