Skip to content
This repository was archived by the owner on Sep 11, 2020. It is now read-only.

transport/server: add asClient parameter #476

Merged
merged 1 commit into from
Jul 11, 2017
Merged

transport/server: add asClient parameter #476

merged 1 commit into from
Jul 11, 2017

Conversation

smola
Copy link
Collaborator

@smola smola commented Jul 11, 2017

Now server.NewServer takes a second parameter asClient.
When asClient is true, the returned instance behaves exactly
as a client from any other protocol. This makes it working
seamlessly when registering a server directly with
client.InstallProtocol.

@smola smola requested a review from mcuadros July 11, 2017 12:53
@codecov
Copy link

codecov bot commented Jul 11, 2017

Codecov Report

Merging #476 into master will decrease coverage by 0.61%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #476      +/-   ##
==========================================
- Coverage   78.03%   77.42%   -0.62%     
==========================================
  Files         127      127              
  Lines        9288     9293       +5     
==========================================
- Hits         7248     7195      -53     
- Misses       1248     1321      +73     
+ Partials      792      777      -15
Impacted Files Coverage Δ
plumbing/transport/server/server.go 59.17% <100%> (+0.95%) ⬆️
plumbing/transport/ssh/common.go 2.81% <0%> (-45.08%) ⬇️
plumbing/transport/ssh/auth_method.go 33.33% <0%> (-24.77%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 09cd5cc...8009cde. Read the comment docs.

server.NewClient returns a server that acts as a client.
This makes it working seamlessly when registering a server directly with
`client.InstallProtocol`.
@mcuadros mcuadros merged commit ec0f306 into src-d:master Jul 11, 2017
@smola smola deleted the server-as-client branch July 11, 2017 14:31
# for free to subscribe to this conversation on GitHub. Already have an account? #.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants