Updated simple_ssl example to use directly the standalone connector,
and use the new WSF_STANDALONE_SERVICE_OPTIONS class. Added WSF_STANDALONE_SERVICE to make it easy to use directly.
This commit is contained in:
@@ -1,13 +1,13 @@
|
||||
note
|
||||
description : "simple application root class"
|
||||
date : "$Date$"
|
||||
revision : "$Revision$"
|
||||
description: "simple application root class"
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
class
|
||||
APPLICATION
|
||||
|
||||
inherit
|
||||
WSF_DEFAULT_SERVICE [APPLICATION_EXECUTION]
|
||||
WSF_STANDALONE_SERVICE [APPLICATION_EXECUTION]
|
||||
redefine
|
||||
initialize
|
||||
end
|
||||
@@ -19,11 +19,17 @@ feature {NONE} -- Initialization
|
||||
|
||||
initialize
|
||||
-- Initialize current service.
|
||||
local
|
||||
opts: WSF_STANDALONE_SERVICE_OPTIONS
|
||||
do
|
||||
-- Specific to `standalone' connector (the EiffelWeb server).
|
||||
-- See `{WSF_STANDALONE_SERVICE_LAUNCHER}.initialize'
|
||||
set_service_option ("port", 9090)
|
||||
import_service_options (create {WSF_SERVICE_LAUNCHER_OPTIONS_FROM_INI}.make_from_file ("simple.ini"))
|
||||
create opts
|
||||
opts.port := 9090
|
||||
opts.socket_recv_timeout := 5 -- seconds
|
||||
|
||||
opts.import_ini_file_options ("simple.ini")
|
||||
import_service_options (opts)
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
<setting name="concurrency" value="scoop"/>
|
||||
<variable name="ssl_enabled" value="true"/>
|
||||
<library name="base" location="$ISE_LIBRARY\library\base\base-safe.ecf"/>
|
||||
<library name="default_standalone" location="..\..\library\server\wsf\default\standalone-safe.ecf"/>
|
||||
<library name="wsf_standalone" location="..\..\library\server\wsf\connector\standalone-safe.ecf"/>
|
||||
<library name="http" location="..\..\library\network\protocol\http\http-safe.ecf"/>
|
||||
<library name="wsf" location="..\..\library\server\wsf\wsf-safe.ecf"/>
|
||||
<cluster name="simple" location=".\" recursive="true"/>
|
||||
|
||||
@@ -0,0 +1,24 @@
|
||||
note
|
||||
description: "[
|
||||
Service using standalone connector launcher.
|
||||
]"
|
||||
author: "$Author$"
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
class
|
||||
WSF_STANDALONE_SERVICE [G -> WSF_EXECUTION create make end]
|
||||
|
||||
inherit
|
||||
WSF_LAUNCHABLE_SERVICE
|
||||
|
||||
feature {NONE} -- Initialization
|
||||
|
||||
launch (opts: detachable WSF_SERVICE_LAUNCHER_OPTIONS)
|
||||
local
|
||||
l_launcher: WSF_STANDALONE_SERVICE_LAUNCHER [G]
|
||||
do
|
||||
create l_launcher.make_and_launch (opts)
|
||||
end
|
||||
|
||||
end
|
||||
Reference in New Issue
Block a user