【发布时间】:2018-05-22 15:39:28
【问题描述】:
想看看能不能暴露 卷曲http://localhost:9090/studentinfo?schoolId=12341324, 其中“studentinfo”是服务路径。
@http:ServiceConfig { basePath: "/studentinfo" }
service<http:Service> studentInfo bind studentInfoListener {
@http:ResourceConfig {
methods: ["GET"],
path: "?"
}
getStudentBySearch(endpoint client, http:Request req) {
http:Response response;
var params = req.getQueryParams();
var schoolId = <string>params.schoolId;
var addmissionYear = <string>params.addmissionYear;
...
}
...
}
【问题讨论】:
标签: ballerina