/** * Sets the value of property to value * * @since 1.9.0 */ public void setProperty(String prop, String value) { with(prop, value); }
/** * Same as {@link #with(ClientProperty, String)} for ClientProperty.INSTANCE_RPC_SASL_ENABLED and * ClientProperty.GENERAL_KERBEROS_PRINCIPAL. * * @param saslEnabled * Should SASL(kerberos) be enabled * @param kerberosServerPrimary * The 'primary' component of the Kerberos principal Accumulo servers use to login (e.g. * 'accumulo' in 'accumulo/_HOST@REALM') * @since 1.7.0 */ public ClientConfiguration withSasl(boolean saslEnabled, String kerberosServerPrimary) { return withSasl(saslEnabled).with(ClientProperty.KERBEROS_SERVER_PRIMARY, kerberosServerPrimary); }
/** * Sets the value of property to value * */ public void setProperty(ClientProperty prop, String value) { with(prop, value); }
/** * Same as {@link #with(ClientProperty, String)} for ClientProperty.INSTANCE_RPC_SASL_ENABLED and * ClientProperty.GENERAL_KERBEROS_PRINCIPAL. * * @param saslEnabled * Should SASL(kerberos) be enabled * @param kerberosServerPrimary * The 'primary' component of the Kerberos principal Accumulo servers use to login (e.g. * 'accumulo' in 'accumulo/_HOST@REALM') * @since 1.7.0 */ public ClientConfiguration withSasl(boolean saslEnabled, String kerberosServerPrimary) { return withSasl(saslEnabled).with(ClientProperty.KERBEROS_SERVER_PRIMARY, kerberosServerPrimary); }
/** * Same as {@link #with(ClientProperty, String)} for ClientProperty.INSTANCE_RPC_SASL_ENABLED. * * @since 1.7.0 */ public ClientConfiguration withSasl(boolean saslEnabled) { return with(ClientProperty.INSTANCE_RPC_SASL_ENABLED, String.valueOf(saslEnabled)); }
/** * Same as {@link #with(ClientProperty, String)} for ClientProperty.INSTANCE_ZK_HOST * */ public ClientConfiguration withZkHosts(String zooKeepers) { checkArgument(zooKeepers != null, "zooKeepers is null"); return with(ClientProperty.INSTANCE_ZK_HOST, zooKeepers); }
/** * Same as {@link #with(ClientProperty, String)} for ClientProperty.INSTANCE_ZK_TIMEOUT * */ public ClientConfiguration withZkTimeout(int timeout) { return with(ClientProperty.INSTANCE_ZK_TIMEOUT, String.valueOf(timeout)); }
/** * Same as {@link #with(ClientProperty, String)} for ClientProperty.INSTANCE_RPC_SSL_ENABLED and * ClientProperty.RPC_USE_JSSE * */ public ClientConfiguration withSsl(boolean sslEnabled, boolean useJsseConfig) { return with(ClientProperty.INSTANCE_RPC_SSL_ENABLED, String.valueOf(sslEnabled)) .with(ClientProperty.RPC_USE_JSSE, String.valueOf(useJsseConfig)); }
/** * Same as {@link #with(ClientProperty, String)} for ClientProperty.INSTANCE_NAME * */ public ClientConfiguration withInstance(String instanceName) { checkArgument(instanceName != null, "instanceName is null"); return with(ClientProperty.INSTANCE_NAME, instanceName); }
/** * Same as {@link #with(ClientProperty, String)} for ClientProperty.INSTANCE_ID * */ public ClientConfiguration withInstance(UUID instanceId) { checkArgument(instanceId != null, "instanceId is null"); return with(ClientProperty.INSTANCE_ID, instanceId.toString()); }
/** * Same as {@link #setProperty(ClientProperty, String)} but returns the ClientConfiguration for * chaining purposes */ public ClientConfiguration with(ClientProperty prop, String value) { return with(prop.getKey(), value); }
/** * Sets the value of property to value * */ public void setProperty(ClientProperty prop, String value) { with(prop, value); }
/** * Sets the value of property to value * * @since 1.9.0 */ public void setProperty(String prop, String value) { with(prop, value); }
/** * Same as {@link #with(ClientProperty, String)} for ClientProperty.INSTANCE_RPC_SASL_ENABLED. * * @since 1.7.0 */ public ClientConfiguration withSasl(boolean saslEnabled) { return with(ClientProperty.INSTANCE_RPC_SASL_ENABLED, String.valueOf(saslEnabled)); }
/** * Same as {@link #with(ClientProperty, String)} for ClientProperty.INSTANCE_ZK_HOST * */ public ClientConfiguration withZkHosts(String zooKeepers) { checkArgument(zooKeepers != null, "zooKeepers is null"); return with(ClientProperty.INSTANCE_ZK_HOST, zooKeepers); }
/** * Same as {@link #with(ClientProperty, String)} for ClientProperty.INSTANCE_NAME * */ public ClientConfiguration withInstance(String instanceName) { checkArgument(instanceName != null, "instanceName is null"); return with(ClientProperty.INSTANCE_NAME, instanceName); }
/** * Same as {@link #with(ClientProperty, String)} for ClientProperty.INSTANCE_ZK_TIMEOUT * */ public ClientConfiguration withZkTimeout(int timeout) { return with(ClientProperty.INSTANCE_ZK_TIMEOUT, String.valueOf(timeout)); }
/** * Same as {@link #with(ClientProperty, String)} for ClientProperty.INSTANCE_RPC_SSL_ENABLED and * ClientProperty.RPC_USE_JSSE * */ public ClientConfiguration withSsl(boolean sslEnabled, boolean useJsseConfig) { return with(ClientProperty.INSTANCE_RPC_SSL_ENABLED, String.valueOf(sslEnabled)) .with(ClientProperty.RPC_USE_JSSE, String.valueOf(useJsseConfig)); }
/** * Same as {@link #with(ClientProperty, String)} for ClientProperty.INSTANCE_ID * */ public ClientConfiguration withInstance(UUID instanceId) { checkArgument(instanceId != null, "instanceId is null"); return with(ClientProperty.INSTANCE_ID, instanceId.toString()); }
/** * Same as {@link #setProperty(ClientProperty, String)} but returns the ClientConfiguration for * chaining purposes */ public ClientConfiguration with(ClientProperty prop, String value) { return with(prop.getKey(), value); }