logs: add optional limits parameter, default to 50
This commit is contained in:
1 parent
241772baa7
commit
d78bcb87c0
1 file changed
+5
-4
@@ -20,13 +20,14 @@ public class LogsController {
|
||||
|
||||
@RequestMapping(APIServicePaths.GET_LOGS)
|
||||
@ResponseBody
|
||||
String getLogs(@RequestParam("moduleType") String moduleType, @RequestParam("logLevels") String logLevels) {
|
||||
System.out.print(moduleType);
|
||||
System.out.print(logLevels);
|
||||
String getLogs(@RequestParam("moduleType") String moduleType,
|
||||
@RequestParam("logLevels") String logLevels,
|
||||
@RequestParam(required = false, value = "limit") String limit) {
|
||||
|
||||
return restTemplate.getForObject(ModuleServicePaths.GET_LOGS
|
||||
.concat("?moduleType=").concat(moduleType)
|
||||
.concat("&logLevels=").concat(logLevels),
|
||||
.concat("&logLevels=").concat(logLevels)
|
||||
.concat("&limit=").concat(limit != null ? limit : "50"),
|
||||
String.class
|
||||
);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user