Example #1
0
 def testCleanupArgsString(self):
     sysDirMgr = MRSystemDirectoryManager(1234, '/user/hod/mapredsystem/hoduser.123.abc.com', \
                                           'def.com:5678', '/usr/bin/hadoop', self.log)
     str = sysDirMgr.toCleanupArgs()
     self.assertTrue(
         " --jt-pid 1234 --mr-sys-dir /user/hod/mapredsystem/hoduser.123.abc.com --fs-name def.com:5678 --hadoop-path /usr/bin/hadoop ",
         str)
 def testUnresponsiveJobTracker(self):
   # simulate an unresponsive job tracker, by giving a command that runs longer than the retries
   # verify that the program returns with the right error message.
   sc = simpleCommand("sleep", "sleep 300")
   sc.start()
   pid = sc.getPid()
   while pid is None:
     pid = sc.getPid()
   sysDirMgr = MRSystemDirectoryManager(pid, '/user/yhemanth/mapredsystem/hoduser.123.abc.com', \
                                               'def.com:5678', '/usr/bin/hadoop', self.log, retries=3)
   sysDirMgr.removeMRSystemDirectory()
   self.log.hasMessage("Job Tracker did not exit even after a minute. Not going to try and cleanup the system directory", 'warn')
   sc.kill()
   sc.wait()
   sc.join()
Example #3
0
 def testUnresponsiveJobTracker(self):
     # simulate an unresponsive job tracker, by giving a command that runs longer than the retries
     # verify that the program returns with the right error message.
     sc = simpleCommand("sleep", "sleep 300")
     sc.start()
     pid = sc.getPid()
     while pid is None:
         pid = sc.getPid()
     sysDirMgr = MRSystemDirectoryManager(pid, '/user/yhemanth/mapredsystem/hoduser.123.abc.com', \
                                                 'def.com:5678', '/usr/bin/hadoop', self.log, retries=3)
     sysDirMgr.removeMRSystemDirectory()
     self.log.hasMessage(
         "Job Tracker did not exit even after a minute. Not going to try and cleanup the system directory",
         'warn')
     sc.kill()
     sc.wait()
     sc.join()
 def testCleanupArgsString(self):
   sysDirMgr = MRSystemDirectoryManager(1234, '/user/hod/mapredsystem/hoduser.123.abc.com', \
                                         'def.com:5678', '/usr/bin/hadoop', self.log)
   str = sysDirMgr.toCleanupArgs()
   self.assertTrue(" --jt-pid 1234 --mr-sys-dir /user/hod/mapredsystem/hoduser.123.abc.com --fs-name def.com:5678 --hadoop-path /usr/bin/hadoop ", str)