- [ ] I have searched the 
[issues](https://github.com/apache/incubator-dubbo/issues) of this repository 
and believe that this is not a duplicate.
- [ ] I have checked the 
[FAQ](https://github.com/apache/incubator-dubbo/blob/master/FAQ.md) of this 
repository and believe that this is not a duplicate.

### Environment

* Dubbo version: 2.6.2
* Operating System version: win7
* Java version: 1.8

### Step to reproduce this issue

#### Problem one

I want to test pseudo cluster, I create service like follow code :

```
public interface DemoService
{
    String sayHello(String name);
}
```

implement service interface  as follows, both loadbalance strategies are random:

```
@Service(timeout = 5000, loadbalance="random")
public class DemoServiceImpl implements DemoService
{
    @Override
    public String sayHello(String name)
    {
        return "Service1 -> Hello " + name;
    }
}
```

```
@Service(timeout = 5000, loadbalance="random")
public class DemoServiceImpl2 implements DemoService
{
    @Override
    public String sayHello(String name)
    {
        return "Service2 -> Hello " + name;
    }
}
```

### Expected Result

* start one application
* random return "Service1" and "Service2" . 

### Actual Result

* alway return "Service2"

#### Problem two

change one implement loadblance stragy as follow:

```
@Service(timeout = 5000, loadbalance="consistenthash")
public class DemoServiceImpl implements DemoService
{
    @Override
    public String sayHello(String name)
    {
        return "Service1 -> Hello " + name;
    }
}
```

### Question

I don't know how dubbo it works. but it is very strange , it always use 
consistenthash stragy.

Dubbo provide client and server side loadblance stragy , Who is at work.

As I know,dubbo has no central node coordinator,  may be is client side effect. 
If remove server side loadblance stragy is better?





[ Full content available at: 
https://github.com/apache/incubator-dubbo/issues/2419 ]
This message was relayed via gitbox.apache.org for [email protected]

Reply via email to