Tabnine Logo
HttpConfig.newBuilder
Code IndexAdd Tabnine to your IDE (free)

How to use
newBuilder
method
in
com.hubspot.horizon.HttpConfig

Best Java code snippets using com.hubspot.horizon.HttpConfig.newBuilder (Showing top 6 results out of 315)

origin: HubSpot/Singularity

@Override
protected void configure() {
 ObjectMapper objectMapper = JavaUtils.newObjectMapper();
 Builder httpConfigBuilder = HttpConfig.newBuilder().setObjectMapper(objectMapper);
 bind(ObjectMapper.class).annotatedWith(Names.named(MESOS_CLIENT_OBJECT_MAPPER)).toInstance(objectMapper);
 bind(HttpClient.class).annotatedWith(Names.named(SingularityMesosClient.DEFAULT_HTTP_CLIENT_NAME))
   .toInstance(new NingHttpClient(httpConfigBuilder.build()));
 bind(HttpClient.class).annotatedWith(Names.named(SingularityMesosClient.SHORT_TIMEOUT_HTTP_CLIENT_NAME))
   .toInstance(new NingHttpClient(httpConfigBuilder.setRequestTimeoutSeconds(MESOS_CLIENT_HTTP_SHORT_TIMEOUT_SECONDS).build()));
 bind(MesosClient.class).to(SingularityMesosClient.class).in(Scopes.SINGLETON);
}
origin: HubSpot/Singularity

@Override
protected void configure() {
 ObjectMapper objectMapper = JavaUtils.newObjectMapper();
 objectMapper.registerModule(new GuavaModule());
 objectMapper.registerModule(new Jdk8Module());
 HttpClient httpClient = new NingHttpClient(httpConfig.or(HttpConfig.newBuilder().setObjectMapper(objectMapper).build()));
 bind(HttpClient.class).annotatedWith(Names.named(HTTP_CLIENT_NAME)).toInstance(httpClient);
 bind(SingularityClient.class).toProvider(SingularityClientProvider.class).in(Scopes.SINGLETON);
 if (hosts != null) {
  bindHosts(binder()).toInstance(hosts);
 }
}
origin: com.hubspot/HorizonNing

public NingHttpClient() {
 this(HttpConfig.newBuilder().build());
}
origin: com.hubspot/HorizonApache

public ApacheHttpClient() {
 this(HttpConfig.newBuilder().build());
}
origin: com.hubspot/HorizonNing

public NingAsyncHttpClient() {
 this(HttpConfig.newBuilder().build());
}
origin: HubSpot/Baragon

@Override
protected void configure() {
 HttpClient httpClient = new NingHttpClient(HttpConfig.newBuilder()
     .setObjectMapper(buildObjectMapper())
     .build());
 bind(HttpClient.class).annotatedWith(Names.named(HTTP_CLIENT_NAME)).toInstance(httpClient);
 bind(BaragonServiceClient.class).toProvider(BaragonClientProvider.class).in(Scopes.SINGLETON);
 if (hosts != null) {
  bindHosts(binder()).toInstance(hosts);
 }
}
com.hubspot.horizonHttpConfignewBuilder

Popular methods of HttpConfig

  • getConnectTimeoutMillis
  • getMaxConnections
  • getMaxConnectionsPerHost
  • getMaxRedirects
  • getObjectMapper
  • getOptions
  • getRequestTimeoutMillis
  • getSSLConfig
  • getUserAgent
  • isFollowRedirects
  • <init>
  • getDefaultKeepAliveMillis
  • <init>,
  • getDefaultKeepAliveMillis,
  • isRejectRelativeRedirects

Popular in Java

  • Start an intent from android
  • getResourceAsStream (ClassLoader)
  • putExtra (Intent)
  • getSystemService (Context)
  • HttpServer (com.sun.net.httpserver)
    This class implements a simple HTTP server. A HttpServer is bound to an IP address and port number a
  • Proxy (java.net)
    This class represents proxy server settings. A created instance of Proxy stores a type and an addres
  • KeyStore (java.security)
    KeyStore is responsible for maintaining cryptographic keys and their owners. The type of the syste
  • Hashtable (java.util)
    A plug-in replacement for JDK1.5 java.util.Hashtable. This version is based on org.cliffc.high_scale
  • Set (java.util)
    A Set is a data structure which does not allow duplicate elements.
  • Executor (java.util.concurrent)
    An object that executes submitted Runnable tasks. This interface provides a way of decoupling task s
  • CodeWhisperer alternatives
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now