You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mesos.apache.org by an...@apache.org on 2016/08/02 16:45:07 UTC

[1/5] mesos git commit: Reduced logging verbosity for replicated log operations.

Repository: mesos
Updated Branches:
  refs/heads/master 58a1bd139 -> 74e959848


Reduced logging verbosity for replicated log operations.

Logging the duration required for each storage operation at `INFO` level
is overkill for most people consuming the log.

Review: https://reviews.apache.org/r/50301/


Project: http://git-wip-us.apache.org/repos/asf/mesos/repo
Commit: http://git-wip-us.apache.org/repos/asf/mesos/commit/9eea27c5
Tree: http://git-wip-us.apache.org/repos/asf/mesos/tree/9eea27c5
Diff: http://git-wip-us.apache.org/repos/asf/mesos/diff/9eea27c5

Branch: refs/heads/master
Commit: 9eea27c56db736d2409380f0eaeaecbd1eb1784d
Parents: 58a1bd1
Author: Neil Conway <ne...@gmail.com>
Authored: Tue Aug 2 09:36:02 2016 -0700
Committer: Anand Mazumdar <an...@apache.org>
Committed: Tue Aug 2 09:36:02 2016 -0700

----------------------------------------------------------------------
 src/log/leveldb.cpp      | 26 +++++++++++++-------------
 src/log/log.cpp          |  4 ++--
 src/log/recover.cpp      |  2 +-
 src/log/replica.cpp      |  9 +++------
 src/master/registrar.cpp |  6 +++---
 5 files changed, 22 insertions(+), 25 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/mesos/blob/9eea27c5/src/log/leveldb.cpp
----------------------------------------------------------------------
diff --git a/src/log/leveldb.cpp b/src/log/leveldb.cpp
index f389d74..5310a12 100644
--- a/src/log/leveldb.cpp
+++ b/src/log/leveldb.cpp
@@ -171,14 +171,14 @@ Try<Storage::State> LevelDBStorage::restore(const string& path)
     return Error(status.ToString());
   }
 
-  LOG(INFO) << "Opened db in " << stopwatch.elapsed();
+  VLOG(1) << "Opened db in " << stopwatch.elapsed();
 
   stopwatch.start(); // Restart the stopwatch.
 
   // TODO(benh): Conditionally compact to avoid long recovery times?
   db->CompactRange(nullptr, nullptr);
 
-  LOG(INFO) << "Compacted db in " << stopwatch.elapsed();
+  VLOG(1) << "Compacted db in " << stopwatch.elapsed();
 
   State state;
   state.begin = 0;
@@ -193,13 +193,13 @@ Try<Storage::State> LevelDBStorage::restore(const string& path)
 
   leveldb::Iterator* iterator = db->NewIterator(leveldb::ReadOptions());
 
-  LOG(INFO) << "Created db iterator in " << stopwatch.elapsed();
+  VLOG(1) << "Created db iterator in " << stopwatch.elapsed();
 
   stopwatch.start(); // Restart the stopwatch.
 
   iterator->SeekToFirst();
 
-  LOG(INFO) << "Seeked to beginning of db in " << stopwatch.elapsed();
+  VLOG(1) << "Seeked to beginning of db in " << stopwatch.elapsed();
 
   stopwatch.start(); // Restart the stopwatch.
 
@@ -268,8 +268,8 @@ Try<Storage::State> LevelDBStorage::restore(const string& path)
     iterator->Next();
   }
 
-  LOG(INFO) << "Iterated through " << keys
-            << " keys in the db in " << stopwatch.elapsed();
+  VLOG(1) << "Iterated through " << keys
+          << " keys in the db in " << stopwatch.elapsed();
 
   delete iterator;
 
@@ -301,8 +301,8 @@ Try<Nothing> LevelDBStorage::persist(const Metadata& metadata)
     return Error(status.ToString());
   }
 
