# Server API settings


# service.disable_global_exit_handling = 1

service.port =  8080
#service.port =  8001
service.procs = 0
service.ip = "127.0.0.1"
#service.ip = "0.0.0.0"
#service.socket = "/tmp/scgi.socket"     # Default is "" -- use default socket given
service.worker_threads = 5
#service.api = "fastcgi"			
service.api = "http"			
						# fastcgi -- preferred API
						# scgi	  -- simplefied FCGI API -- yet another alternative
						# cgi	  -- Use only in case you application does huge amount of work
						#            such the fork()+exec() time in neligable
						#            Recomended for debug purposes only

http.script_names = { "/stock" "/hello" }

# Server work mode

server.mod="thread"				# process -- process runs single instance of worker thread. Very simple 
						#	     suitable for server that manages process startup/shutdown
						#	     This is only mod that supports CGI api
						# thread  -- thread pool execute several instances of worker. More dengerous
						# 	     in terms of faults -- thread crashes causes server crash
						# prefork -- "Apache Style" module -- the process forks into several 
						# 	     worker process and each worker thread has its own process

# server.procs = 5				# Default 5 -- Number of worker process for mod prefork
# server.threads = 5				# Default 5 -- Number of worker threads for mod thread

server.buffer = 100				# Default 1 -- relevant for multi-threaded model
						#              How many requests may be "on-hold" even if
						#              thread pool is full. Also sets "listen(2) backlog parameter

						#              by web server -

# server.disable_xpowered_by	= 0		# Disable X-Powered-By header (default enabled)
# server.buffer_reserve		= 16000		# Set default inital buffer size of output page
						# Default is 16,000 -- set to cover most of page
						# sizes that are used by your CMS

# ZLib Compression: 

# gzip.enable = 0				# Default 0 -- Enable gzip compression recomended to turn on
# gzip.level = 1				# Default: zlib defailt, defines compression level 
# gzip.buffer = 4096				# Default: zlib default, defines buffer size for zlib

# cache.backend = "threaded"			# Default "none" -- defines the cache backend to be used 
						#        "threaded" inprocess server suitable only for mod thread
						#	 "fork"     suitable for mod prefork only uses shared memory
						#	 "tcp"      distributed suitable for any other mod
						#
## threaded cache parameters
# cache.limit = 100				# Default 100 -- number of cached entries for cache threaded
#
## fork cache parameters
# cache.memsize = 64				# Default 64  -- the size of cache in KB for "fork" cache backend
# cache.file = "/tmp/mymem"			# The location of cache mmaped file/semaphore
#
## tcp cache parameters
# cache.ips = { "192.168.0.1" "192.168.0.2" }	# The IP addresses of tcp_cache_servers -- no default value!
# cache.ports = { 12000 12000 }			# The ports tcp_cache_servers listen on
						# Make sure all servers occure in SAME order in all clients


# Localization
locale.locales ={ "he_IL.UTF-8" "en_US.UTF-8" }	# list of supported languages
locale.default =  "he_IL.UTF-8"			# default language (default first one)
locale.gettext_domains = { "app" "test" }	# list of supported domains
locale.default_gettext_domain = "test"		# default domain (default first one)
locale.gettext_path="./transtext/locale"	# path to locale directory


# General Session settings
# Default Expiration

session.expire = "browser"			# "browser" "renew" "fixed"
session.timeout = 10 				# 24*3600

# session.cookies_prefix = "cppcms_session"
# session.cookies_domain = ""
# session.cookies_path = "/"
# session.cookies_secure = 0

session.location = "client" 			# "none" "client" "server" "both" default none
#session.client_size_limit = 64		# The threshold for clinet/server storage defaul 2048


# Clinet side storage configuration
#session.cookies_encryptor = "hmac"		# "hmac" "aes" -- default "aes" unless unsupported
						# hmac -- Preserves consistency
						# aes  ---Preserves consistency and secrecy 
session.cookies_key = "126ba5b3f9c7d5a0b75f135c46cec946"
						# Secret Private key: 32 hexadeximal digits


#session.backend = "files"			# Server side storage backend: "cache", "files", "sqlite", "tcp"
						#	default -- "files"
						# cache  -- does not preserverd withing restarti!!!
						#           It is actually "empty" backend with enabled cache
						# files  -- save information in "files_dir" directory
						# sqlite -- save information in sqlite DB
						# tcp    -- save information over distributed storage

#session.server_enable_cache = 0		# Add standard caching layer over storage backend
						# May improve performance when working with "heavy sorages"
						# like databases or files --- default disabled

#session.files_comp = "thread"			# Serialization method for file backend
						# "thread"  -- safe for use with thread mod uses in memory mutexes
						# "prefork" -- safe for use with prefork mod -- uses shared
						#              memory with mutexes 
						# "nfs"     -- uses fcntl locking, safe for use over NFS when
						#              locking is supported and enabled 
						#              allows sharing cache data over distributed network
						# default   -- according to "mod"

session.files_dir = "./sessions"		# Location of session date for file backend
						# default getenv("TMP")+/cppcms_sessions
session.files_gc_frequency = 3600		# Frequency of "garbage collection" --- cleaning sessions that
						# had allready "time out". Default -1 --- disabled
session.sqlite_db = "./sessions/s.db"		# The base name of slite DB for the sqlite storage
session.tcp_ips = { "127.0.0.1" }
session.tcp_ports = { 3000 }


file_server.enable = 1
#file_server.doument_root = "C:\cygwin\home\artyom\Projects\cppcms\framework-refactoring"
#file_server.mime_types = "mime.type"
