----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/47440/#review133819 -----------------------------------------------------------
A couple of highlevel questions and thoughts below. src/main/java/org/apache/aurora/scheduler/events/PubsubEvent.java (line 163) <https://reviews.apache.org/r/47440/#comment198455> By using the object as-is, we have effectively made in internal API public. That could prevent us from doing necessary changes in the future, as we would have to adhere to a deprecation cycle. It might therefore make sense to establish an explicit schema. src/main/java/org/apache/aurora/scheduler/events/Webhook.java (line 39) <https://reviews.apache.org/r/47440/#comment198460> Thinking out loud: Do we have to worry about synchronization? Or is there a guarantee that only one event will be dispatched at a time? If I understand this https://docs.oracle.com/javase/7/docs/technotes/guides/net/http-keepalive.html and that https://stackoverflow.com/questions/16256681/how-to-reuse-httpurlconnection?lq=1 correctly, we could simply re-create a connection object each time. Java should do the right thing behind the scenes. This would relieve us from any synchronization needs. src/main/java/org/apache/aurora/scheduler/events/Webhook.java (line 75) <https://reviews.apache.org/r/47440/#comment198456> Is that an outdated comment? src/main/java/org/apache/aurora/scheduler/events/Webhook.java (line 83) <https://reviews.apache.org/r/47440/#comment198458> What's that line doing? src/main/java/org/apache/aurora/scheduler/events/WebhookModule.java (line 45) <https://reviews.apache.org/r/47440/#comment198461> I am surprised to find this one here. Are you planning to bundle a default config file? - Stephan Erb On May 18, 2016, 11:12 p.m., Dmitriy Shirchenko wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/47440/ > ----------------------------------------------------------- > > (Updated May 18, 2016, 11:12 p.m.) > > > Review request for Aurora. > > > Bugs: AURORA-1683 > https://issues.apache.org/jira/browse/AURORA-1683 > > > Repository: aurora > > > Description > ------- > > Looking for some feedback whether I'm on the correct path in adding a > webhook. All comments are welcome! > > > Diffs > ----- > > docs/reference/scheduler-configuration.md > f7d676d0ed6bc536f4341dbb9365cf50e8607efb > examples/vagrant/upstart/aurora-scheduler.conf > 3d9e706de564df5e24cb34265bebc0db1cad11a0 > src/main/java/org/apache/aurora/scheduler/app/SchedulerMain.java > 9ebfe230836e88a97bc60092373f72f176a8f6f2 > src/main/java/org/apache/aurora/scheduler/events/PubsubEvent.java > 2a4c0665e48d30e0655de00bd7f6f9b49f01eafc > src/main/java/org/apache/aurora/scheduler/events/Webhook.java PRE-CREATION > src/main/java/org/apache/aurora/scheduler/events/WebhookInfo.java > PRE-CREATION > src/main/java/org/apache/aurora/scheduler/events/WebhookModule.java > PRE-CREATION > src/main/resources/org/apache/aurora/scheduler/webhook.json PRE-CREATION > src/test/java/org/apache/aurora/scheduler/events/WebhookTest.java > PRE-CREATION > > Diff: https://reviews.apache.org/r/47440/diff/ > > > Testing > ------- > > Need to fix tests. > > > Thanks, > > Dmitriy Shirchenko > >
