Skip to content

NGSIv1 removal pending issues and follow ups #4681

@fgalan

Description

@fgalan

PR #4603 start the removal, but some items are still pending:

Not directly related to NGSIv1 removal, but detected during this work:

  • parseEntitiesResponse potential leak at the end. Memory is not release in case of parse error. Create a .test to raise the leak first. Review V2 parsing logic searching for new
  for (rapidjson::Value::ConstValueIterator iter = document.Begin(); iter != document.End(); ++iter)
  {
    Entity* eP = new Entity();

    std::string s = parseEntityObject(ciP, iter, eP, true, true);
    if (s != "OK")
    {
      oeP->fill(SccBadRequest, s);
      alarmMgr.badInput(clientIp, "JSON Parse Error", s);
      ciP->httpStatusCode = SccBadRequest;
      return false;
    }

    evP->vec.push_back(eP);
  }

Edit: some fixes in this line were done in the last commits of PR #4603 (1e72568, d9a3739 ) although a more exhaustive analysis should be done.

  • ForwardingInformation not working
  //
  // FIXME P6: once forwarding is implemented for APIv2, include this call
  // jh.addRaw("forwardingInformation", forwardingInformation.toJson());
  //
  • Align scripts/style_check_in_makefile.sh with src/lib and test/unittest (alphabetical order would be clearer)

  • Guards with empty types. Mark for removal

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions