GithubHelp home page GithubHelp logo

powerman / perl-json-rpc2 Goto Github PK

View Code? Open in Web Editor NEW
3.0 3.0 2.0 102 KB

Perl module: JSON::RPC2 - Transport-independent implementation of JSON-RPC 2.0

Home Page: https://metacpan.org/release/JSON-RPC2

License: Other

Perl 99.76% Raku 0.24%

perl-json-rpc2's People

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

sjmiller valitnon

perl-json-rpc2's Issues

. removed from @INC

In perl 5.26 the dot is removed from @INC, causing the tests to fail:

Can't locate t/share.pm in @INC (you may need to install the t::share module) (@INC contains: /home/cpansand/.cpan/build/2017051300/JSON-RPC2-v2.1.1-0/blib/arch /home/cpansand/.cpan/build/2017051300/JSON-RPC2-v2.1.1-0/blib/lib /opt/perl-5.26.0-RC1/lib/site_perl/5.26.0/x86_64-linux /opt/perl-5.26.0-RC1/lib/site_perl/5.26.0 /opt/perl-5.26.0-RC1/lib/5.26.0/x86_64-linux /opt/perl-5.26.0-RC1/lib/5.26.0) at t/client-batch.t line 3.
BEGIN failed--compilation aborted at t/client-batch.t line 3.
t/client-batch.t ........... 
Dubious, test returned 2 (wstat 512, 0x200)
No subtests run 
... (etc.) ...

A possible fix: add something like use lib "."; to the top of the failing scripts.

[Question] How to handle events?

Hi,

some JSON RPC servers have something like an event model. You can subscribe to certain events and when something occurs you're sent an event object. The "id" of the object is always "NULL" and the type is always "event". I'm actually using this together with WebSockets... (AnyEvent::WebSocket::Client).

Looking at the source of the response() sub, I can see that an "id" of value "NULL" is always sorted out. Is there an event handling that I just cannot see, or is it just not implemented?

Don't get me wrong here, I'm fine if it's not implemented, I'm just asking before reinventing the wheel.

KR,

G.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.