Protobuf's LUA version

Source: Internet
Author: User

Recommended a protobuf LUA version of the previous Project client Lua, communication protocol is PROTOBUF, with NetEase Proto-gen-lua, the use of the process encountered some problems need to be around, such as:
1, each change, add proto to generate new files, code scale explosion
2, because Lua itself, each file maximum file within the global local variable can not exceed 200, so when the proto scale is too large, the generated
Lua files are not available, you need to split the proto
3, I do Proto-gen-lua integration, as if the use of protobuf2.5, forced to use only 2.4, and then proto in the message
Format support is not complete, such as the message contains other message is not possible, but only to include the message definition to write
Inside the message

Recent new projects, want to study the next protobuf dynamic analysis, so on GitHub found this project:
Https://github.com/zhanjunxiong/luapb

Project in the first integration of PROTOBUF, and then put this LUAPB CPP file also added, LUAPB this project Singleton.h is not a cross-flat
, you can modify the code for a single example, and then you can use the

These days of frustrating time encountered some bugs, to the author after the author quickly repaired, specific usage, you can refer to the project Test example, can also go to
Issue list to see:
Https://github.com/zhanjunxiong/luapb/issues/2

Protobuf's LUA version

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.