:param workDir: :return:
(workDir)
| 37 | |
| 38 | |
| 39 | def start_tablet_server(workDir): |
| 40 | """ |
| 41 | |
| 42 | :param workDir: |
| 43 | :return: |
| 44 | """ |
| 45 | binDir = get('BIN_DIR') |
| 46 | logfile = os.path.join(workDir, 'run.log') |
| 47 | cmd = 'cd %(binDir)s && ./rtidb --role=tablet >%(logfile)s 2>&1 &' % locals() |
| 48 | p = Process() |
| 49 | data, error, retCode = p.run(cmd) |
| 50 | if 0 != retCode: |
| 51 | raise Exception('Start tablet server error: %s' % FileUtils.read(logfile)) |
| 52 | |
| 53 | |
| 54 | def inspect_get(data, type): |