Add persist_logs flag to dev_appserver_main
This change was introduced in the 1.6.1 SDK.
@@ -82,6 +82,8 @@ Options:
--mysql_socket=PATH MySQL Unix socket file path.
Used by the Cloud SQL (rdbms) stub.
(Default '%(mysql_socket)s')
+ --persist_logs Enables storage of all request and application
+ logs to enable later access. (Default false).
--require_indexes Disallows queries that require composite indexes
not defined in index.yaml.
--search_indexes_path=PATH Path to file to use for storing Full Text Search
@@ -203,6 +205,7 @@ ARG_MYSQL_PASSWORD = 'mysql_password'
ARG_MYSQL_PORT = 'mysql_port'
ARG_MYSQL_SOCKET = 'mysql_socket'
ARG_MYSQL_USER = 'mysql_user'
+ARG_PERSIST_LOGS = 'persist_logs'
ARG_PORT = 'port'
ARG_PROSPECTIVE_SEARCH_PATH = 'prospective_search_path'
ARG_REQUIRE_INDEXES = 'require_indexes'
@@ -264,6 +267,7 @@ DEFAULT_ARGS = {
ARG_MYSQL_PORT: 3306,
ARG_MYSQL_SOCKET: '',
ARG_MYSQL_USER: '',
+ ARG_PERSIST_LOGS: False,
ARG_PORT: 8080,
ARG_PROSPECTIVE_SEARCH_PATH: os.path.join(tempfile.gettempdir(),
'dev_appserver.prospective_search'),
@@ -324,6 +328,7 @@ LONG_OPTIONS = [
'mysql_port=',
'mysql_socket=',
'mysql_user=',
+ 'persist_logs',
'port=',
'require_indexes',
'search_indexes_path=',
@@ -515,6 +520,9 @@ def ParseArguments(argv):
if option == '--trusted':
option_dict[ARG_TRUSTED] = True
+ if option == '--persist_logs':
+ option_dict[ARG_PERSIST_LOGS] = True
+
if option == '--backends':
option_dict[ARG_BACKENDS] = value
if option == '--multiprocess':
@@ -701,6 +709,7 @@ def main(argv):
address = option_dict[ARG_ADDRESS]
allow_skipped_files = option_dict[ARG_ALLOW_SKIPPED_FILES]
static_caching = option_dict[ARG_STATIC_CACHING]
+ persist_logs = option_dict[ARG_PERSIST_LOGS]
skip_sdk_update_check = option_dict[ARG_SKIP_SDK_UPDATE_CHECK]
interactive_console = option_dict[ARG_CONSOLE]
@@ -735,6 +744,7 @@ def main(argv):
allow_skipped_files=allow_skipped_files,
static_caching=static_caching,
default_partition=default_partition,
+ persist_logs=persist_logs,
frontend_port= None,
interactive_console=interactive_console,
secret_hash = hashlib.sha1(appinfo.application + '/' + \
