This commit is contained in:
Redkale
2017-11-15 11:00:08 +08:00
parent 7c5ac7970e
commit 945f9f9ef5
6 changed files with 22 additions and 9 deletions

View File

@@ -94,6 +94,7 @@ public class SncpTest {
SncpTestBean callbean = new SncpTestBean();
callbean.setId(1);
callbean.setContent("数据X");
service.queryLongResult("f", 3,33L);
service.insert(callbean);
System.out.println("bean.id应该会被修改(id不会是1) " + callbean);

View File

@@ -17,8 +17,10 @@ public interface SncpTestIService extends Service {
public String queryResult(SncpTestBean bean);
public long queryLongResult(String a, int b, long value);
public CompletableFuture<String> queryResultAsync(SncpTestBean bean);
public void insert(@RpcCall(DataCallArrayAttribute.class) SncpTestBean... beans);
public String updateBean(@RpcCall(SncpTestServiceImpl.CallAttribute.class) SncpTestBean bean);

View File

@@ -41,6 +41,12 @@ public class SncpTestServiceImpl implements SncpTestIService {
}
@Override
@RpcMultiRun
public long queryLongResult(String a, int b, long value) {
return value + 1;
}
public static class CallAttribute implements Attribute<SncpTestBean, Long> {
@Override