faas-cli icon indicating copy to clipboard operation
faas-cli copied to clipboard

Remove leaking logs from SDK

Open viveksyngh opened this issue 4 years ago • 0 comments
trafficstars

This commit removes leaking logs from the SDK (proxy package) of the CLI by removing custom print statements within proxy package. It updates method signature for DeployFunction which now returns deployOutput text along with status code.

Fixes: #853

Signed-off-by: Vivek Singh [email protected]

Description

Motivation and Context

  • [x] I have raised an issue to propose this change (required)

How Has This Been Tested?

echo -n $PASSWORD | ./faas-cli login --username admin --password-stdin
Calling the OpenFaaS server to validate the credentials...
Handling connection for 8080
credentials saved for admin http://127.0.0.1:8080
(⎈ |kind-vdp:default)➜  faas-cli git:(remove-leakin-logs) echo -n $PASSWORD | ./faas-cli login --username admin --password-stdin
(⎈ |kind-vdp:default)➜  faas-cli git:(remove-leakin-logs) ./faas-cli store deploy figlet
Handling connection for 8080

Deployed. 202 Accepted.
URL: http://127.0.0.1:8080/function/figlet

(⎈ |kind-vdp:default)➜  faas-cli git:(remove-leakin-logs) ./faas-cli list
Handling connection for 8080
Function                      	Invocations    	Replicas
figlet                        	0              	1

Types of changes

  • [x] 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)

Checklist:

  • [x] My code follows the code style of this project.
  • [ ] My change requires a change to the documentation.
  • [ ] I have updated the documentation accordingly.
  • [ ] I've read the CONTRIBUTION guide
  • [x] I have signed-off my commits with git commit -s
  • [ ] I have added tests to cover my changes.
  • [x] All new and existing tests passed.

viveksyngh avatar Feb 23 '21 12:02 viveksyngh