-  LOG(INFO) << "Persisting metadata (" << value.size()
-            << " bytes) to leveldb took " << stopwatch.elapsed();
+  VLOG(1) << "Persisting metadata (" << value.size()
+          << " bytes) to leveldb took " << stopwatch.elapsed();
 
   return Nothing();
 }
@@ -338,8 +338,8 @@ Try<Nothing> LevelDBStorage::persist(const Action& action)
   // catch-up policy is used).
   first = min(first, action.position());
 
-  LOG(INFO) << "Persisting action (" << value.size()
-            << " bytes) to leveldb took " << stopwatch.elapsed();
+  VLOG(1) << "Persisting action (" << value.size()
+          << " bytes) to leveldb took " << stopwatch.elapsed();
 
   // Delete positions if a truncate action has been *learned*. Note
   // that we do this in a best-effort fashion (i.e., we ignore any
@@ -396,8 +396,8 @@ Try<Nothing> LevelDBStorage::persist(const Action& action)
         CHECK_LT(first.get(), action.truncate().to());
         first = action.truncate().to();
 
-        LOG(INFO) << "Deleting ~" << index
-                  << " keys from leveldb took " << stopwatch.elapsed();
+        VLOG(1) << "Deleting ~" << index
+                << " keys from leveldb took " << stopwatch.elapsed();
       }
     }
   }
@@ -433,7 +433,7 @@ Try<Action> LevelDBStorage::read(uint64_t position)
     return Error("Bad record");
   }
 
-  LOG(INFO) << "Reading position from leveldb took " << stopwatch.elapsed();
+  VLOG(1) << "Reading position from leveldb took " << stopwatch.elapsed();
 
   return record.action();
 }

http://git-wip-us.apache.org/repos/asf/mesos/blob/9eea27c5/src/log/log.cpp
----------------------------------------------------------------------
diff --git a/src/log/log.cpp b/src/log/log.cpp
index f8e439f..0940f92 100644
--- a/src/log/log.cpp
+++ b/src/log/log.cpp
@@ -574,7 +574,7 @@ Option<Log::Position> LogWriterProcess::__start(
 
 Future<Option<Log::Position> > LogWriterProcess::append(const string& bytes)
 {
-  LOG(INFO) << "Attempting to append " << bytes.size() << " bytes to the log";
+  VLOG(1) << "Attempting to append " << bytes.size() << " bytes to the log";
 
   if (coordinator == nullptr) {
     return Failure("No election has been performed");
@@ -593,7 +593,7 @@ Future<Option<Log::Position> > LogWriterProcess::append(const string& bytes)
 Future<Option<Log::Position> > LogWriterProcess::truncate(
     const Log::Position& to)
 {
-  LOG(INFO) << "Attempting to truncate the log to " << to.value;
+  VLOG(1) << "Attempting to truncate the log to " << to.value;
 
   if (coordinator == nullptr) {
     return Failure("No election has been performed");

http://git-wip-us.apache.org/repos/asf/mesos/blob/9eea27c5/src/log/recover.cpp
----------------------------------------------------------------------
diff --git a/src/log/recover.cpp b/src/log/recover.cpp
index 69b5b28..eaf3fd3 100644
--- a/src/log/recover.cpp
+++ b/src/log/recover.cpp
@@ -463,7 +463,7 @@ protected:
 
   virtual void finalize()
   {
-    LOG(INFO) << "Recover process terminated";
+    VLOG(1) << "Recover process terminated";
   }
 
 private:

http://git-wip-us.apache.org/repos/asf/mesos/blob/9eea27c5/src/log/replica.cpp
----------------------------------------------------------------------
diff --git a/src/log/replica.cpp b/src/log/replica.cpp
index 45b7717..5ab7b3d 100644
--- a/src/log/replica.cpp
+++ b/src/log/replica.cpp
@@ -692,11 +692,7 @@ void ReplicaProcess::learned(const UPID& from, const Action& action)
             << action.position() << " from " << from;
 
   CHECK(action.learned());
-
-  if (persist(action)) {
-    LOG(INFO) << "Replica learned " << action.type()
-              << " action at position " << action.position();
-  }
+  persist(action);
 }
 
 
@@ -709,7 +705,8 @@ bool ReplicaProcess::persist(const Action& action)
     return false;
   }
 
-  LOG(INFO) << "Persisted action at " << action.position();
+  VLOG(1) << "Persisted action " << action.type()
+          << " at position " << action.position();
 
   // No longer a hole here (if there even was one).
   holes -= action.position();

http://git-wip-us.apache.org/repos/asf/mesos/blob/9eea27c5/src/master/registrar.cpp
----------------------------------------------------------------------
diff --git a/src/master/registrar.cpp b/src/master/registrar.cpp
index 9d2f558..4589d2f 100644
--- a/src/master/registrar.cpp
+++ b/src/master/registrar.cpp
@@ -462,7 +462,7 @@ void RegistrarProcess::update()
   }
 
   LOG(INFO) << "Applied " << operations.size() << " operations in "
-            << stopwatch.elapsed() << "; attempting to update the 'registry'";
+            << stopwatch.elapsed() << "; attempting to update the registry";
 
   // Perform the store, and time the operation.
   metrics.state_store.start();
@@ -488,7 +488,7 @@ void RegistrarProcess::_update(
 
   // Abort if the storage operation did not succeed.
   if (!store.isReady() || store.get().isNone()) {
-    string message = "Failed to update 'registry': ";
+    string message = "Failed to update registry: ";
 
     if (store.isFailed()) {
       message += store.failure();
@@ -506,7 +506,7 @@ void RegistrarProcess::_update(
 
   Duration elapsed = metrics.state_store.stop();
 
-  LOG(INFO) << "Successfully updated the 'registry' in " << elapsed;
+  LOG(INFO) << "Successfully updated the registry in " << elapsed;
 
   variable = store.get().get();
 


[4/5] mesos git commit: Tweaked agent logging.

Posted by an...@apache.org.
Tweaked agent logging.

Review: https://reviews.apache.org/r/50520/


Project: http://git-wip-us.apache.org/repos/asf/mesos/repo
Commit: http://git-wip-us.apache.org/repos/asf/mesos/commit/f9b0558a
Tree: http://git-wip-us.apache.org/repos/asf/mesos/tree/f9b0558a
Diff: http://git-wip-us.apache.org/repos/asf/mesos/diff/f9b0558a

Branch: refs/heads/master
Commit: f9b0558a5bfc12f784dde74195b88782e6e8d203
Parents: 961f29b
Author: Neil Conway <ne...@gmail.com>
Authored: Tue Aug 2 09:36:40 2016 -0700
Committer: Anand Mazumdar <an...@apache.org>
Committed: Tue Aug 2 09:36:40 2016 -0700

----------------------------------------------------------------------
 src/slave/main.cpp  | 3 ---
 src/slave/slave.cpp | 4 ++--
 2 files changed, 2 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/mesos/blob/f9b0558a/src/slave/main.cpp
----------------------------------------------------------------------
diff --git a/src/slave/main.cpp b/src/slave/main.cpp
index a4d971a..42ca115 100644
--- a/src/slave/main.cpp
+++ b/src/slave/main.cpp
@@ -430,9 +430,6 @@ int main(int argc, char** argv)
     return EXIT_FAILURE;
   }
 
-
-  LOG(INFO) << "Starting Mesos agent";
-
   Slave* slave = new Slave(
       id,
       flags,

http://git-wip-us.apache.org/repos/asf/mesos/blob/f9b0558a/src/slave/slave.cpp
----------------------------------------------------------------------
diff --git a/src/slave/slave.cpp b/src/slave/slave.cpp
index 7e2e89b..51d7831 100644
--- a/src/slave/slave.cpp
+++ b/src/slave/slave.cpp
@@ -195,7 +195,7 @@ void Slave::signaled(int signal, int uid)
 
 void Slave::initialize()
 {
-  LOG(INFO) << "Agent started on " << string(self()).substr(6);
+  LOG(INFO) << "Mesos agent started on " << string(self()).substr(5);
   LOG(INFO) << "Flags at startup: " << flags;
 
   if (self().address.ip.isLoopback()) {
@@ -3782,7 +3782,7 @@ void Slave::pingTimeout(Future<Option<MasterInfo>> future)
 
 void Slave::exited(const UPID& pid)
 {
-  LOG(INFO) << pid << " exited";
+  LOG(INFO) << "Got exited event for " << pid;
 
   if (master.isNone() || master.get() == pid) {
     // TODO(neilc): Try to re-link to the master (MESOS-1963).


[3/5] mesos git commit: Clarified log messages during master startup.

Posted by an...@apache.org.
Clarified log messages during master startup.

In particular, it is confusing to have two separate log messages:
"detected a new leader" and "elected as the new leader".

Review: https://reviews.apache.org/r/50518/


Project: http://git-wip-us.apache.org/repos/asf/mesos/repo
Commit: http://git-wip-us.apache.org/repos/asf/mesos/commit/961f29bf
Tree: http://git-wip-us.apache.org/repos/asf/mesos/tree/961f29bf
Diff: http://git-wip-us.apache.org/repos/asf/mesos/diff/961f29bf

Branch: refs/heads/master
Commit: 961f29bf859673607c9ceb94c23925f090c28825
Parents: 9417ae4
Author: Neil Conway <ne...@gmail.com>
Authored: Tue Aug 2 09:36:32 2016 -0700
Committer: Anand Mazumdar <an...@apache.org>
Committed: Tue Aug 2 09:36:32 2016 -0700

----------------------------------------------------------------------
 src/master/main.cpp      |  2 --
 src/master/master.cpp    | 23 ++++++++++++-----------
 src/master/registrar.cpp |  2 +-
 3 files changed, 13 insertions(+), 14 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/mesos/blob/961f29bf/src/master/main.cpp
----------------------------------------------------------------------
diff --git a/src/master/main.cpp b/src/master/main.cpp
index e202973..0bce1df 100644
--- a/src/master/main.cpp
+++ b/src/master/main.cpp
@@ -540,8 +540,6 @@ int main(int argc, char** argv)
     slaveRemovalLimiter = new RateLimiter(permits.get(), duration.get());
   }
 
-  LOG(INFO) << "Starting Mesos master";
-
   Master* master =
     new Master(
       allocator.get(),

http://git-wip-us.apache.org/repos/asf/mesos/blob/961f29bf/src/master/master.cpp
----------------------------------------------------------------------
diff --git a/src/master/master.cpp b/src/master/master.cpp
index 060dc7f..17d5c58 100644
--- a/src/master/master.cpp
+++ b/src/master/master.cpp
@@ -1653,8 +1653,8 @@ Future<Nothing> Master::_recover(const Registry& registry)
 
   // Recovery is now complete!
   LOG(INFO) << "Recovered " << registry.slaves().slaves().size() << " agents"
-            << " from the Registry (" << Bytes(registry.ByteSize()) << ")"
-            << " ; allowing " << flags.agent_reregister_timeout
+            << " from the registry (" << Bytes(registry.ByteSize()) << ")"
+            << "; allowing " << flags.agent_reregister_timeout
             << " for agents to re-register";
 
   return Nothing();
@@ -1844,15 +1844,6 @@ void Master::detected(const Future<Option<MasterInfo>>& _leader)
   bool wasElected = elected();
   leader = _leader.get();
 
-  LOG(INFO) << "The newly elected leader is "
-            << (leader.isSome()
-                ? (leader.get().pid() + " with id " + leader.get().id())
-                : "None");
-
-  if (wasElected && !elected()) {
-    EXIT(EXIT_FAILURE) << "Lost leadership... committing suicide!";
-  }
-
   if (elected()) {
     electedTime = Clock::now();
 
@@ -1868,6 +1859,16 @@ void Master::detected(const Future<Option<MasterInfo>>& _leader)
       // but the same leading master is elected as leader.
       LOG(INFO) << "Re-elected as the leading master";
     }
+  } else {
+    // A different node has been elected as the leading master.
+    LOG(INFO) << "The newly elected leader is "
+              << (leader.isSome()
+                  ? (leader.get().pid() + " with id " + leader.get().id())
+                  : "None");
+
+    if (wasElected) {
+      EXIT(EXIT_FAILURE) << "Lost leadership... committing suicide!";
+    }
   }
 
   // Keep detecting.

http://git-wip-us.apache.org/repos/asf/mesos/blob/961f29bf/src/master/registrar.cpp
----------------------------------------------------------------------
diff --git a/src/master/registrar.cpp b/src/master/registrar.cpp
index 4589d2f..4d1eaa0 100644
--- a/src/master/registrar.cpp
+++ b/src/master/registrar.cpp
@@ -329,7 +329,7 @@ string RegistrarProcess::registryHelp()
 Future<Registry> RegistrarProcess::recover(const MasterInfo& info)
 {
   if (recovered.isNone()) {
-    LOG(INFO) << "Recovering registrar";
+    VLOG(1) << "Recovering registrar";
 
     metrics.state_fetch.start();
     state->fetch<Registry>("registry")


[2/5] mesos git commit: Fixed quoting for executor IDs in log messages.

Posted by an...@apache.org.
Fixed quoting for executor IDs in log messages.

Executor IDs should be quoted.

Review: https://reviews.apache.org/r/50516/


Project: http://git-wip-us.apache.org/repos/asf/mesos/repo
Commit: http://git-wip-us.apache.org/repos/asf/mesos/commit/9417ae4c
Tree: http://git-wip-us.apache.org/repos/asf/mesos/tree/9417ae4c
Diff: http://git-wip-us.apache.org/repos/asf/mesos/diff/9417ae4c

Branch: refs/heads/master
Commit: 9417ae4cd36e1bff55c75391a49b9a89dfbe554d
Parents: 9eea27c
Author: Neil Conway <ne...@gmail.com>
Authored: Tue Aug 2 09:36:18 2016 -0700
Committer: Anand Mazumdar <an...@apache.org>
Committed: Tue Aug 2 09:36:18 2016 -0700

----------------------------------------------------------------------
 src/master/validation.cpp | 12 ++++++------
 src/slave/slave.cpp       |  8 ++++----
 2 files changed, 10 insertions(+), 10 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/mesos/blob/9417ae4c/src/master/validation.cpp
----------------------------------------------------------------------
diff --git a/src/master/validation.cpp b/src/master/validation.cpp
index f834376..af18e5a 100644
--- a/src/master/validation.cpp
+++ b/src/master/validation.cpp
@@ -645,9 +645,9 @@ Option<Error> validateResourceUsage(
     Option<double> cpus =  executorResources.cpus();
     if (cpus.isNone() || cpus.get() < MIN_CPUS) {
       LOG(WARNING)
-        << "Executor " << stringify(task.executor().executor_id())
-        << " for task " << stringify(task.task_id())
-        << " uses less CPUs ("
+        << "Executor '" << task.executor().executor_id()
+        << "' for task '" << task.task_id()
+        << "' uses less CPUs ("
         << (cpus.isSome() ? stringify(cpus.get()) : "None")
         << ") than the minimum required (" << MIN_CPUS
         << "). Please update your executor, as this will be mandatory "
@@ -657,9 +657,9 @@ Option<Error> validateResourceUsage(
     Option<Bytes> mem = executorResources.mem();
     if (mem.isNone() || mem.get() < MIN_MEM) {
       LOG(WARNING)
-        << "Executor " << stringify(task.executor().executor_id())
-        << " for task " << stringify(task.task_id())
-        << " uses less memory ("
+        << "Executor '" << task.executor().executor_id()
+        << "' for task '" << task.task_id()
+        << "' uses less memory ("
         << (mem.isSome() ? stringify(mem.get().megabytes()) : "None")
         << ") than the minimum required (" << MIN_MEM
         << "). Please update your executor, as this will be mandatory "

http://git-wip-us.apache.org/repos/asf/mesos/blob/9417ae4c/src/slave/slave.cpp
----------------------------------------------------------------------
diff --git a/src/slave/slave.cpp b/src/slave/slave.cpp
index c19a63e..7e2e89b 100644
--- a/src/slave/slave.cpp
+++ b/src/slave/slave.cpp
@@ -1964,7 +1964,7 @@ void Slave::runTasks(
   // when the original instance of the executor was shutting down.
   if (executor->containerId != containerId) {
     LOG(WARNING) << "Ignoring sending queued tasks '" << taskIds
-                 << " to executor " << *executor
+                 << "' to executor " << *executor
                  << " because the target container " << containerId
                  << " has exited";
     return;
@@ -5757,12 +5757,12 @@ Executor* Framework::launchExecutor(
   }
 
   CHECK(!executors.contains(executorInfo.executor_id()))
-    << "Unknown executor " << executorInfo.executor_id();
+    << "Unknown executor '" << executorInfo.executor_id() << "'";
 
   executors[executorInfo.executor_id()] = executor;
 
-  LOG(INFO) << "Launching executor " << executorInfo.executor_id()
-            << " of framework " << id()
+  LOG(INFO) << "Launching executor '" << executorInfo.executor_id()
+            << "' of framework " << id()
             << " with resources " << executorInfo.resources()
             << " in work directory '" << directory << "'";
 


[5/5] mesos git commit: Made the JSON snippets complete in the Scheduler HTTP API doc.

Posted by an...@apache.org.
Made the JSON snippets complete in the Scheduler HTTP API doc.

Review: https://reviews.apache.org/r/50626/


Project: http://git-wip-us.apache.org/repos/asf/mesos/repo
Commit: http://git-wip-us.apache.org/repos/asf/mesos/commit/74e95984
Tree: http://git-wip-us.apache.org/repos/asf/mesos/tree/74e95984
Diff: http://git-wip-us.apache.org/repos/asf/mesos/diff/74e95984

Branch: refs/heads/master
Commit: 74e9598482b4c02f9e7ddf63ad5db6ddf08cccf2
Parents: f9b0558
Author: Abhishek Dasgupta <a1...@linux.vnet.ibm.com>
Authored: Tue Aug 2 09:37:13 2016 -0700
Committer: Anand Mazumdar <an...@apache.org>
Committed: Tue Aug 2 09:37:13 2016 -0700

----------------------------------------------------------------------
 docs/scheduler-http-api.md | 86 ++++++++++++++++++++++++++++++++---------
 1 file changed, 67 insertions(+), 19 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/mesos/blob/74e95984/docs/scheduler-http-api.md
----------------------------------------------------------------------
diff --git a/docs/scheduler-http-api.md b/docs/scheduler-http-api.md
index 4be9612..504872e 100644
--- a/docs/scheduler-http-api.md
+++ b/docs/scheduler-http-api.md
@@ -42,8 +42,8 @@ For example, a stream may look like:
 
 ```
 128\n
-{"type": "SUBSCRIBED","subscribed": {"framework_id": {"value":"12220-3440-12532-2345"},...}104\n
-{"framework_id": {"value": "12220-3440-12532-2345"},...{"value" : "12220-3440-12532-O12"},}208\n
+{"type": "SUBSCRIBED","subscribed": {"framework_id": {"value":"12220-3440-12532-2345"},"heartbeat_interval_seconds":15.0}20\n
+{"type":"HEARTBEAT"}675\n
 ...
 ```
 
@@ -152,15 +152,48 @@ Content-Type: application/json
 Mesos-Stream-Id: 130ae4e3-6b13-4ef4-baa9-9f2e85c3e9af
 
 {
-  "framework_id"	: {"value" : "12220-3440-12532-2345"},
-  "type"			: "ACCEPT",
-  "accept"			: {
-    "offer_ids"		: [
-                       {"value" : "12220-3440-12532-O12"},
-                       {"value" : "12220-3440-12532-O12"}
-                      ],
-    "operations"	: [ {"type" : "LAUNCH", "launch" : {...}} ],
-    "filters"		: {...}
+  "framework_id"   : {"value" : "12220-3440-12532-2345"},
+  "type"           : "ACCEPT",
+  "accept"         : {
+    "offer_ids"    : [
+                      {"value" : "12220-3440-12532-O12"}
+                     ],
+     "operations"  : [
+                      {
+                       "type"         : "LAUNCH",
+                       "launch"       : {
+                         "task_infos" : [
+                                         {
+                                          "name"        : "My Task",
+                                          "task_id"     : {"value" : "12220-3440-12532-my-task"},
+                                          "agent_id"    : {"value" : "12220-3440-12532-S1233"},
+                                          "executor"    : {
+                                            "command"     : {
+                                              "shell"     : true,
+                                              "value"     : "sleep 1000"
+                                            },
+                                            "executor_id" : {"value" : "12214-23523-my-executor"}
+                                          },
+                                          "resources"   : [
+                                                           {
+                                                            "name"  : "cpus",
+						            "role"  : "*",
+						            "type"  : "SCALAR",
+						            "scalar": {"value": 1.0}
+					                   },
+                                                           {
+						            "name"  : "mem",
+						            "role"  : "*",
+						            "type"  : "SCALAR",
+						            "scalar": {"value": 128.0}
+					                   }
+                                                          ]
+                                         }
+                                        ]
+                       }
+                      }
+                     ],
+     "filters"     : {"refuse_seconds" : 5.0}
   }
 }
 
@@ -188,7 +221,7 @@ Mesos-Stream-Id: 130ae4e3-6b13-4ef4-baa9-9f2e85c3e9af
                    {"value" : "12220-3440-12532-O12"},
                    {"value" : "12220-3440-12532-O13"}
                   ],
-    "filters"	: {...}
+    "filters"	: {"refuse_seconds" : 5.0}
   }
 }
 
@@ -396,13 +429,28 @@ OFFERS Event (JSON)
   "type"	: "OFFERS",
   "offers"	: [
     {
-      "offer_id":{"value": "12214-23523-O235235"},
-      "framework_id":{"value": "12124-235325-32425"},
-      "agent_id":{"value": "12325-23523-S23523"},
-      "hostname":"agent.host",
-      "resources":[...],
-      "attributes":[...],
-      "executor_ids":[]
+      "offer_id"     : {"value": "12214-23523-O235235"},
+      "framework_id" : {"value": "12124-235325-32425"},
+      "agent_id"     : {"value": "12325-23523-S23523"},
+      "hostname"     : "agent.host",
+      "resources"    : [
+                        {
+                         "name"   : "cpus",
+                         "type"   : "SCALAR",
+                         "scalar" : {"value" : 2},
+                         "role"   : "*"
+                        }
+                       ],
+      "attributes"   : [
+                        {
+                         "name"   : "os",
+                         "type"   : "TEXT",
+                         "text"   : {"value" : "ubuntu16.04"}
+                        }
+                       ],
+      "executor_ids" : [
+                        {"value" : "12214-23523-my-executor"}
+                       ]
     }
   ]
 }