Skip to content

Commit

Permalink
fix(dataType): change return type of build output from string to map (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
gal-yardeni committed Dec 1, 2020
1 parent b0cd43f commit 6e07056
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@

import com.netflix.spinnaker.igor.build.model.GenericBuild;
import java.util.List;
import java.util.Map;

/**
* Interface to be implemented by ci build service providers that supports a way of getting builds
Expand Down Expand Up @@ -48,8 +49,8 @@ List<GenericBuild> getBuilds(
* Get the build log by providing the build id. The data returned will be used in the CI view, to
* present the build's log.
*
* @param buildId
* @return a string represent the build log
* @param buildId the build id
* @return a map with key "log" which represent the build log
*/
String getBuildOutput(String buildId);
Map<String, Object> getBuildOutput(String buildId);
}
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@

import com.netflix.spinnaker.igor.build.model.GenericBuild;
import java.util.List;
import java.util.Map;
import java.util.Optional;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
Expand Down Expand Up @@ -50,7 +51,7 @@ public List<GenericBuild> getBuilds(
}

@GetMapping("/builds/{buildId}/output")
public String getBuildOutput(@PathVariable(value = "buildId") String buildId) {
public Map<String, Object> getBuildOutput(@PathVariable(value = "buildId") String buildId) {
return getCiService().getBuildOutput(buildId);
}

Expand Down

0 comments on commit 6e07056

Please sign in to comment.