Class BitbucketClientFactoryImpl
java.lang.Object
com.atlassian.bitbucket.jenkins.internal.client.BitbucketClientFactoryImpl
- All Implemented Interfaces:
BitbucketClientFactory
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final longCache duration for the capabilities response. -
Method Summary
Modifier and TypeMethodDescriptionReturn a client that can return the username for the credentials used.Construct a client that can retrieve the advertised capabilities from Bitbucket.getMirroredRepositoriesClient(int repositoryId) Construct a client that can retrieve the list of mirrored repositories for a givenrepoIdfrom Bitbucket.getProjectClient(String projectKey) Return a project client.getSearchClient(String projectName) Return a search client
-
Field Details
-
CAPABILITIES_CACHE_DURATION
public static final long CAPABILITIES_CACHE_DURATIONCache duration for the capabilities response. Defaults to 1 hour in ms.
-
-
Method Details
-
getAuthenticatedUserClient
Description copied from interface:BitbucketClientFactoryReturn a client that can return the username for the credentials used.- Specified by:
getAuthenticatedUserClientin interfaceBitbucketClientFactory- Returns:
- a client that is ready to use
-
getCapabilityClient
Description copied from interface:BitbucketClientFactoryConstruct a client that can retrieve the advertised capabilities from Bitbucket. The client is thread safe and can be used multiple times.- Specified by:
getCapabilityClientin interfaceBitbucketClientFactory- Returns:
- a client that is ready to use
-
getMirroredRepositoriesClient
Description copied from interface:BitbucketClientFactoryConstruct a client that can retrieve the list of mirrored repositories for a givenrepoIdfrom Bitbucket.- Specified by:
getMirroredRepositoriesClientin interfaceBitbucketClientFactory- Parameters:
repositoryId- the repositoryId- Returns:
- a client that is ready to use
-
getProjectClient
Description copied from interface:BitbucketClientFactoryReturn a project client.- Specified by:
getProjectClientin interfaceBitbucketClientFactory- Returns:
- a client that is ready to use
-
getSearchClient
Description copied from interface:BitbucketClientFactoryReturn a search client- Specified by:
getSearchClientin interfaceBitbucketClientFactory- Parameters:
projectName- the project name to search for- Returns:
- a client that is ready to use
-