Giter VIP home page Giter VIP logo

hprose-dart's Introduction

HPROSE is short for High Performance Remote Object Service Engine.

It is a modern, lightweight, cross-language, cross-platform, object-oriented, high performance, remote dynamic communication middleware. It is not only easy to use, but powerful. You just need a little time to learn, then you can use it to easily construct cross language cross platform distributed application system.

It contains a semi-text serialization format, an RPC protocol and its implementation. The meaning of semi-text is all the data are represented as text, except the original binary data. The serialization format is very compact. It takes up very little space, and can be parsed very quickly in programming language. You can use this serialization format without hprose RPC protocol in other communications protocols, data storage, and more. If you want to know more, please read Hprose Specification.

Join the chat at https://gitter.im/hprose/hprose

hprose-dart's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

hprose-dart's Issues

callback of prosumer.subscribe dont work

i use the demo code on a flutter demo to test push
await prosumer1.subscribe('test', (message) {
print('112233');
print(message);
print(message.toJson());
});
final r1 = prosumer2.push('hello', 'test');

but i view the log only get these
I/flutter (13244): Hm1{s2"id"u1}Cu+a1{s4"test"}z
I/flutter (13244): Rtz
I/flutter (13244): Hm1{s2"id"u1}Cu<z
I/flutter (13244): Hm1{s2"id"u2}Cs2">*"a2{s5"hello"s4"test"}z
I/flutter (13244): Rm1{s4"test"a1{c1"@"2{s4"data"s4"from"}o0{s5"hello"u2}}}z
I/flutter (13244): Rm1{u1t}z
I/flutter (13244): the result of push [{1: true}]
I/flutter (13244): Hm1{s2"id"u1}Cu<z
I/flutter (13244): Hm1{s2"id"u1}Cu-a1{s4"test"}z
I/flutter (13244): Rnz
I/flutter (13244): Rtz

dont get my log "112233"

hope for answer

How to use hprose-dart in google app engine env ?

hi,
I'm using Dart in Google app engine (via: https://pub.dev/packages/appengine).

When the code in my server.dart is looks like this

import 'dart:io';
import 'package:appengine/appengine.dart';
import 'package:hprose/rpc.dart';

requestHandler(HttpRequest request) {
  if (request.uri.path == "/rpc") {

    // HProse server code here 
    var service = new Service();
    service.addMethod(hello);

    //TODO:   how?
      service.bind( ???? )
      ...

  } else {
    request.response
      ..write('server ok')
      ..close();
  }
}

String hello(String name) {
  return 'hello $name';
}

main() async {
  await runAppEngine(requestHandler);
}

but I don't know how to bind the hprose handler within it's Method requestHandler(HttpRequest request)

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.