Commit 319ac0e4 by 111-PC\111

[+]pulsar消费服务

1 parent 09604223
package cn.com.glsx.consumer; package cn.com.glsx.consumer;
import cn.com.glsx.consumer.service.InfoService;
import com.alibaba.nacos.common.utils.MD5Utils; import com.alibaba.nacos.common.utils.MD5Utils;
import lombok.extern.slf4j.Slf4j; import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller; import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMapping;
/** /**
...@@ -14,6 +17,13 @@ import org.springframework.web.bind.annotation.RequestMapping; ...@@ -14,6 +17,13 @@ import org.springframework.web.bind.annotation.RequestMapping;
@Slf4j @Slf4j
public class TestController { public class TestController {
@Autowired
private InfoService infoService;
@RequestMapping("/test")
public void test(@RequestBody String data){
infoService.processMessage(data);
}
public static void main(String[] args) { public static void main(String[] args) {
System.out.println(MD5Utils.md5Hex("13476670746","utf-8")); System.out.println(MD5Utils.md5Hex("13476670746","utf-8"));
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!