Support unrecognized properties.
This commit is contained in:
parent
40529dc41f
commit
885af064c9
|
@ -18,6 +18,7 @@ package org.whispersystems.textsecuregcm;
|
||||||
|
|
||||||
import com.codahale.metrics.SharedMetricRegistries;
|
import com.codahale.metrics.SharedMetricRegistries;
|
||||||
import com.codahale.metrics.graphite.GraphiteReporter;
|
import com.codahale.metrics.graphite.GraphiteReporter;
|
||||||
|
import com.fasterxml.jackson.databind.DeserializationFeature;
|
||||||
import com.google.common.base.Optional;
|
import com.google.common.base.Optional;
|
||||||
import net.spy.memcached.MemcachedClient;
|
import net.spy.memcached.MemcachedClient;
|
||||||
import org.bouncycastle.jce.provider.BouncyCastleProvider;
|
import org.bouncycastle.jce.provider.BouncyCastleProvider;
|
||||||
|
@ -112,6 +113,7 @@ public class WhisperServerService extends Application<WhisperServerConfiguration
|
||||||
throws Exception
|
throws Exception
|
||||||
{
|
{
|
||||||
SharedMetricRegistries.add(Constants.METRICS_NAME, environment.metrics());
|
SharedMetricRegistries.add(Constants.METRICS_NAME, environment.metrics());
|
||||||
|
environment.getObjectMapper().configure(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES, false);
|
||||||
|
|
||||||
DBIFactory dbiFactory = new DBIFactory();
|
DBIFactory dbiFactory = new DBIFactory();
|
||||||
DBI jdbi = dbiFactory.build(environment, config.getDataSourceFactory(), "postgresql");
|
DBI jdbi = dbiFactory.build(environment, config.getDataSourceFactory(), "postgresql");
|
||||||
|
|
|
@ -84,7 +84,6 @@ public class KeysController {
|
||||||
|
|
||||||
@Timed
|
@Timed
|
||||||
@GET
|
@GET
|
||||||
@Path("/")
|
|
||||||
@Produces(MediaType.APPLICATION_JSON)
|
@Produces(MediaType.APPLICATION_JSON)
|
||||||
public PreKeyStatus getStatus(@Auth Account account) {
|
public PreKeyStatus getStatus(@Auth Account account) {
|
||||||
int count = keys.getCount(account.getNumber(), account.getAuthenticatedDevice().get().getId());
|
int count = keys.getCount(account.getNumber(), account.getAuthenticatedDevice().get().getId());
|
||||||
|
|
Loading…
Reference in New Issue