mirror of
https://git.yoctoproject.org/poky
synced 2026-04-04 14:02:22 +02:00
bitbake: server/process: Pass timeout/xmlrpc parameters directly to the server
Further cleanup, just pass these settings directly. (Bitbake rev: ac2284357f1fc7044dac9c146fad218fc9906412) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
@@ -38,7 +38,7 @@ class ProcessServer():
|
||||
profile_filename = "profile.log"
|
||||
profile_processed_filename = "profile.log.processed"
|
||||
|
||||
def __init__(self, lock, sock, sockname):
|
||||
def __init__(self, lock, sock, sockname, server_timeout, xmlrpcinterface):
|
||||
self.command_channel = False
|
||||
self.command_channel_reply = False
|
||||
self.quit = False
|
||||
@@ -57,6 +57,9 @@ class ProcessServer():
|
||||
self.sock = sock
|
||||
self.sockname = sockname
|
||||
|
||||
self.server_timeout = server_timeout
|
||||
self.xmlrpcinterface = xmlrpcinterface
|
||||
|
||||
def register_idle_function(self, function, data):
|
||||
"""Register a function to be called while the server is idle"""
|
||||
assert hasattr(function, '__call__')
|
||||
@@ -466,7 +469,7 @@ class BitBakeServer(object):
|
||||
print(self.start_log_format % (os.getpid(), datetime.datetime.now().strftime(self.start_log_datetime_format)))
|
||||
sys.stdout.flush()
|
||||
|
||||
server = ProcessServer(self.bitbake_lock, self.sock, self.sockname)
|
||||
server = ProcessServer(self.bitbake_lock, self.sock, self.sockname, self.configuration.server_timeout, self.configuration.xmlrpcinterface)
|
||||
os.close(self.readypipe)
|
||||
writer = ConnectionWriter(self.readypipein)
|
||||
try:
|
||||
@@ -476,8 +479,6 @@ class BitBakeServer(object):
|
||||
writer.send("r")
|
||||
writer.close()
|
||||
server.cooker = self.cooker
|
||||
server.server_timeout = self.configuration.server_timeout
|
||||
server.xmlrpcinterface = self.configuration.xmlrpcinterface
|
||||
print("Started bitbake server pid %d" % os.getpid())
|
||||
sys.stdout.flush()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user