CodePudding user response:
1, pom. XML2, XxxServiceImpl. Java
@ Path (" hi ")
@ Consumes (" application/json ")
@ Produces (" application/json; Charset=utf-8 ")
@ Service
Public class XxxServiceImpl implements XxxService {
@ GET
@ Path (" getAbc ")
@ Override
Public ServiceResponseDTO
return null;
}
}
3, the service. The XML
4, with the postman test request
http://ip:port/hi/getAbc? Id=12345
CodePudding user response:
0, application. The properties,,,,,,,
Dubbo. Separate protocols. Rest. Name=rest
Dubbo. Separate protocols. Rest. Id=rest
Dubbo. Separate protocols. Rest. Port=8888
Dubbo. Separate protocols. Dubbo. Name=dubbo
Dubbo. Separate protocols. Dubbo. Id=dubbo
Dubbo. Separate protocols. Dubbo. Port=9999
.