Giter Site home page Giter Site logo

Comments (2)

arobenko avatar arobenko commented on July 19, 2024

Hi @TimonTerBraak,
There are no built-in means to easily handle protocols like yours in the CommsChampion Ecosystem. I think performance wise it's better for you to pre- and post-process the payload by removing / adding escape characters, just like you do now. Such code is quite simple both to write and quick compile.

However, it is possible to implement such pre- and post-processing using the means of the CommsChampion Ecosystem, but it will take more effort to implement it and due to usage of the templates the compilation will take longer. The implementation will require splitting your protocol into two separate ones, one to handle the framing and escaping, and the second one to handle a payload to determine actual messages. So, it will still require two passes on the data anyway. With the currently available feature set you will probably have to use custom code injection. Maybe in the future I will implement extra features to the CommsDSL spec, commsdsl code generates, and COMMS library which will eliminate the necessity to inject custom code for such case, bit it won't happen within the next couple of months and it won't eliminate two passes on the data.

Please let me know if you want me to advice on the details on how to implement such two passes using the CommsChampion Ecosystem.

from commsdsl.

TimonTerBraak avatar TimonTerBraak commented on July 19, 2024

Thanks for the quick feedback. Then I'll stick to my current implementation. The advantage of doing this in the COMMS part is the decoupling of the application logic, improving the reusability of this functionality for other protocol.

from commsdsl.

Related Issues (20)

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.