34 lines
1.1 KiB
Java
34 lines
1.1 KiB
Java
package com.myoa.engineering.crawl.ppomppu.receiver.controller.v1;
|
|
|
|
import org.springframework.web.bind.annotation.PathVariable;
|
|
import org.springframework.web.bind.annotation.PostMapping;
|
|
import org.springframework.web.bind.annotation.RequestMapping;
|
|
import org.springframework.web.bind.annotation.RestController;
|
|
|
|
import com.myoa.engineering.crawl.ppomppu.receiver.service.ProcessorAPIService;
|
|
import com.myoa.engineering.crawl.ppomppu.support.dto.code.PpomppuBoardName;
|
|
|
|
import reactor.core.publisher.Mono;
|
|
|
|
/**
|
|
* EventAPIController
|
|
* @author Shin Woo-jin (woo-jin.shin@linecorp.com)
|
|
* @since 2021-09-05
|
|
*
|
|
*/
|
|
@RestController
|
|
@RequestMapping("/api/v1/")
|
|
public class EventAPIController {
|
|
|
|
private final ProcessorAPIService processorAPIService;
|
|
|
|
public EventAPIController(ProcessorAPIService processorAPIService) {
|
|
this.processorAPIService = processorAPIService;
|
|
}
|
|
|
|
@PostMapping("/exploit/parsePpomppuRSS/{boardName}")
|
|
public Mono<String> parsePpomppuRSS(@PathVariable("boardName") PpomppuBoardName boardName) {
|
|
return processorAPIService.emitParseEvent(boardName);
|
|
}
|
|
}
|