forked from halo-dev/halo
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Dev Co-authored-by: John Niang <[email protected]>
- Loading branch information
Showing
28 changed files
with
420 additions
and
76 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
34 changes: 34 additions & 0 deletions
34
src/main/java/run/halo/app/controller/admin/api/TraceController.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
package run.halo.app.controller.admin.api; | ||
|
||
import io.swagger.annotations.ApiOperation; | ||
import org.springframework.boot.actuate.trace.http.HttpTrace; | ||
import org.springframework.web.bind.annotation.GetMapping; | ||
import org.springframework.web.bind.annotation.RequestMapping; | ||
import org.springframework.web.bind.annotation.RestController; | ||
import run.halo.app.service.TraceService; | ||
|
||
import java.util.List; | ||
|
||
/** | ||
* Trace controller. | ||
* | ||
* @author johnniang | ||
* @date 19-6-18 | ||
*/ | ||
@RestController | ||
@RequestMapping("/api/admin/traces") | ||
public class TraceController { | ||
|
||
private final TraceService traceService; | ||
|
||
public TraceController(TraceService traceService) { | ||
this.traceService = traceService; | ||
} | ||
|
||
@GetMapping | ||
@ApiOperation("Lists http traces") | ||
public List<HttpTrace> listHttpTraces() { | ||
return traceService.listHttpTraces(); | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
package run.halo.app.model.dto; | ||
|
||
import lombok.Data; | ||
import lombok.EqualsAndHashCode; | ||
import lombok.ToString; | ||
|
||
import java.util.Date; | ||
|
||
/** | ||
* Http trace dto. | ||
* | ||
* @author johnniang | ||
* @date 19-6-18 | ||
*/ | ||
@Data | ||
@ToString | ||
@EqualsAndHashCode | ||
public class HttpTraceDTO { | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.