mirror of
https://github.com/valitydev/woody_java.git
synced 2024-11-06 08:15:21 +00:00
MSPF-6: Builder type fixes to make thrift endpoint creation more handy
This commit is contained in:
parent
ab0284d36a
commit
863f3e775e
@ -1,6 +1,7 @@
|
||||
package com.rbkmoney.woody.thrift.impl.http;
|
||||
|
||||
import com.rbkmoney.woody.api.AbstractClientBuilder;
|
||||
import com.rbkmoney.woody.api.ClientBuilder;
|
||||
import com.rbkmoney.woody.api.event.ClientEventListener;
|
||||
import com.rbkmoney.woody.api.generator.IdGenerator;
|
||||
import com.rbkmoney.woody.api.interceptor.CommonInterceptor;
|
||||
@ -28,6 +29,7 @@ import org.apache.thrift.transport.TTransport;
|
||||
|
||||
import java.lang.reflect.Constructor;
|
||||
import java.lang.reflect.InvocationTargetException;
|
||||
import java.net.URI;
|
||||
import java.util.Arrays;
|
||||
import java.util.Optional;
|
||||
|
||||
@ -49,6 +51,21 @@ public class THClientBuilder extends AbstractClientBuilder {
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public THClientBuilder withAddress(URI address) {
|
||||
return (THClientBuilder) super.withAddress(address);
|
||||
}
|
||||
|
||||
@Override
|
||||
public THClientBuilder withEventListener(ClientEventListener listener) {
|
||||
return (THClientBuilder) super.withEventListener(listener);
|
||||
}
|
||||
|
||||
@Override
|
||||
public THClientBuilder withIdGenerator(IdGenerator generator) {
|
||||
return (THClientBuilder) super.withIdGenerator(generator);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected MethodCallTracer getOnCallMetadataExtender(Class iface) {
|
||||
return new EmptyTracer() {
|
||||
|
@ -1,6 +1,7 @@
|
||||
package com.rbkmoney.woody.thrift.impl.http;
|
||||
|
||||
import com.rbkmoney.woody.api.AbstractServiceBuilder;
|
||||
import com.rbkmoney.woody.api.ServiceBuilder;
|
||||
import com.rbkmoney.woody.api.event.ServiceEventListener;
|
||||
import com.rbkmoney.woody.api.interceptor.CommonInterceptor;
|
||||
import com.rbkmoney.woody.api.interceptor.CompositeInterceptor;
|
||||
@ -30,6 +31,10 @@ import java.util.Optional;
|
||||
*/
|
||||
public class THServiceBuilder extends AbstractServiceBuilder<Servlet> {
|
||||
|
||||
@Override
|
||||
public THServiceBuilder withEventListener(ServiceEventListener listener) {
|
||||
return (THServiceBuilder) super.withEventListener(listener);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected MethodCallTracer getOnCallMetadataExtender(Class serviceInterface) {
|
||||
|
Loading…
Reference in New Issue
Block a user