Merge "Allow ExternalIncludedIn extensions to add multiple Included In rows"

*submodules:
* Update plugins/cookbook-plugin from branch 'master'
  - Add example implementation of ExternalIncludedIn extension point
    
    Change-Id: Ied5517cf9da58c748ad60bdf96444828a6051df3
    Signed-off-by: Edwin Kempin <ekempin@google.com>
This commit is contained in:
Edwin Kempin
2016-08-05 15:14:28 +00:00
committed by Gerrit Code Review
6 changed files with 23 additions and 17 deletions

View File

@@ -27,6 +27,7 @@ java_library(
name = 'lib',
exported_deps = [
':api',
'//lib:guava',
'//lib/guice:guice',
'//lib/guice:guice-assistedinject',
'//lib/guice:guice-servlet',
@@ -42,6 +43,7 @@ java_library(
'//gerrit-common:annotations',
],
provided_deps = [
'//lib:guava',
'//lib/guice:guice',
'//lib/guice:guice-assistedinject',
],

View File

@@ -23,6 +23,7 @@ java_library(
name = 'lib',
exports = [
':api',
'//lib:guava',
'//lib/guice:guice',
'//lib/guice:guice-assistedinject',
'//lib/guice:guice-servlet',
@@ -37,6 +38,7 @@ java_library(
srcs = glob([SRC + '**/*.java']),
deps = [
'//gerrit-common:annotations',
'//lib:guava',
'//lib/guice:guice',
'//lib/guice:guice-assistedinject',
],

View File

@@ -14,16 +14,18 @@
package com.google.gerrit.extensions.config;
import com.google.common.collect.Multimap;
import com.google.gerrit.extensions.annotations.ExtensionPoint;
import java.util.Collection;
import java.util.List;
@ExtensionPoint
public interface ExternalIncludedIn {
/**
* Returns a list of systems that include the given commit.
* Returns additional entries for IncludedInInfo as multimap where the
* key is the row title and the the values are a list of systems that include
* the given commit (e.g. names of servers on which this commit is deployed).
*
* The tags and branches in which the commit is included are provided so that
* a RevWalk can be avoided when a system runs a certain tag or branch.
@@ -33,9 +35,8 @@ public interface ExternalIncludedIn {
* included
* @param tags the tags that include the commit
* @param branches the branches that include the commit
* @return a list of systems that contain the given commit, e.g. names of
* servers on which this commit is deployed
* @return additional entries for IncludedInInfo
*/
List<String> getIncludedIn(String project, String commit,
Multimap<String, String> getIncludedIn(String project, String commit,
Collection<String> tags, Collection<String> branches);
}