Skip to content
This repository has been archived by the owner on Jan 31, 2022. It is now read-only.

Merge templated RPC migration into develop #176

Merged
merged 44 commits into from
Mar 31, 2020

Conversation

lpetre-ulb
Copy link
Contributor

Description

Following what was done in xHAL and as described in #172, this PR aims at making develop the main development branch.

The only active development is around the templated RPC, but the target branch is different between different repositories (develop in xhal and cmsgemos, but feature/templated-rpc in this repository). It is somehow confusing.

The develop branch of cmsgemos is going to start using the templated RPC framework, so it makes sense to include the templated RPC functionalities into develop.

Moreover, some of the latest clean up PR would be target develop rather than feature/templated-rpc-methods, but are (going to be) merged into feature/templated-rpc-methods to avoid any divergences.

Since fast forward merge is better done from the command line (committers are preserved), I'm going to push the change this evening if there is no strong opposition.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Motivation and Context

The templated RPC are the present of the CTP7 modules.

lpetre-ulb and others added 30 commits December 5, 2019 20:33
* change `NULL` to `nullptr`
* remove some seemingly unnecessary `#include`s
* Added placeholders for several needed serialize methods
  * serializers for 8 and 16 bit unsigned types
  * serializers for float using simple `reinterpret_cast` **may not work**
* Remove `GETLOCALARGS` macro
* Cleanup `#include` directives
* Cleanup doxy comment styles
* Clean style for braces and `struct` names
* Doesn't compile because not all submodules have been migrated
* doesn't compile because not all `amc` submodules have been migrated
* doesn't compile because not all `amc` submodules have been migrated
* doesn't compile because not all `amc` submodules have been migrated
* update structs for enuns to strongly typed enum struct
* remove vestigial stdsprintf
* cleanup commented includes
* add spec.template and put packageinfo in correct location
* correction of types, serializer for `size_t`
* Update config submodule and use `https` instead of `ssh`
* Add gitlab-ci config
* Update gitignore
mexanick and others added 12 commits February 3, 2020 16:21
[feature] templated RPC + package structure
utils::regExists closes the LMDB when it exits. Whenever the db_res was
used, it was referring to a dangling pointer to a (non-existent)
memory-mapped address.

utils::regExists has been modified to return the content of the LMDB key
as a std::string if it exists, avoiding the previsouly described issue.

During the adaptation of utils::writeRawAddress, utils::readRawAddress,
utils utils::writeRawReg, utils::readRawReg, utils::writeReg and
utils::readReg, the following internal functions have been removed:

* utils::writeAddress
* utils::readAddress

Basic const-ification has been applied on the way.
* Update the config submodule to the latest commit in feature/common-ci
* Disable the x86_64 build while the GLIB sysroot is not ready
int is not a (de)serializable type by default. Since the signed behavior
is not needed, just remove it with the unsigned version.
Replacing it with a std::vector<std::string>
…ted-rpc

Minimal working version of the templated RPC methods
@jsturdy
Copy link
Contributor

jsturdy commented Mar 30, 2020

Historically, for all merges done via PR/MR (except for those in throwaway branches, e.g., what was supposed to be the "short-term" legacy code) should have a merge commit to mark the PR/MR through which the merge happened (history and automatic changelog are two of many reasons to do this).
As a corollary, no other PR/MRs should appear in the "central" tree, i.e., if people do PR/MRs between their developments (which has been discouraged, but has still happened), those should be squash, fast-forward, rebase, whatever, but without a merge commit

@lpetre-ulb
Copy link
Contributor Author

Historically, for all merges done via PR/MR (except for those in throwaway branches, e.g., what was supposed to be the "short-term" legacy code) should have a merge commit to mark the PR/MR through which the merge happened (history and automatic changelog are two of many reasons to do this).

It makes a lot sense for regular PR/MR. Does it also make so much sense for central branches merges? Particularly in this case where the development was stalled in develop and only occured in feature/templated-rpc-methods? I don't have a strong opinion about it. This PR can be merged as-is if you prefer.

However, that rule has been very loosely applied. If I'm not mistaken, non fast-forward merges are even forbidden in some repositories, or, at least, not the default option.

As a corollary, no other PR/MRs should appear in the "central" tree, i.e., if people do PR/MRs between their developments (which has been discouraged, but has still happened), those should be squash, fast-forward, rebase, whatever, but without a merge commit

👍 👍 👍

mexanick and others added 2 commits March 30, 2020 11:25
- adding [[deprecated]] attributes to single register access exports
- removing export of readRemoteBlock as it is indeed not used by cmsgemos
- getting order in include/server/utils.h
Export read and write functions as RPC methods as a temporary compatibility layer
@mexanick mexanick self-requested a review March 31, 2020 09:13
@mexanick
Copy link
Contributor

Merging as is will allow to loosely keep the commit history after deletion of the templated-rpc-methods branch deletion which I believe is preferred way in current circumstances. Otherwise, squash commit can be applied, but then history tracking will be difficult and would requires preserving of then-obsolete templated-rpc-methods branch

@mexanick mexanick mentioned this pull request Mar 31, 2020
8 tasks
@mexanick mexanick merged commit bb98c3a into develop Mar 31, 2020
@lpetre-ulb lpetre-ulb deleted the feature/templated-rpc-methods branch March 31, 2020 12:47
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants