Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

return valid results when several status codes #251

Open
wants to merge 11 commits into
base: master
Choose a base branch
from

Conversation

AlvaroVega
Copy link
Member

@AlvaroVega AlvaroVega commented Aug 11, 2021

When iotaRedirector retrieves several status codes from iotagents linke [200,200,400] then iotagentManager is responding with 400 error.

This PR tries to return the valid results retrieved by iotagent-manager instead just one error.

Related issue #167

This PR overcomes #249

@coveralls
Copy link

coveralls commented Aug 11, 2021

Pull Request Test Coverage Report for Build 1261150107

Warning: This coverage report may be inaccurate.

This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.

Details

  • 10 of 23 (43.48%) changed or added relevant lines in 1 file are covered.
  • 14 unchanged lines in 1 file lost coverage.
  • Overall coverage decreased (-1.3%) to 75.866%

Changes Missing Coverage Covered Lines Changed/Added Lines %
lib/services/iotaRedirector.js 10 23 43.48%
Files with Coverage Reduction New Missed Lines %
lib/services/iotaRedirector.js 14 74.93%
Totals Coverage Status
Change from base Build 949284276: -1.3%
Covered Lines: 506
Relevant Lines: 632

💛 - Coveralls

@AlvaroVega
Copy link
Member Author

AlvaroVega commented Aug 31, 2021

  • Tested with a bad configured iotagent (which returns 400 error):
  - IOTA_PROVIDER_URL=http://172.17.0.1:4061/kk3

@AlvaroVega
Copy link
Member Author

Depends on this PR #256
This PR should be merged after PR #256

@AlvaroVega
Copy link
Member Author

time=2021-09-22T15:48:20.727Z | lvl=WARN | corr=eeed4c39-33d8-440a-8d52-8922230167f9 | trans=eeed4c39-33d8-440a-8d52-8922230167f9 | op=IoTAManager.Redirector | from=n/a | srv=smartcity | subsrv=/problemas/masproblemas | msg=several statusCodes [200,400] and combinedResults {"count":0,"devices":[]}, redirecting for GET | comp=IoTAgentManager

@AlvaroVega AlvaroVega changed the title [WIP] return valid results when several status codes return valid results when several status codes Sep 23, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants