<p>Yes, this can be done by Service Discovery. The product family you're looking for is of products such as <a href="https://www.consul.io/" rel="nofollow noreferrer">Consul</a>. You should have the container services report their identities and versions when they load. Report their version and ip (for example), and have the tests run against these values.</p>

<p>This will require some effort with installations and scripting, and has a learning curve - but this is the way to go. </p>

CC BY-SA 4.0
2018-09-22T17:31:44.763Z
I tried to understand Consul but does it work if there are like 5 multiple test cases where different people test different 2 completly different branches together? I mean all 5 tester's staging test should be "in a container knowing only each other branches as communication". Maybe our idea to solve this matter is wrong and we should just get a different approach to test. But I haven't seen any information or paper about what to do in our case.
Beardminator
CC BY-SA 4.0
2018-09-22T01:40:20.067Z
2018-09-22T01:40:20.067Z
orberkov
<p>You need apply Continuos integration, so exist many combinations but general you need know your </p>

<p>1.-Programming language.</p>

<p>2.-Operative System and version. </p>

<p>3.-Data type( sql, mongodb,file, etc).</p>

<p>4.-Protocol communication and port.</p>

<p>5.-A script that check o verify outputs.</p>

<p>6.-A file with result/or flag</p>

<p><a href="https://travis-ci.org" rel="nofollow noreferrer">travis</a> is very well option, because they run test with his machines, and too you can add service git(github option) , with file script called <code>.travis</code> you can run your test, exist other ci services and integrations but general working like it(without docker).   </p>

<pre><code>language: python
cache: pip
python:
  - '3.5'
  - '3.6'

install: pip install -r requirements-dev.txt
script: pytest
deploy:
  provider: pypi
  user: acme-bot
  password:
    secure: "&lt;something long&gt;"
  distributions: sdist bdist_wheel
  on:
    tags: true

matrix:
  include:
</code></pre>

<p>Well if you network communication require additional service networs you too need a service VPN </p>

CC BY-SA 4.0
2018-09-25T21:53:35.030Z
2018-09-25T21:53:35.030Z
Soleil
<p>I been trying to search for answer for this question but so far I didn't found anything useful.</p>

<p>Our problem is that we have 2 microservices with many staging branches, each of these microservices are on different servers and environments.
We want to test each microservices branch with each other in our staging environment so microservice1-branch20 with microservice2-branch10.
They need to communicate two-way so they both need to know that they only can contact with that version of the microservice.</p>

<p>Is there any good way to do these tests without putting them together in one docker container?</p>

<microservices>
Staging - Test multiple microservice versions together
Beardminator
# Staging - Test multiple microservice versions together

(Asked by: username_0 on 2018-09-20)

I been trying to search for answer for this question but so far I didn't found anything useful.

Our problem is that we have 2 microservices with many staging branches, each of these microservices are on different servers and environments.
We want to test each microservices branch with each other in our staging environment so microservice1-branch20 with microservice2-branch10.
They need to communicate two-way so they both need to know that they only can contact with that version of the microservice.

Is there any good way to do these tests without putting them together in one docker container?

**Tags:** microservices


---

## 2 answers

### Answer by username_1 on 2018-09-22. Score: 1

Yes, this can be done by Service Discovery. The product family you're looking for is of products such as [Consul](https://www.consul.io/). You should have the container services report their identities and versions when they load. Report their version and ip (for example), and have the tests run against these values.

This will require some effort with installations and scripting, and has a learning curve - but this is the way to go.

> **Comments:**
> **username_0**: I tried to understand Consul but does it work if there are like 5 multiple test cases where different people test different 2 completly different branches together? I mean all 5 tester's staging test should be "in a container knowing only each other branches as communication". Maybe our idea to solve this matter is wrong and we should just get a different approach to test. But I haven't seen any information or paper about what to do in our case.  

---

### Answer by username_2 on 2018-09-25. Score: 0

You need apply Continuos integration, so exist many combinations but general you need know your 
1.-Programming language.
2.-Operative System and version. 
3.-Data type( sql, mongodb,file, etc).
4.-Protocol communication and port.
5.-A script that check o verify outputs.
6.-A file with result/or flag
travis is very well option, because they run test with his machines, and too you can add service git(github option) , with file script called .travis you can run your test, exist other ci services and integrations but general working like it(without docker).   
language: python
cache: pip
python:
  - '3.5'
  - '3.6'

install: pip install -r requirements-dev.txt
script: pytest
deploy:
  provider: pypi
  user: acme-bot
  password:
    secure: ""
  distributions: sdist bdist_wheel
  on:
    tags: true

matrix:
  include:

Well if you network communication require additional service networs you too need a service VPN


---

