[SERVER-28470] KMIPService constructor should keep the Status from _initServerConnection Created: 24/Mar/17  Updated: 27/Jun/22  Resolved: 23/Jun/17

Status: Closed
Project: Core Server
Component/s: Security
Affects Version/s: None
Fix Version/s: 3.5.10

Type: Improvement Priority: Major - P3
Reporter: Ben Shteinfeld Assignee: Ben Shteinfeld
Resolution: Done Votes: 0
Labels: neweng, platforms-interns-2017
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Backwards Compatibility: Fully Compatible
Sprint: Platforms 2017-06-19, Platforms 2017-07-10
Participants:
Case:

 Description   

The KMIPService constructor uses the Status that it gets from _initServerConnection() only to set _isValid to true or false. This means that the error message which _initServerConnection() might have stored in the Status is thrown away, which is undesirable from a usability perspective.

_isValid should be converted from a bool to a Status, and used to store the result of _initServerConnection. Then where kmipService.isValid() is called in getKeyFromKMIPServer(), it should include any non-OK Status from kmipService in the Status that it returns.



 Comments   
Comment by Githook User [ 23/Jun/17 ]

Author:

{u'username': u'bshteinfeld', u'name': u'Ben Shteinfeld', u'email': u'ben.shteinfeld@mongodb.com'}

Message: SERVER-28470 Create static factory for KMIPService to return StatusWith
Branch: master
https://github.com/10gen/mongo-enterprise-modules/commit/beab33752f938fcc6acf549fb4aa24cfc25c01fb

Generated at Thu Feb 08 04:18:14 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.