mirror of https://github.com/apache/cloudstack.git
Inject GslbServiceProvider using @Inject fails in oss build, as it requires an
implemenation by default to autowire but only implementation avaialable is in nonoss plugin. So using autowired required=false for injecting GslbServiceProvider that will work with both oss and non-oss builds.
This commit is contained in:
parent
d437cb6dac
commit
f8b8f60977
|
|
@ -44,6 +44,7 @@ import org.apache.cloudstack.api.command.user.region.ha.gslb.*;
|
|||
import org.apache.cloudstack.region.Region;
|
||||
import org.apache.cloudstack.region.dao.RegionDao;
|
||||
import org.apache.log4j.Logger;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
import javax.ejb.Local;
|
||||
|
|
@ -79,8 +80,8 @@ public class GlobalLoadBalancingRulesServiceImpl implements GlobalLoadBalancingR
|
|||
IPAddressDao _ipAddressDao;
|
||||
@Inject
|
||||
AgentManager _agentMgr;
|
||||
|
||||
protected GslbServiceProvider _gslbProvider = null;
|
||||
@Autowired(required=false)
|
||||
protected GslbServiceProvider _gslbProvider;
|
||||
|
||||
|
||||
@Override
|
||||
|
|
|
|||
Loading…
Reference in New Issue