Java Code Examples for com.alibaba.dubbo.registry.common.domain.Consumer#setApplication()
The following examples show how to use
com.alibaba.dubbo.registry.common.domain.Consumer#setApplication() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: SyncUtils.java From dubbox with Apache License 2.0 | 6 votes |
public static Consumer url2Consumer(Pair<Long, URL> pair) { if (pair == null) { return null; } Long id = pair.getKey(); URL url = pair.getValue(); if (null == url) return null; Consumer c = new Consumer(); c.setId(id); c.setService(url.getServiceKey()); c.setAddress(url.getHost()); c.setApplication(url.getParameter(Constants.APPLICATION_KEY)); c.setParameters(url.toParameterString()); return c; }
Example 2
Source File: SyncUtils.java From dubbox-hystrix with Apache License 2.0 | 6 votes |
public static Consumer url2Consumer(Pair<Long, URL> pair) { if (pair == null) { return null; } Long id = pair.getKey(); URL url = pair.getValue(); if (null == url) return null; Consumer c = new Consumer(); c.setId(id); c.setService(url.getServiceKey()); c.setAddress(url.getHost()); c.setApplication(url.getParameter(Constants.APPLICATION_KEY)); c.setParameters(url.toParameterString()); return c; }
Example 3
Source File: SyncUtils.java From dubbo3 with Apache License 2.0 | 6 votes |
public static Consumer url2Consumer(Pair<Long, URL> pair) { if (pair == null) { return null; } Long id = pair.getKey(); URL url = pair.getValue(); if (null == url) return null; Consumer c = new Consumer(); c.setId(id); c.setService(url.getServiceKey()); c.setAddress(url.getHost()); c.setApplication(url.getParameter(Constants.APPLICATION_KEY)); c.setParameters(url.toParameterString()); return c; }
Example 4
Source File: SyncUtils.java From dubbox with Apache License 2.0 | 6 votes |
public static Consumer url2Consumer(Pair<Long, URL> pair) { if (pair == null) { return null; } Long id = pair.getKey(); URL url = pair.getValue(); if (null == url) return null; Consumer c = new Consumer(); c.setId(id); c.setService(url.getServiceKey()); c.setAddress(url.getHost()); c.setApplication(url.getParameter(Constants.APPLICATION_KEY)); c.setParameters(url.toParameterString()); return c; }
Example 5
Source File: SyncUtils.java From dubbox with Apache License 2.0 | 6 votes |
public static Consumer url2Consumer(Pair<Long, URL> pair) { if (pair == null) { return null; } Long id = pair.getKey(); URL url = pair.getValue(); if (null == url) return null; Consumer c = new Consumer(); c.setId(id); c.setService(url.getServiceKey()); c.setAddress(url.getHost()); c.setApplication(url.getParameter(Constants.APPLICATION_KEY)); c.setParameters(url.toParameterString()); return c; }