Updated the codecs used with latest changes [CTT-713]#1336
Conversation
…o use these codecs properly with the new introduced parameters. Associated protocol PR is hazelcast/hazelcast-client-protocol#557
Could you try to keep the PRs separate, if possible, please? I.E. are these changes only the autogenerated output of hazelcast/hazelcast-client-protocol#557? or are there additional changes as well? |
No, they are related and needed. I can not separate them. |
Ok, I've tried splitting it (locally to understand it) but I think there's a problem - the generated You can see my working in this branch. |
I generate and format the code. Is the problem about formatting(clang format) difference or do you see other differences? |
Co-authored-by: Jack Green <JackPGreen@Gmail.com>
JackPGreen
left a comment
There was a problem hiding this comment.
I generate and format the code. Is the problem about formatting(clang format) {...}?
I think this makes it very challenging to review - if it's generated code, as long as I'm happy with the generator configuration (i.e. hazelcast/hazelcast-client-protocol#557) and I can validate the code is generated as it should be, I can simply rubber-stamp it.
In this scenario, I can't validate the code is generated as it should be, so instead I need to review the generator configuration and review the generated code as well.
I tried to update the client-protocol template formatting in https://github.com/JackPGreen/hazelcast-client-protocol/tree/clang-formatting to see if I could produce the output heree "out-of-the-box" but it's not (easily) possible as the formatter is line breaking in different positions due to the line length (i.e. a parameter may be declared on the same line as a function or a newline depending on the name of the method - which isn't easy to implement in a template).
I think it would be better simply to leave the formatting of the generated code as-is.
do you see other differences?
I don't think so.
We can integrate |
🤦 Good point - it's much simpler to actually use the formatter than to try to approximate it. |
Sent the PR for this hazelcast/hazelcast-client-protocol#558 |
The format produced by the generator does not match the style of the codebase, making validation tricky - see hazelcast/hazelcast-cpp-client#1336 Instead, the generator should format the code it produces (using the same formatter as used the C++ client) _as it's produced_.
Updated the codecs used with latest changes. Also, updated the code to use these codecs properly with the new introduced parameters.
Associated protocol PR is hazelcast/hazelcast-client-protocol#557