Subscription loadSubscription(String id) {
...
}
@Override
public SubscriptionList findMatchingSubscriptions(String app, String topic) {
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package org.example; | |
import java.util.List; | |
import java.util.ArrayList; | |
public class ErrorListResponse { | |
public static final String TYPE = "error.list"; |
@POST
@Path("/{id: [0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}}/ping")
public Response pingSubscription(@PathParam("id") String id) throws Exception {
final Optional<Subscription> sub = subscriptionService.loadSubscription(id);
if (sub.isPresent()) {
return Response.ok(eventDeliveryService.sendPingEvent(sub.get())).build();
} else {
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
before: wrap calls in try/finally | |
*/ | |
@Override | |
public Notification readNotification(String appID, String notificationID) { | |
final Timer.Context time = readTimer.time(); | |
try { | |
return notificationStore.read(appID, notificationID).getNotification(); | |
} finally { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class MetricRegistryModule extends AbstractModule { | |
private MetricRegistry metricsRegistry; | |
public MetricRegistryModule(MetricRegistry metricsRegistry) { | |
this.metricsRegistry = metricsRegistry; | |
} | |
@Override | |
protected void configure() { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Inject | |
@Context | |
private HttpContext httpContext; | |
@Inject | |
@Context | |
private HttpHeaders headers; | |
@Inject | |
@Context |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/build.gradle b/build.gradle | |
index b514ac8..b548f75 100644 | |
--- a/build.gradle | |
+++ b/build.gradle | |
@@ -41,6 +41,7 @@ subprojects { | |
uploadArchives { | |
repositories { | |
signing { | |
+ required = false | |
sign configurations.archives |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export JAVA_HOME=$(/usr/libexec/java_home -v 1.7) |
java -XX:+PrintFlagsFinal -version
OlderNewer