xeden3 / LECPServer

LECPServer(Leanboard Equipment Communication Proxy Server), It is a high-performance industrial connectivity platform developed based on the JLean framework. It solves communications challenges with industrial devices and applications, with streamlined data through a single communications platform
222 stars 45 forks source link

[Question] 为什么Release里面的bs.zip是加密的? #2

Closed tiaod closed 3 years ago

tiaod commented 3 years ago

如果基于jlean开发,那么如果想在本地监听http请求,不是要调用JsProxyAPI.webAPIStart()这个接口吗?为什么源码里面没有处理http请求的相关代码?请问作者是jlean的员工吗?我翻遍了文档没有找到相关信息,问题比较多,有点像采访,希望作者不要介意 :smile:

xeden3 commented 3 years ago

bs.zip是加密的是方便打包而已,JLean专业用户是支持加密打包的功能,如果你不希望zip加密,可以直接在Github项目里面bs文件夹复制到LECPServer目录下,也是可以运行的。

xeden3 commented 3 years ago

抱歉,最近比较忙,回复较晚

http的监听是使用了webAPIStart接口,源码有处理http监听请求的代码,在main.js


    let r = JsProxyAPI.webAPIStart(端口号,
        function (success, handler) {
            console.log(success, handler);
        },
        function (msg) {
           // 这部分开始就是监听内容了
            console.log(msg);
            // 将msg转为json结构
            ......
xeden3 commented 3 years ago

JLean是我们公司其中一个项目,我们公司主营是做MES的,JLean和LECPServer均是派生项目,因此拿来做开源和社区化,希望更多的朋友得到便利。

tiaod commented 3 years ago

明白了,我那天是直接在repo里搜索webAPIStart这个关键字,没找到结果,让我困惑了很久。 刚刚翻了下global/main.js里面看到了相关代码,十分感谢你的耐心解答!