본문 바로가기

RPC

[Play Framework] Json RPC Client구현하기 Json-RPC로 사용할 라이브러리는 jsonrpc4j 이다. 자세한 사항은 여기로~! 이전 게시글과 연동하여 사용할 것이다. Spring Framework로 구현한 Json RPC Server를 참고!! 1. 라이브러리 추가하자 com.github.briandilley.jsonrpc4j jsonrpc4j 1.0 com.fasterxml.jackson.core jackson-core 2.0.2 com.fasterxml.jackson.core jackson-databind 2.0.2 com.fasterxml.jackson.core jackson-annotations 2.0.2 2. Serve에서 구현된 Model과 Service를 사용하므로 파일을 추가하자~! 3. RPC 테스트 클래스 생성 코드를 보면 .. 더보기
[Spring Framework] Json RPC Server 구현하기 Json-RPC로 사용할 라이브러리는 jsonrpc4j 이다. 자세한 사항은 여기로~! 이제 시작해보자~! 1. 우선은 라이브러리를 추가하자~! com.github.briandilley.jsonrpc4j jsonrpc4j 1.0 com.fasterxml.jackson.core jackson-core 2.0.2 com.fasterxml.jackson.core jackson-databind 2.0.2 com.fasterxml.jackson.core jackson-annotations 2.0.2 위에 보면 jackson을 쓴다. 이미 사용하기 떄문에 jsonrpc4j 라이브러리만 추가~! 2. Service 설정 자 기존에 구현된 Service에서 @JsonRpcService 애노테이션을 사용하자~! 그럼 설.. 더보기
[Protocol] Json RPC란... - Remote procedure call protocol을 Json으로 간단히 표현한 것이다. (XML-RPC와 유사하다.) Data type과 command로 구성되어 있고 알람(요청만하고 서버에 결과값을 받지 않는 것)과 다중 호출이 가능하다. (이전에 호출한 것에대해 상관없이?) JSON-RPC is a remote procedure call protocol encoded in JSON. It is a very simple protocol (and very similar to XML-RPC), defining only a handful of data types and commands. JSON-RPC allows for notifications (data sent to the server that.. 더보기