The Metadata API allows you to make changes to your Salesforce instance and then deploy those changes through sandboxes to production. There are many tools, both Salesforce-provided or community developed, that allow you to interact with the Metadata API. The API is a fundamental part of release management but actually managing the “change” is what literally makes or breaks an implementation. This webinar focuses on building automation into your release management process using commonly available enterprise tools.
Key Takeaways
:: Learn about the Metadata API and some common API calls
:: Explore the tools built on top of the API
:: Learn how to leverage a version control system manage multiple development streams
:: Build deployment pipelines with automated testing
Intended Audience
:: Force.com Developers / Quality Assurance, Technical Leads, Architects, Application Directors
2. #forcewebinar
Safe Harbor
Safe harbor statement under the Private Securities Litigation Reform Act of 1995:
This presentation may contain forward-looking statements that involve risks, uncertainties, and assumptions. If any such uncertainties materialize or if any of
the assumptions proves incorrect, the results of salesforce.com, inc. could differ materially from the results expressed or implied by the forward-looking
statements we make. All statements other than statements of historical fact could be deemed forward-looking, including any projections of product or service
availability, subscriber growth, earnings, revenues, or other financial items and any statements regarding strategies or plans of management for future
operations, statements of belief, any statements concerning new, planned, or upgraded services or technology developments and customer contracts or use
of our services.
The risks and uncertainties referred to above include – but are not limited to – risks associated with developing and delivering new functionality for our
service, new products and services, our new business model, our past operating losses, possible fluctuations in our operating results and rate of growth,
interruptions or delays in our Web hosting, breach of our security measures, the outcome of intellectual property and other litigation, risks associated with
possible mergers and acquisitions, the immature market in which we operate, our relatively limited operating history, our ability to expand, retain, and
motivate our employees and manage our growth, new releases of our service and successful customer deployment, our limited history reselling non-
salesforce.com products, and utilization and selling to larger enterprise customers. Further information on potential factors that could affect the financial
results of salesforce.com, inc. is included in our annual report on Form 10-Q for the most recent fiscal quarter ended July 31, 2012. This documents and
others containing important disclosures are available on the SEC Filings section of the Investor Information section of our Web site.
Any unreleased services or features referenced in this or other presentations, press releases or public statements are not currently available and may not be
delivered on time or at all. Customers who purchase our services should make the purchase decisions based upon features that are currently available.
Salesforce.com, inc. assumes no obligation and does not intend to update these forward-looking statements.
4. #forcewebinar
Follow Developer Force for the Latest News
@forcedotcom / #forcewebinar
Developer Force – Force.com Community
+Developer Force – Force.com Community
Developer Force
Developer Force Group
5. #forcewebinar
Agenda
§ What is the API?
§ How can I access it?
§ ANT: The what, where and how?
§ Version Control
§ Continuous Integration
§ Build Pipelines
§ New Features
8. #forcewebinar
What is the API?
§ Text-based (XML) version of an org
§ ALL Most tools use the metadata API
– See last slide on the Tooling API!
§ SOAP based and Asynchronous (poll for updates)
§ File and CRUD calls
– File-based = Deploy(), Retrieve()
– CRUD based = more granular
§ Not complete but getting closer on every release!
17. #forcewebinar
Pros
§ Single place for
developers
§ Can easily traverse
metadata files
§ Automatic package.xml
generation
Cons
§ No automation
§ Hard to govern when/what
changes
§ Can become tedious for
repeated deployment retries
§ Does not run tests between
sandboxes
§ Must migrate whole objects
versus individual fields, rules
etc
Force.com IDE (Eclipse)
Summary
Good for smaller teams where the developer and
release manager role are the same person. Useful
for small changes between sandboxes.
18. #forcewebinar
Change Sets
§ When you want to send customizations from your current
organization to another organization, you create an
outbound change set. Once you send the change set, the
receiving organization sees it as an inbound change set.
§ Sending a change set between two organizations requires
a deployment connection.
19. #forcewebinar
Pros
§ Non-developer skillset
§ Simple, declarative
interface
§ Handles dependencies
§ History of migration
maintained in org itself
Cons
§ No automation
§ Does not run tests
between sandboxes
§ Cannot modify change
sets, must create new
§ Does not scale well.
Change Sets
Summary
Smaller orgs with non-developer skillset. More
configuration than code in the org. Migrating single
items (fields) is easier.
20. #forcewebinar
ANT Migration Tool
§ Java/Ant-based command-line utility
§ ANT “tasks” wrap the metadata API calls for ease of use.
Also has pre-built tasks for source control systems
§ Build automation tools can call ANT scripts
§ Three files the are important
– package.xml
– build.xml
– build.properties
21. #forcewebinar
ANT Migration Tool: What?, How?, Where?,
§ package.xml = What to deploy
§ build.xml = How to deploy. Called by ANT to orchestrate
e.g. checkout, deploy
§ build.properties = Where. best practice to use properties
file for variables like username, password, instance
23. #forcewebinar
Pros
§ Can be integrated into
automated test/build
systems
§ Integration to source
control
§ Run tests between
sandboxes
Cons
§ Overhead to setup initially
§ Requires developer skillset
§ Still limited my metadata
API, so still some manual
tasks
ANT Migration Tool
Summary
Enterprises with existing build/release management
infrastructure. Overlap with .net/java/ruby best
practices around automation and continuous
integration
25. #forcewebinar
Source Control
§ AKA version control system, revision control
§ Track changes to SFDC metadata
§ SFDC has no native source control integration (org ->
source control)
§ Most systems allow multiple developers opening the
same file (merge later vs file locks)
§ 2 main flavors
– Centralized (client/server): Subversion, perforce
– Distributed (peer-to-peer): Git, Mecurial
36. #forcewebinar
Faster Deploys to Production (Pilot)
Only Run Specified Tests
Must Cover Code Changes
75% Coverage Per Class
Force.com Migration Tool
37. #forcewebinar
Smart User Matching on Deploy
AFTER
me@myco.com
=
me@myco.com.dev
=
me@myco.com.full
BEFORE
me@myco.com
!=
me@myco.com.dev
!=
me@myco.com.full
38. #forcewebinar
Tooling API
§ The Tooling API is designed for developing user interface
tools to interact with the development artifacts in orgs.
§ It can be accessed via SOAP and ReST
§ Developer Console is largely built on the tooling API
39. #forcewebinar
Summary
§ The API and its characteristics
§ The tools to access it
Crawl Walk Run Fly!
ANT
Source
Control
Continuous
Integration
Continuous
Delivery