diff --git a/src/main/java/cokr/xit/interfaces/smg/service/bean/SmgReceiverBean.java b/src/main/java/cokr/xit/interfaces/smg/service/bean/SmgReceiverBean.java index 9006607..1d9d922 100644 --- a/src/main/java/cokr/xit/interfaces/smg/service/bean/SmgReceiverBean.java +++ b/src/main/java/cokr/xit/interfaces/smg/service/bean/SmgReceiverBean.java @@ -149,8 +149,8 @@ public class SmgReceiverBean extends FileJobBean { new WebClient().post(req -> req.uri(alert) - .data("interfaceSequences", interfaceSequences) - .json(true) + .contentType(WebClient.Request.ContentType.JSON) + .bodyData(interfaceSequences) .async(true) ); } diff --git a/src/main/java/cokr/xit/interfaces/smg/service/bean/SmgSenderBean.java b/src/main/java/cokr/xit/interfaces/smg/service/bean/SmgSenderBean.java index 610e9b3..0db042a 100644 --- a/src/main/java/cokr/xit/interfaces/smg/service/bean/SmgSenderBean.java +++ b/src/main/java/cokr/xit/interfaces/smg/service/bean/SmgSenderBean.java @@ -161,10 +161,10 @@ public class SmgSenderBean extends FileJobBean { new WebClient().post(req -> req.uri(alert) - .data("success", success) - .data("fail", fail) - .json(true) - .async(true) + .contentType(WebClient.Request.ContentType.JSON) + .data("success", success) + .data("fail", fail) + .async(true) ); } } \ No newline at end of file diff --git a/src/main/java/cokr/xit/interfaces/smg/web/SmgController.java b/src/main/java/cokr/xit/interfaces/smg/web/SmgController.java index 702b92f..b3477e3 100644 --- a/src/main/java/cokr/xit/interfaces/smg/web/SmgController.java +++ b/src/main/java/cokr/xit/interfaces/smg/web/SmgController.java @@ -32,8 +32,7 @@ public class SmgController extends AbstractController { * */ @PostMapping(value = "/petition/receive.do", name = "국민 신문고 민원 수신") - public ModelAndView receivePetitions(@RequestBody Map result) { - List interfaceSequences = (List)result.get("interfaceSequences"); + public ModelAndView receivePetitions(@RequestBody List interfaceSequences) { boolean empty = isEmpty(interfaceSequences); log().debug("interfaceSequences received: {}", empty ? "none" : String.join(", ", interfaceSequences));