public interface PluginBuildServerProvider
Provides the ability for a plugin to be a "build server provider"; that is a plugin that provides the ability to access and manage build jobs on a build/automation server.
Modifier and Type | Method and Description |
---|---|
Optional<PluginBuildServer> |
getBuildServer(javax.servlet.http.HttpServletRequest servletRequest,
Map<String,Object> requestBody)
Given a request, identify the build server that made the request.
|
Optional<PluginBuildServer> |
getBuildServer(String id)
Get the
PluginBuildServer for the given ID. |
Optional<PluginBuildServer> getBuildServer(@Nonnull String id)
PluginBuildServer
for the given ID.id
- the ID of the build server to getPluginBuildServer
, or Optional.empty()
if there is no build server for the
given ID@Nonnull Optional<PluginBuildServer> getBuildServer(@Nonnull javax.servlet.http.HttpServletRequest servletRequest, @Nonnull Map<String,Object> requestBody)
This is used to establish the concept of a trusted build status. A build status must be verified/trusted for the purposes of certain functions such as:
Optional.empty()
.servletRequest
- the request for which the requester will be determinedrequestBody
- a map of all fields included in the build status request, fields of this map can be
used to verify the build serverOptional
containing the build server if the request can be validated as certainly originating
from that build server. If the request cannot be validated as coming from a known/trusted build server this
provider is responsible for, then Optional.empty()
is returned.Copyright © 2024 Atlassian. All rights reserved.