Bitbucket Server data integration

CloudBees Engineering Efficiency stores Bitbucket Server information in the System of Record for each instance that has installed the plugin. This page explains how the service works, API REST calls used with the servers, and details about data sent from the Bitbucket Server plugin.

What data is stored

CloudBees Engineering Efficiency stores the following Bitbucket Server information in the System of Record for each instance that has installed the plugin:

  • Account - The CloudBees organization linked with this Bitbucket Server

  • Refresh token - A security token obtained from the Bitbucket Server App in CloudBees Engineering Efficiency

  • Server ID - The unique identifier for the Bitbucket Server

  • Base URL - The root URL for the Bitbucket Server

How the service works

The customer installs a Bitbucket Server plugin developed by CloudBees into their Bitbucket Server instance. Once installed, this plugin runs a sync operation to send CloudBees Engineering Efficiency data from the Bitbucket Server instance, then sends updates as data is created, updated, and deleted. The sync operation also repeats periodically and resends all data created or updated since the last sync.

The app sends data that includes the following:

  • Repositories

  • Branches

  • Commits

  • PullRequests

  • PullRequestParticipant

  • PullRequestActivity

  • User

User information is removed from the above entities on ingestion and stored separately in the System of Record.

The data is sent to the CloudBees Engineering Efficiency backend service via the REST API. This service handles authentication and is responsible for verifying your Bitbucket Server installation as a source of data updates. The backend receives and stores your data where it can be retrieved and used by the System of Record GraphQL for your applications.

Data syncs between Bitbucket Server and System of Record

After the CloudBees Software Delivery Management plugin is installed for Bitbucket Server and a new Bitbucket Server integration is created, an installation scan is started simultaneously. This begins fetching data entities from the Bitbucket Server, including data for Repositories, Branches, and Pull Requests (up to 1 year old) associated with those entities.

There’s no rate limiting for Bitbucket Server instances. These scans retrieve and publish the data to the CloudBees Engineering Efficiency service until all the data has been retrieved and published. For large organizations, this can take a few hours.

Periodically, scans are run to retrieve all of the projects, repositories, branches, and pull request data.

Once an integration has been set up, the CloudBees Software Delivery Management plugin begins triggering webhook events to CloudBees Engineering Efficiency any time a Repository, Branch or Pull Request is created, updated, or deleted. These webhook events are processed directly and do not result in subsequent API calls back to Bitbucket Server from CloudBees Engineering Efficiency.

Connecting Bitbucket Server to CloudBees Engineering Efficiency

Integration with Bitbucket Server is provided through the CloudBees Software Delivery Management plugin. After installing the plugin on your Bitbucket Server, it will establish a push-based connection that sends the latest Bitbucket changes to CloudBees Engineering Efficiency after an initial push of existing data.

Bitbucket Server App REST APIs

The Bitbucket plugin publishes data to app.cloudbees.com using a REST API. Invocations of the REST API are executed over HTTPS and authenticated using a security token that is associated with the Bitbucket Server during setup.

EndpointMethodParams / Request BodyDescription

Data sent from the Bitbucket Server plugin

The following data is synchronized to the CloudBees Engineering Efficiency SaaS on an on-going basis and stored in the CloudBees Engineering Efficiency data store, the System of Record.

Bitbucket Server

CloudBees Engineering Efficiency stores the following data from the Bitbucket integration:

  • Repository

  • Branch

  • Commit

  • PullRequest

  • PullRequestParticipant

  • PullRequestActivity

  • User

This includes (embedded in the above objects) the following personally identifiable information:

  • User, but only the following fields:

    • Name (public profile name, for example, Brenda Wilson)

    • Login (Bitbucket username, for example, bwilson834)

    • Url (URL for the user profile, for example, https://bitbucket.example.com/admin/users/view?name=bwilson834)

    • Email (for example, bwilson@cloudbees.com)