From 108ab430318a0334b3c4ef638032726eed10fa44 Mon Sep 17 00:00:00 2001 From: Jocelyn Fiat Date: Fri, 23 Nov 2012 18:56:09 +0100 Subject: [PATCH 01/27] Made encoder and error library compilable with 6.8 --- library/text/encoder/encoder-safe.ecf | 8 ++++---- library/text/encoder/encoder.ecf | 2 +- library/utility/general/error/error-safe.ecf | 2 +- library/utility/general/error/error.ecf | 2 +- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/library/text/encoder/encoder-safe.ecf b/library/text/encoder/encoder-safe.ecf index 7db8d66c..513e1e4e 100644 --- a/library/text/encoder/encoder-safe.ecf +++ b/library/text/encoder/encoder-safe.ecf @@ -1,5 +1,5 @@ - + @@ -7,7 +7,7 @@ /EIFGENs$ /.svn$ - @@ -17,12 +17,12 @@ /tests$ /spec$ - + - + diff --git a/library/text/encoder/encoder.ecf b/library/text/encoder/encoder.ecf index 5c3184fc..71732816 100644 --- a/library/text/encoder/encoder.ecf +++ b/library/text/encoder/encoder.ecf @@ -7,7 +7,7 @@ /EIFGENs$ /.svn$ - diff --git a/library/utility/general/error/error-safe.ecf b/library/utility/general/error/error-safe.ecf index b5eb8493..e6da0b5a 100644 --- a/library/utility/general/error/error-safe.ecf +++ b/library/utility/general/error/error-safe.ecf @@ -7,7 +7,7 @@ /EIFGENs$ /.svn$ - diff --git a/library/utility/general/error/error.ecf b/library/utility/general/error/error.ecf index ea7b6080..f21ea9b9 100644 --- a/library/utility/general/error/error.ecf +++ b/library/utility/general/error/error.ecf @@ -7,7 +7,7 @@ /EIFGENs$ /.svn$ - From 63b4f6509e5f06bd20d3faac933ecd6ea8a2f9cf Mon Sep 17 00:00:00 2001 From: Jocelyn Fiat Date: Sun, 25 Nov 2012 17:28:27 +0100 Subject: [PATCH 02/27] Fixed compilation due to recent changes from http_client and corrected design. --- examples/restbucksCRUD/client/src/restbuck_client.e | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/examples/restbucksCRUD/client/src/restbuck_client.e b/examples/restbucksCRUD/client/src/restbuck_client.e index c325e5c3..22f84bbd 100644 --- a/examples/restbucksCRUD/client/src/restbuck_client.e +++ b/examples/restbucksCRUD/client/src/restbuck_client.e @@ -17,7 +17,7 @@ feature {NONE} -- Initialization local h: LIBCURL_HTTP_CLIENT sess: HTTP_CLIENT_SESSION - resp : HTTP_CLIENT_RESPONSE + resp : detachable HTTP_CLIENT_RESPONSE l_location : detachable READABLE_STRING_8 body : STRING do @@ -39,7 +39,7 @@ feature {NONE} -- Initialization -- Update the Order - if attached resp.body as l_body then + if resp /= Void and then attached resp.body as l_body then body := l_body.as_string_8 body.replace_substring_all ("takeAway", "in Shop") print ("%N Update Order %N") @@ -47,11 +47,10 @@ feature {NONE} -- Initialization end end - update_order ( sess: HTTP_CLIENT_SESSION; uri : detachable READABLE_STRING_8; a_body : STRING) : HTTP_CLIENT_RESPONSE + update_order ( sess: HTTP_CLIENT_SESSION; uri : detachable READABLE_STRING_8; a_body : STRING): detachable HTTP_CLIENT_RESPONSE local context : HTTP_CLIENT_REQUEST_CONTEXT do - create Result.make if attached uri as l_uri then sess.set_base_url (l_uri) create context.make @@ -74,9 +73,8 @@ feature {NONE} -- Initialization end - read_order ( sess: HTTP_CLIENT_SESSION; uri : detachable READABLE_STRING_8) : HTTP_CLIENT_RESPONSE + read_order ( sess: HTTP_CLIENT_SESSION; uri : detachable READABLE_STRING_8): detachable HTTP_CLIENT_RESPONSE do - create Result.make if attached uri as l_uri then sess.set_base_url (l_uri) Result := sess.get ("", Void) From f18ef477b8e8051f7c9ca13994f052735e72603b Mon Sep 17 00:00:00 2001 From: Jocelyn Fiat Date: Sun, 25 Nov 2012 21:30:10 +0100 Subject: [PATCH 03/27] Included the library base(-safe).ecf which was forgotten by mistake. --- library/server/wsf/default/cgi-safe.ecf | 1 + library/server/wsf/default/cgi.ecf | 1 + library/server/wsf/default/libfcgi-safe.ecf | 1 + library/server/wsf/default/libfcgi.ecf | 1 + library/server/wsf/default/nino-safe.ecf | 1 + library/server/wsf/default/nino.ecf | 1 + 6 files changed, 6 insertions(+) diff --git a/library/server/wsf/default/cgi-safe.ecf b/library/server/wsf/default/cgi-safe.ecf index f10d0274..ed590547 100644 --- a/library/server/wsf/default/cgi-safe.ecf +++ b/library/server/wsf/default/cgi-safe.ecf @@ -8,6 +8,7 @@ /\.svn$ diff --git a/library/server/wsf/wsf_extension.ecf b/library/server/wsf/wsf_extension.ecf index e3622f9b..cef881de 100644 --- a/library/server/wsf/wsf_extension.ecf +++ b/library/server/wsf/wsf_extension.ecf @@ -12,7 +12,7 @@ - + diff --git a/library/server/wsf/wsf_session-safe.ecf b/library/server/wsf/wsf_session-safe.ecf index 0c679d78..b94c5e7a 100644 --- a/library/server/wsf/wsf_session-safe.ecf +++ b/library/server/wsf/wsf_session-safe.ecf @@ -14,7 +14,7 @@ - + diff --git a/library/server/wsf/wsf_session.ecf b/library/server/wsf/wsf_session.ecf index 5c2e26b0..f085bc3b 100644 --- a/library/server/wsf/wsf_session.ecf +++ b/library/server/wsf/wsf_session.ecf @@ -14,7 +14,7 @@ - + From 156406f9acda66283cbef47243050ec34cca6642 Mon Sep 17 00:00:00 2001 From: Jocelyn Fiat Date: Mon, 3 Dec 2012 12:20:12 +0100 Subject: [PATCH 08/27] Fixed various compilation issue with new self documentation Improved the self documentation handler to provide a make_hidden creation procedure --- examples/restbucksCRUD/src/restbucks_server.e | 7 ++++++ .../context/wsf_router_context_mapping.e | 2 +- .../wsf_router_self_documentation_handler.e | 23 ++++++++++++++++++- .../starts_with/wsf_starts_with_mapping.e | 2 ++ .../wsf_uri_template_context_mapping.e | 3 +++ .../server/wsf/router/wsf_routed_service.e | 6 ++++- 6 files changed, 40 insertions(+), 3 deletions(-) diff --git a/examples/restbucksCRUD/src/restbucks_server.e b/examples/restbucksCRUD/src/restbucks_server.e index ad1beb4d..79870862 100644 --- a/examples/restbucksCRUD/src/restbucks_server.e +++ b/examples/restbucksCRUD/src/restbucks_server.e @@ -10,6 +10,9 @@ inherit ANY WSF_URI_TEMPLATE_ROUTED_SERVICE + redefine + execute_default + end WSF_HANDLER_HELPER @@ -30,10 +33,13 @@ feature {NONE} -- Initialization setup_router local order_handler: ORDER_HANDLER + doc: WSF_ROUTER_SELF_DOCUMENTATION_HANDLER do create order_handler router.handle_with_request_methods ("/order", order_handler, router.methods_POST) router.handle_with_request_methods ("/order/{orderid}", order_handler, router.methods_GET + router.methods_DELETE + router.methods_PUT) + create doc.make_hidden (router) + router.handle_with_request_methods ("/api/doc", doc, router.methods_GET) end feature -- Execution @@ -54,6 +60,7 @@ feature -- Execution h.put_content_type_text_plain l_api_doc := "%NPlease check the API%NURI:/order METHOD: POST%NURI:/order/{orderid} METHOD: GET, PUT, DELETE%N" l_description := req.request_method + req.request_uri + " is not allowed" + "%N" + l_api_doc + l_description.append ("%NHTML documentation:/api/doc METHOD: GET%N") h.put_content_length (l_description.count) h.put_current_date res.set_status_code ({HTTP_STATUS_CODE}.method_not_allowed) diff --git a/library/server/wsf/router/context/wsf_router_context_mapping.e b/library/server/wsf/router/context/wsf_router_context_mapping.e index 92c1f23f..bf7f8895 100644 --- a/library/server/wsf/router/context/wsf_router_context_mapping.e +++ b/library/server/wsf/router/context/wsf_router_context_mapping.e @@ -25,7 +25,7 @@ feature -- Status report debug_output: STRING -- String that should be displayed in debugger to represent `Current'. do - Result := Precursor + " {" + {C}.name + "}" + Result := Precursor + " {" + ({C}).name + "}" end note diff --git a/library/server/wsf/router/documentation/wsf_router_self_documentation_handler.e b/library/server/wsf/router/documentation/wsf_router_self_documentation_handler.e index 427037f0..0de5d36b 100644 --- a/library/server/wsf/router/documentation/wsf_router_self_documentation_handler.e +++ b/library/server/wsf/router/documentation/wsf_router_self_documentation_handler.e @@ -17,8 +17,11 @@ inherit on_mapped end + WSF_SELF_DOCUMENTED_HANDLER + create - make + make, + make_hidden feature {NONE} -- Initialization @@ -27,10 +30,28 @@ feature {NONE} -- Initialization router := a_router end + make_hidden (a_router: WSF_ROUTER) + do + make (a_router) + is_hidden := True + end + router: WSF_ROUTER resource: detachable STRING + is_hidden: BOOLEAN + -- Current mapped handler should be hidden from self documentation + +feature -- Documentation + + mapping_documentation (m: WSF_ROUTER_MAPPING): WSF_ROUTER_MAPPING_DOCUMENTATION + do + create Result.make (m) + Result.set_is_hidden (is_hidden) + Result.add_description ("Self generated documentation based on the router's setup") + end + feature {WSF_ROUTER} -- Mapping on_mapped (a_mapping: WSF_ROUTER_MAPPING; a_rqst_methods: detachable WSF_ROUTER_METHODS) diff --git a/library/server/wsf/router/support/starts_with/wsf_starts_with_mapping.e b/library/server/wsf/router/support/starts_with/wsf_starts_with_mapping.e index e62ffb50..c152150e 100644 --- a/library/server/wsf/router/support/starts_with/wsf_starts_with_mapping.e +++ b/library/server/wsf/router/support/starts_with/wsf_starts_with_mapping.e @@ -10,6 +10,8 @@ class inherit WSF_ROUTER_MAPPING + WSF_SELF_DOCUMENTED_ROUTER_MAPPING + create make diff --git a/library/server/wsf/router/support/uri_template_with_context/wsf_uri_template_context_mapping.e b/library/server/wsf/router/support/uri_template_with_context/wsf_uri_template_context_mapping.e index fe2b56ca..98f27adf 100644 --- a/library/server/wsf/router/support/uri_template_with_context/wsf_uri_template_context_mapping.e +++ b/library/server/wsf/router/support/uri_template_with_context/wsf_uri_template_context_mapping.e @@ -11,6 +11,9 @@ inherit WSF_ROUTER_CONTEXT_MAPPING [C] WSF_SELF_DOCUMENTED_ROUTER_MAPPING + undefine + debug_output + end create make, diff --git a/library/server/wsf/router/wsf_routed_service.e b/library/server/wsf/router/wsf_routed_service.e index a2a83d8f..00dd52ab 100644 --- a/library/server/wsf/router/wsf_routed_service.e +++ b/library/server/wsf/router/wsf_routed_service.e @@ -47,7 +47,11 @@ feature -- Execution execute_default (req: WSF_REQUEST; res: WSF_RESPONSE) -- Default procedure - deferred + local + not_found: WSF_NOT_FOUND_RESPONSE + do + create not_found.make (req) + res.send (not_found) end feature -- Access From fc8188aeb1fcabfdb4624671083d6fa96acdb2a3 Mon Sep 17 00:00:00 2001 From: Olivier Ligot Date: Mon, 3 Dec 2012 16:29:12 +0100 Subject: [PATCH 09/27] Logging filter The logging filter is now part of EWF core (before it was only available in the filter example) and can therefore be reused by others needing it. Note that this is a first implementation. It can certainly be improved in the future to support more fine grained logging. --- examples/filter/src/filter_server.e | 2 +- .../wsf/router/filter/wsf_logging_filter.e | 21 ++++++++++++------- 2 files changed, 15 insertions(+), 8 deletions(-) rename examples/filter/src/filter/logging_filter.e => library/server/wsf/router/filter/wsf_logging_filter.e (55%) diff --git a/examples/filter/src/filter_server.e b/examples/filter/src/filter_server.e index fff542ac..25d16fef 100644 --- a/examples/filter/src/filter_server.e +++ b/examples/filter/src/filter_server.e @@ -53,7 +53,7 @@ feature {NONE} -- Initialization setup_filter -- Setup `filter' local - l_logging_filter: LOGGING_FILTER + l_logging_filter: WSF_LOGGING_FILTER do create l_logging_filter filter.set_next (l_logging_filter) diff --git a/examples/filter/src/filter/logging_filter.e b/library/server/wsf/router/filter/wsf_logging_filter.e similarity index 55% rename from examples/filter/src/filter/logging_filter.e rename to library/server/wsf/router/filter/wsf_logging_filter.e index e6a8b89b..66bdf8d7 100644 --- a/examples/filter/src/filter/logging_filter.e +++ b/library/server/wsf/router/filter/wsf_logging_filter.e @@ -5,7 +5,7 @@ note revision: "$Revision$" class - LOGGING_FILTER + WSF_LOGGING_FILTER inherit WSF_FILTER @@ -15,24 +15,31 @@ feature -- Basic operations execute (req: WSF_REQUEST; res: WSF_RESPONSE) -- Execute the filter local - l_user_agent: STRING + l_user_agent, l_referer: STRING l_date: DATE_TIME do if attached req.http_user_agent as ua then - l_user_agent := ua.as_string_8 + l_user_agent := "%"" + ua.as_string_8 + "%"" else l_user_agent := "-" end - create l_date.make_now - io.put_string ("[" + l_date.formatted_out (Date_time_format) + "] %"" + req.request_method + " " + req.request_uri - + " " + {HTTP_CONSTANTS}.http_version_1_1 + "%" " + res.status_code.out + " " + l_user_agent) + if attached req.http_referer as r then + l_referer := "%"" + r + "%" " + else + l_referer := "" + end + create l_date.make_now_utc + io.put_string (req.remote_addr + " - - [" + l_date.formatted_out (Date_time_format) + " GMT] %"" + + req.request_method + " " + req.request_uri + + " " + {HTTP_CONSTANTS}.http_version_1_1 + "%" " + res.status_code.out + " " + + res.transfered_content_length.out + " " + l_referer + l_user_agent) io.put_new_line execute_next (req, res) end feature -- Constants - Date_time_format: STRING = "yyyy/[0]mm/[0]dd [0]hh:[0]mi:[0]ss.ff3" + Date_time_format: STRING = "[0]dd/[0]mm/yyyy [0]hh:[0]mi:[0]ss" note copyright: "2011-2012, Olivier Ligot, Jocelyn Fiat and others" From e9376b5d16d3cbe469e10421cf29888516a3552f Mon Sep 17 00:00:00 2001 From: Olivier Ligot Date: Mon, 3 Dec 2012 17:37:26 +0100 Subject: [PATCH 10/27] Fix ise_wizard * ewf.ini was used instead of template.ecf as configuration file * remove initialize_router otherwise the compilation failed * remove unused variables --- tools/ise_wizard/resources/ewf_application.e | 5 ----- tools/ise_wizard/src/ewf_wizard.e | 5 ++--- 2 files changed, 2 insertions(+), 8 deletions(-) diff --git a/tools/ise_wizard/resources/ewf_application.e b/tools/ise_wizard/resources/ewf_application.e index af64909d..929cd433 100644 --- a/tools/ise_wizard/resources/ewf_application.e +++ b/tools/ise_wizard/resources/ewf_application.e @@ -26,8 +26,6 @@ feature -- Execution -- Default request handler if no other are relevant local mesg: WSF_HTML_PAGE_RESPONSE - s: STRING_8 - l_user_name: READABLE_STRING_32 do create mesg.make mesg.set_title ("Hello World!") @@ -44,9 +42,6 @@ feature {NONE} -- Initialization --| If you don't need any custom options, you are not obliged to redefine `initialize' Precursor - - --| Initialize router - initialize_router end end diff --git a/tools/ise_wizard/src/ewf_wizard.e b/tools/ise_wizard/src/ewf_wizard.e index 9d6f08a6..09bcdd21 100644 --- a/tools/ise_wizard/src/ewf_wizard.e +++ b/tools/ise_wizard/src/ewf_wizard.e @@ -119,15 +119,14 @@ feature -- Form tfn.add_extension ("ecf") copy_resource_template ("template.ecf", tfn.string) + create res.make (tfn.string, d.name) + create tfn.make_from_string (dn.string) tfn.set_file_name ("ewf") tfn.add_extension ("ini") copy_resource_template ("ewf.ini", tfn.string) - - create res.make (tfn.string, d.name) - create dn.make_from_string (pdn) dn.extend (pn) dn.extend ("src") From eb676bd14b54c98cd49d84d5eab1ae6ab8b84c42 Mon Sep 17 00:00:00 2001 From: Olivier Ligot Date: Tue, 4 Dec 2012 14:42:09 +0100 Subject: [PATCH 11/27] ise_wizard Unix shell scripts --- tools/ise_wizard/install_ise_wizard.sh | 15 +++++++++++++++ tools/ise_wizard/install_ise_wizard_custom.sh | 16 ++++++++++++++++ 2 files changed, 31 insertions(+) create mode 100755 tools/ise_wizard/install_ise_wizard.sh create mode 100755 tools/ise_wizard/install_ise_wizard_custom.sh diff --git a/tools/ise_wizard/install_ise_wizard.sh b/tools/ise_wizard/install_ise_wizard.sh new file mode 100755 index 00000000..9b5496ea --- /dev/null +++ b/tools/ise_wizard/install_ise_wizard.sh @@ -0,0 +1,15 @@ +#!/bin/sh + +mkdir tmp +ecb -config ewf_ise_wizard-safe.ecf -target wizard -finalize -c_compile -project_path tmp +mkdir -p spec/$ISE_PLATFORM +mv tmp/EIFGENs/wizard/F_code/wizard spec/$ISE_PLATFORM/wizard +rm -rf tmp + +WIZ_TARGET=$ISE_EIFFEL/studio/wizards/new_projects/ewf +rm -rf $WIZ_TARGET +mkdir $WIZ_TARGET +cp -r resources $WIZ_TARGET/resources +cp -r spec $WIZ_TARGET/spec +cp ewf.dsc $WIZ_TARGET/../ewf.dsc +rm -rf spec diff --git a/tools/ise_wizard/install_ise_wizard_custom.sh b/tools/ise_wizard/install_ise_wizard_custom.sh new file mode 100755 index 00000000..308e7d84 --- /dev/null +++ b/tools/ise_wizard/install_ise_wizard_custom.sh @@ -0,0 +1,16 @@ +#!/bin/sh + +mkdir tmp +ecb -config ewf_ise_wizard-safe.ecf -target custom_wizard -finalize -c_compile -project_path tmp +mkdir -p custom/spec/$ISE_PLATFORM +mv tmp/EIFGENs/custom_wizard/F_code/wizard custom/spec/$ISE_PLATFORM/wizard +rm -rf tmp + +WIZ_TARGET=$ISE_EIFFEL/studio/wizards/new_projects/ewf_custom +rm -rf $WIZ_TARGET +mkdir $WIZ_TARGET +cp -r resources $WIZ_TARGET/resources +cp -f custom/resources/* $WIZ_TARGET/resources +cp -r custom/spec $WIZ_TARGET/spec +cp custom/ewf.dsc $WIZ_TARGET/../ewf_custom.dsc +rm -rf custom/spec From bbf63c1cc063a9abb0f714bbfc32dc69b37d1805 Mon Sep 17 00:00:00 2001 From: Jocelyn Fiat Date: Wed, 5 Dec 2012 17:01:45 +0100 Subject: [PATCH 12/27] removed fcgi(-safe).ecf files ... since there renamed libfcgi(-safe).ecf --- library/server/libfcgi/fcgi-safe.ecf | 52 ---------------------------- library/server/libfcgi/fcgi.ecf | 52 ---------------------------- 2 files changed, 104 deletions(-) delete mode 100644 library/server/libfcgi/fcgi-safe.ecf delete mode 100644 library/server/libfcgi/fcgi.ecf diff --git a/library/server/libfcgi/fcgi-safe.ecf b/library/server/libfcgi/fcgi-safe.ecf deleted file mode 100644 index 18fd9512..00000000 --- a/library/server/libfcgi/fcgi-safe.ecf +++ /dev/null @@ -1,52 +0,0 @@ - - - - - - /\.svn$ - /\.git$ - /EIFGENs$ - - - - - - - - - - - - - - - - - - - - - - - - - - - - /linux$ - /fake$ - - - - - - /windows$ - /fake$ - - - - - - - diff --git a/library/server/libfcgi/fcgi.ecf b/library/server/libfcgi/fcgi.ecf deleted file mode 100644 index 05d15197..00000000 --- a/library/server/libfcgi/fcgi.ecf +++ /dev/null @@ -1,52 +0,0 @@ - - - - - - /\.svn$ - /\.git$ - /EIFGENs$ - - - - - - - - - - - - - - - - - - - - - - - - - - - - /linux$ - /fake$ - - - - - - /windows$ - /fake$ - - - - - - - From 78b161df16e1cbb4bf25407eef06fb3144d63b96 Mon Sep 17 00:00:00 2001 From: Jocelyn Fiat Date: Wed, 5 Dec 2012 22:19:59 +0100 Subject: [PATCH 13/27] Prepare upcoming support for unicode environment variables --- .../ewsgi/connectors/nino/src/wgi_nino_handler.e | 14 +++++++++++--- .../src/implementation/wgi_request_from_table.e | 6 +++--- 2 files changed, 14 insertions(+), 6 deletions(-) diff --git a/library/server/ewsgi/connectors/nino/src/wgi_nino_handler.e b/library/server/ewsgi/connectors/nino/src/wgi_nino_handler.e index 07b683b2..7d03a525 100644 --- a/library/server/ewsgi/connectors/nino/src/wgi_nino_handler.e +++ b/library/server/ewsgi/connectors/nino/src/wgi_nino_handler.e @@ -61,7 +61,7 @@ feature -- Request processing process_request (a_handler: HTTP_CONNECTION_HANDLER; a_socket: TCP_STREAM_SOCKET) -- Process request ... local - env, vars: HASH_TABLE [STRING, STRING] + env: HASH_TABLE [STRING, STRING] p: INTEGER l_request_uri, l_script_name, l_query_string, l_path_info: STRING l_server_name, l_server_port: detachable STRING @@ -73,8 +73,16 @@ feature -- Request processing l_request_uri := a_handler.uri a_headers_map := a_handler.request_header_map create e - vars := e.starting_environment_variables - env := vars.twin + if attached e.starting_environment as vars then + create env.make (vars.count) + across + vars as c + loop + env.force (c.item.to_string_8, c.key.to_string_8) + end + else + create env.make (0) + end --| for Any Abc-Def-Ghi add (or replace) the HTTP_ABC_DEF_GHI variable to `env' from diff --git a/library/server/ewsgi/src/implementation/wgi_request_from_table.e b/library/server/ewsgi/src/implementation/wgi_request_from_table.e index 29dec9d2..1545e2a1 100644 --- a/library/server/ewsgi/src/implementation/wgi_request_from_table.e +++ b/library/server/ewsgi/src/implementation/wgi_request_from_table.e @@ -19,7 +19,7 @@ create feature {NONE} -- Initialization - make (a_vars: HASH_TABLE [READABLE_STRING_8, READABLE_STRING_8]; a_input: like input; a_wgi_connector: like wgi_connector) + make (a_vars: HASH_TABLE [READABLE_STRING_GENERAL, READABLE_STRING_GENERAL]; a_input: like input; a_wgi_connector: like wgi_connector) require vars_attached: a_vars /= Void do @@ -244,7 +244,7 @@ feature -- Access: Extension to CGI meta parameters - 1.1 feature {NONE} -- Element change: CGI meta parameter related to PATH_INFO - set_meta_variables (a_vars: HASH_TABLE [READABLE_STRING_8, READABLE_STRING_8]) + set_meta_variables (a_vars: HASH_TABLE [READABLE_STRING_GENERAL, READABLE_STRING_GENERAL]) -- Fill with variable from `a_vars' local s: like meta_string_variable @@ -264,7 +264,7 @@ feature {NONE} -- Element change: CGI meta parameter related to PATH_INFO until a_vars.after loop - table.force (a_vars.item_for_iteration, a_vars.key_for_iteration) + table.force (a_vars.item_for_iteration.to_string_8, a_vars.key_for_iteration.to_string_8) a_vars.forth end From 43df8f573b09a2ae67c7acb86dae2a1aa2b34b14 Mon Sep 17 00:00:00 2001 From: Jocelyn Fiat Date: Wed, 5 Dec 2012 22:20:56 +0100 Subject: [PATCH 14/27] Provide a way to log into a file, rather than just console output Minor optimization for WSF_LOGGING_FILTER --- .../wsf/router/filter/wsf_logging_filter.e | 78 +++++++++++++++---- 1 file changed, 62 insertions(+), 16 deletions(-) diff --git a/library/server/wsf/router/filter/wsf_logging_filter.e b/library/server/wsf/router/filter/wsf_logging_filter.e index 66bdf8d7..23b5db9a 100644 --- a/library/server/wsf/router/filter/wsf_logging_filter.e +++ b/library/server/wsf/router/filter/wsf_logging_filter.e @@ -9,31 +9,77 @@ class inherit WSF_FILTER + redefine + default_create + end + +create + default_create, + make_with_output + +feature {NONE} -- Initialization + + default_create + do + Precursor + output := io.output + end + + make_with_output (a_output: like output) + -- Create Current with `a_output' as `output' + require + a_output_opened: a_output.is_open_read + do + default_create + output := a_output + end + + output: FILE + -- Output file + --| Could be stdout, or a file... feature -- Basic operations execute (req: WSF_REQUEST; res: WSF_RESPONSE) -- Execute the filter local - l_user_agent, l_referer: STRING l_date: DATE_TIME + s: STRING do - if attached req.http_user_agent as ua then - l_user_agent := "%"" + ua.as_string_8 + "%"" - else - l_user_agent := "-" - end - if attached req.http_referer as r then - l_referer := "%"" + r + "%" " - else - l_referer := "" - end + create s.make (64) + s.append (req.remote_addr) + s.append (" - - [") create l_date.make_now_utc - io.put_string (req.remote_addr + " - - [" + l_date.formatted_out (Date_time_format) + " GMT] %"" - + req.request_method + " " + req.request_uri - + " " + {HTTP_CONSTANTS}.http_version_1_1 + "%" " + res.status_code.out + " " - + res.transfered_content_length.out + " " + l_referer + l_user_agent) - io.put_new_line + s.append (l_date.formatted_out (Date_time_format)) + s.append (" GMT] %"") + s.append (req.request_method) + s.append_character (' ') + s.append (req.request_uri) + s.append_character (' ') + s.append ({HTTP_CONSTANTS}.http_version_1_1) + s.append_character ('%"') + s.append_character (' ') + s.append_integer (res.status_code) + s.append_character (' ') + s.append_natural_64 (res.transfered_content_length) + s.append_character (' ') + if attached req.http_referer as r then + s.append_character ('%"') + s.append_character ('%"') + s.append (r) + s.append_character (' ') + end + + if attached req.http_user_agent as ua then + s.append_character ('%"') + s.append (ua) + s.append_character ('%"') + else + s.append_character ('-') + end + + output.put_string (s) + output.put_new_line execute_next (req, res) end From e1dffa542e045f86905ed2ec507a0aa83be3854e Mon Sep 17 00:00:00 2001 From: Jocelyn Fiat Date: Wed, 5 Dec 2012 22:21:36 +0100 Subject: [PATCH 15/27] use libfcgi(-safe).ecf rather than fcgi(-safe).ecf --- library/server/libfcgi/tests/eiffelweb-safe.ecf | 2 +- library/server/libfcgi/tests/eiffelweb.ecf | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/library/server/libfcgi/tests/eiffelweb-safe.ecf b/library/server/libfcgi/tests/eiffelweb-safe.ecf index 31acd804..781bae86 100644 --- a/library/server/libfcgi/tests/eiffelweb-safe.ecf +++ b/library/server/libfcgi/tests/eiffelweb-safe.ecf @@ -10,7 +10,7 @@ - + diff --git a/library/server/libfcgi/tests/eiffelweb.ecf b/library/server/libfcgi/tests/eiffelweb.ecf index 35a36f2f..2167feb5 100644 --- a/library/server/libfcgi/tests/eiffelweb.ecf +++ b/library/server/libfcgi/tests/eiffelweb.ecf @@ -10,7 +10,7 @@ - + From 2ed861e3d958cb8ff570585941ae1a53ccc439b6 Mon Sep 17 00:00:00 2001 From: Jocelyn Fiat Date: Wed, 5 Dec 2012 22:26:58 +0100 Subject: [PATCH 16/27] added tests\all-safe.ecf to compile most of EWF's lib, to quickly check the compilation state --- library/server/request/router/OBSOLETE.txt | 1 - library/server/request/router/license.lic | 10 ------- library/server/request/router/router-safe.ecf | 16 ----------- library/server/request/router/router.ecf | 16 ----------- tests/all-safe.ecf | 28 +++++++++++++++++++ 5 files changed, 28 insertions(+), 43 deletions(-) delete mode 100644 library/server/request/router/OBSOLETE.txt delete mode 100644 library/server/request/router/license.lic delete mode 100644 library/server/request/router/router-safe.ecf delete mode 100644 library/server/request/router/router.ecf create mode 100644 tests/all-safe.ecf diff --git a/library/server/request/router/OBSOLETE.txt b/library/server/request/router/OBSOLETE.txt deleted file mode 100644 index aecee2d5..00000000 --- a/library/server/request/router/OBSOLETE.txt +++ /dev/null @@ -1 +0,0 @@ -Now the router library is part of ../../wsf library \ No newline at end of file diff --git a/library/server/request/router/license.lic b/library/server/request/router/license.lic deleted file mode 100644 index d4d72876..00000000 --- a/library/server/request/router/license.lic +++ /dev/null @@ -1,10 +0,0 @@ -${NOTE_KEYWORD} - copyright: "2011-${YEAR}, Jocelyn Fiat, Javier Velilla, Eiffel Software and others" - license: "Eiffel Forum License v2 (see http://www.eiffel.com/licensing/forum.txt)" - source: "[ - Eiffel Software - 5949 Hollister Ave., Goleta, CA 93117 USA - Telephone 805-685-1006, Fax 805-685-6869 - Website http://www.eiffel.com - Customer support http://support.eiffel.com - ]" diff --git a/library/server/request/router/router-safe.ecf b/library/server/request/router/router-safe.ecf deleted file mode 100644 index 3af161c9..00000000 --- a/library/server/request/router/router-safe.ecf +++ /dev/null @@ -1,16 +0,0 @@ - - - - - - /.git$ - /EIFGENs$ - /.svn$ - - - - - - diff --git a/library/server/request/router/router.ecf b/library/server/request/router/router.ecf deleted file mode 100644 index 3ffd7d4c..00000000 --- a/library/server/request/router/router.ecf +++ /dev/null @@ -1,16 +0,0 @@ - - - - - - /.git$ - /EIFGENs$ - /.svn$ - - - - - - diff --git a/tests/all-safe.ecf b/tests/all-safe.ecf new file mode 100644 index 00000000..46d43a72 --- /dev/null +++ b/tests/all-safe.ecf @@ -0,0 +1,28 @@ + + + compile many lib from EWF + + + + /.git$ + /EIFGENs$ + /.svn$ + + + + + + + + + + + + + + + + + + From 075ac1d6281ab4784bc2620a9b19c3fdabd44484 Mon Sep 17 00:00:00 2001 From: Olivier Ligot Date: Mon, 3 Dec 2012 16:29:12 +0100 Subject: [PATCH 17/27] Logging filter The logging filter is now part of EWF core (before it was only available in the filter example) and can therefore be reused by others needing it. Note that this is a first implementation. It can certainly be improved in the future to support more fine grained logging. --- examples/filter/src/filter_server.e | 2 +- .../wsf/router/filter/wsf_logging_filter.e | 21 ++++++++++++------- 2 files changed, 15 insertions(+), 8 deletions(-) rename examples/filter/src/filter/logging_filter.e => library/server/wsf/router/filter/wsf_logging_filter.e (55%) diff --git a/examples/filter/src/filter_server.e b/examples/filter/src/filter_server.e index fff542ac..25d16fef 100644 --- a/examples/filter/src/filter_server.e +++ b/examples/filter/src/filter_server.e @@ -53,7 +53,7 @@ feature {NONE} -- Initialization setup_filter -- Setup `filter' local - l_logging_filter: LOGGING_FILTER + l_logging_filter: WSF_LOGGING_FILTER do create l_logging_filter filter.set_next (l_logging_filter) diff --git a/examples/filter/src/filter/logging_filter.e b/library/server/wsf/router/filter/wsf_logging_filter.e similarity index 55% rename from examples/filter/src/filter/logging_filter.e rename to library/server/wsf/router/filter/wsf_logging_filter.e index e6a8b89b..66bdf8d7 100644 --- a/examples/filter/src/filter/logging_filter.e +++ b/library/server/wsf/router/filter/wsf_logging_filter.e @@ -5,7 +5,7 @@ note revision: "$Revision$" class - LOGGING_FILTER + WSF_LOGGING_FILTER inherit WSF_FILTER @@ -15,24 +15,31 @@ feature -- Basic operations execute (req: WSF_REQUEST; res: WSF_RESPONSE) -- Execute the filter local - l_user_agent: STRING + l_user_agent, l_referer: STRING l_date: DATE_TIME do if attached req.http_user_agent as ua then - l_user_agent := ua.as_string_8 + l_user_agent := "%"" + ua.as_string_8 + "%"" else l_user_agent := "-" end - create l_date.make_now - io.put_string ("[" + l_date.formatted_out (Date_time_format) + "] %"" + req.request_method + " " + req.request_uri - + " " + {HTTP_CONSTANTS}.http_version_1_1 + "%" " + res.status_code.out + " " + l_user_agent) + if attached req.http_referer as r then + l_referer := "%"" + r + "%" " + else + l_referer := "" + end + create l_date.make_now_utc + io.put_string (req.remote_addr + " - - [" + l_date.formatted_out (Date_time_format) + " GMT] %"" + + req.request_method + " " + req.request_uri + + " " + {HTTP_CONSTANTS}.http_version_1_1 + "%" " + res.status_code.out + " " + + res.transfered_content_length.out + " " + l_referer + l_user_agent) io.put_new_line execute_next (req, res) end feature -- Constants - Date_time_format: STRING = "yyyy/[0]mm/[0]dd [0]hh:[0]mi:[0]ss.ff3" + Date_time_format: STRING = "[0]dd/[0]mm/yyyy [0]hh:[0]mi:[0]ss" note copyright: "2011-2012, Olivier Ligot, Jocelyn Fiat and others" From a6ca54f958acc8b9820381c6434d46ea503e737c Mon Sep 17 00:00:00 2001 From: Olivier Ligot Date: Mon, 3 Dec 2012 17:37:26 +0100 Subject: [PATCH 18/27] Fix ise_wizard * ewf.ini was used instead of template.ecf as configuration file * remove initialize_router otherwise the compilation failed * remove unused variables --- tools/ise_wizard/resources/ewf_application.e | 5 ----- tools/ise_wizard/src/ewf_wizard.e | 5 ++--- 2 files changed, 2 insertions(+), 8 deletions(-) diff --git a/tools/ise_wizard/resources/ewf_application.e b/tools/ise_wizard/resources/ewf_application.e index af64909d..929cd433 100644 --- a/tools/ise_wizard/resources/ewf_application.e +++ b/tools/ise_wizard/resources/ewf_application.e @@ -26,8 +26,6 @@ feature -- Execution -- Default request handler if no other are relevant local mesg: WSF_HTML_PAGE_RESPONSE - s: STRING_8 - l_user_name: READABLE_STRING_32 do create mesg.make mesg.set_title ("Hello World!") @@ -44,9 +42,6 @@ feature {NONE} -- Initialization --| If you don't need any custom options, you are not obliged to redefine `initialize' Precursor - - --| Initialize router - initialize_router end end diff --git a/tools/ise_wizard/src/ewf_wizard.e b/tools/ise_wizard/src/ewf_wizard.e index 9d6f08a6..09bcdd21 100644 --- a/tools/ise_wizard/src/ewf_wizard.e +++ b/tools/ise_wizard/src/ewf_wizard.e @@ -119,15 +119,14 @@ feature -- Form tfn.add_extension ("ecf") copy_resource_template ("template.ecf", tfn.string) + create res.make (tfn.string, d.name) + create tfn.make_from_string (dn.string) tfn.set_file_name ("ewf") tfn.add_extension ("ini") copy_resource_template ("ewf.ini", tfn.string) - - create res.make (tfn.string, d.name) - create dn.make_from_string (pdn) dn.extend (pn) dn.extend ("src") From 4ed8365afe520baf9cca573a268b2b1309d7d7ac Mon Sep 17 00:00:00 2001 From: Olivier Ligot Date: Tue, 4 Dec 2012 14:42:09 +0100 Subject: [PATCH 19/27] ise_wizard Unix shell scripts --- tools/ise_wizard/install_ise_wizard.sh | 15 +++++++++++++++ tools/ise_wizard/install_ise_wizard_custom.sh | 16 ++++++++++++++++ 2 files changed, 31 insertions(+) create mode 100755 tools/ise_wizard/install_ise_wizard.sh create mode 100755 tools/ise_wizard/install_ise_wizard_custom.sh diff --git a/tools/ise_wizard/install_ise_wizard.sh b/tools/ise_wizard/install_ise_wizard.sh new file mode 100755 index 00000000..9b5496ea --- /dev/null +++ b/tools/ise_wizard/install_ise_wizard.sh @@ -0,0 +1,15 @@ +#!/bin/sh + +mkdir tmp +ecb -config ewf_ise_wizard-safe.ecf -target wizard -finalize -c_compile -project_path tmp +mkdir -p spec/$ISE_PLATFORM +mv tmp/EIFGENs/wizard/F_code/wizard spec/$ISE_PLATFORM/wizard +rm -rf tmp + +WIZ_TARGET=$ISE_EIFFEL/studio/wizards/new_projects/ewf +rm -rf $WIZ_TARGET +mkdir $WIZ_TARGET +cp -r resources $WIZ_TARGET/resources +cp -r spec $WIZ_TARGET/spec +cp ewf.dsc $WIZ_TARGET/../ewf.dsc +rm -rf spec diff --git a/tools/ise_wizard/install_ise_wizard_custom.sh b/tools/ise_wizard/install_ise_wizard_custom.sh new file mode 100755 index 00000000..308e7d84 --- /dev/null +++ b/tools/ise_wizard/install_ise_wizard_custom.sh @@ -0,0 +1,16 @@ +#!/bin/sh + +mkdir tmp +ecb -config ewf_ise_wizard-safe.ecf -target custom_wizard -finalize -c_compile -project_path tmp +mkdir -p custom/spec/$ISE_PLATFORM +mv tmp/EIFGENs/custom_wizard/F_code/wizard custom/spec/$ISE_PLATFORM/wizard +rm -rf tmp + +WIZ_TARGET=$ISE_EIFFEL/studio/wizards/new_projects/ewf_custom +rm -rf $WIZ_TARGET +mkdir $WIZ_TARGET +cp -r resources $WIZ_TARGET/resources +cp -f custom/resources/* $WIZ_TARGET/resources +cp -r custom/spec $WIZ_TARGET/spec +cp custom/ewf.dsc $WIZ_TARGET/../ewf_custom.dsc +rm -rf custom/spec From d445559890656aa039b49d0f727d62424df2cff4 Mon Sep 17 00:00:00 2001 From: Jocelyn Fiat Date: Wed, 5 Dec 2012 17:01:45 +0100 Subject: [PATCH 20/27] removed fcgi(-safe).ecf files ... since there renamed libfcgi(-safe).ecf --- library/server/libfcgi/fcgi-safe.ecf | 52 ---------------------------- library/server/libfcgi/fcgi.ecf | 52 ---------------------------- 2 files changed, 104 deletions(-) delete mode 100644 library/server/libfcgi/fcgi-safe.ecf delete mode 100644 library/server/libfcgi/fcgi.ecf diff --git a/library/server/libfcgi/fcgi-safe.ecf b/library/server/libfcgi/fcgi-safe.ecf deleted file mode 100644 index 18fd9512..00000000 --- a/library/server/libfcgi/fcgi-safe.ecf +++ /dev/null @@ -1,52 +0,0 @@ - - - - - - /\.svn$ - /\.git$ - /EIFGENs$ - - - - - - - - - - - - - - - - - - - - - - - - - - - - /linux$ - /fake$ - - - - - - /windows$ - /fake$ - - - - - - - diff --git a/library/server/libfcgi/fcgi.ecf b/library/server/libfcgi/fcgi.ecf deleted file mode 100644 index 05d15197..00000000 --- a/library/server/libfcgi/fcgi.ecf +++ /dev/null @@ -1,52 +0,0 @@ - - - - - - /\.svn$ - /\.git$ - /EIFGENs$ - - - - - - - - - - - - - - - - - - - - - - - - - - - - /linux$ - /fake$ - - - - - - /windows$ - /fake$ - - - - - - - From a9f3ea7886d9ddb2f822bdd4332c4041a6e74286 Mon Sep 17 00:00:00 2001 From: Jocelyn Fiat Date: Wed, 5 Dec 2012 22:19:59 +0100 Subject: [PATCH 21/27] Prepare upcoming support for unicode environment variables --- .../ewsgi/connectors/nino/src/wgi_nino_handler.e | 14 +++++++++++--- .../src/implementation/wgi_request_from_table.e | 6 +++--- 2 files changed, 14 insertions(+), 6 deletions(-) diff --git a/library/server/ewsgi/connectors/nino/src/wgi_nino_handler.e b/library/server/ewsgi/connectors/nino/src/wgi_nino_handler.e index 07b683b2..7d03a525 100644 --- a/library/server/ewsgi/connectors/nino/src/wgi_nino_handler.e +++ b/library/server/ewsgi/connectors/nino/src/wgi_nino_handler.e @@ -61,7 +61,7 @@ feature -- Request processing process_request (a_handler: HTTP_CONNECTION_HANDLER; a_socket: TCP_STREAM_SOCKET) -- Process request ... local - env, vars: HASH_TABLE [STRING, STRING] + env: HASH_TABLE [STRING, STRING] p: INTEGER l_request_uri, l_script_name, l_query_string, l_path_info: STRING l_server_name, l_server_port: detachable STRING @@ -73,8 +73,16 @@ feature -- Request processing l_request_uri := a_handler.uri a_headers_map := a_handler.request_header_map create e - vars := e.starting_environment_variables - env := vars.twin + if attached e.starting_environment as vars then + create env.make (vars.count) + across + vars as c + loop + env.force (c.item.to_string_8, c.key.to_string_8) + end + else + create env.make (0) + end --| for Any Abc-Def-Ghi add (or replace) the HTTP_ABC_DEF_GHI variable to `env' from diff --git a/library/server/ewsgi/src/implementation/wgi_request_from_table.e b/library/server/ewsgi/src/implementation/wgi_request_from_table.e index 29dec9d2..1545e2a1 100644 --- a/library/server/ewsgi/src/implementation/wgi_request_from_table.e +++ b/library/server/ewsgi/src/implementation/wgi_request_from_table.e @@ -19,7 +19,7 @@ create feature {NONE} -- Initialization - make (a_vars: HASH_TABLE [READABLE_STRING_8, READABLE_STRING_8]; a_input: like input; a_wgi_connector: like wgi_connector) + make (a_vars: HASH_TABLE [READABLE_STRING_GENERAL, READABLE_STRING_GENERAL]; a_input: like input; a_wgi_connector: like wgi_connector) require vars_attached: a_vars /= Void do @@ -244,7 +244,7 @@ feature -- Access: Extension to CGI meta parameters - 1.1 feature {NONE} -- Element change: CGI meta parameter related to PATH_INFO - set_meta_variables (a_vars: HASH_TABLE [READABLE_STRING_8, READABLE_STRING_8]) + set_meta_variables (a_vars: HASH_TABLE [READABLE_STRING_GENERAL, READABLE_STRING_GENERAL]) -- Fill with variable from `a_vars' local s: like meta_string_variable @@ -264,7 +264,7 @@ feature {NONE} -- Element change: CGI meta parameter related to PATH_INFO until a_vars.after loop - table.force (a_vars.item_for_iteration, a_vars.key_for_iteration) + table.force (a_vars.item_for_iteration.to_string_8, a_vars.key_for_iteration.to_string_8) a_vars.forth end From 5de14b114e5295f0bd80cf4b8d62c1be62d308aa Mon Sep 17 00:00:00 2001 From: Jocelyn Fiat Date: Wed, 5 Dec 2012 22:20:56 +0100 Subject: [PATCH 22/27] Provide a way to log into a file, rather than just console output Minor optimization for WSF_LOGGING_FILTER --- .../wsf/router/filter/wsf_logging_filter.e | 78 +++++++++++++++---- 1 file changed, 62 insertions(+), 16 deletions(-) diff --git a/library/server/wsf/router/filter/wsf_logging_filter.e b/library/server/wsf/router/filter/wsf_logging_filter.e index 66bdf8d7..23b5db9a 100644 --- a/library/server/wsf/router/filter/wsf_logging_filter.e +++ b/library/server/wsf/router/filter/wsf_logging_filter.e @@ -9,31 +9,77 @@ class inherit WSF_FILTER + redefine + default_create + end + +create + default_create, + make_with_output + +feature {NONE} -- Initialization + + default_create + do + Precursor + output := io.output + end + + make_with_output (a_output: like output) + -- Create Current with `a_output' as `output' + require + a_output_opened: a_output.is_open_read + do + default_create + output := a_output + end + + output: FILE + -- Output file + --| Could be stdout, or a file... feature -- Basic operations execute (req: WSF_REQUEST; res: WSF_RESPONSE) -- Execute the filter local - l_user_agent, l_referer: STRING l_date: DATE_TIME + s: STRING do - if attached req.http_user_agent as ua then - l_user_agent := "%"" + ua.as_string_8 + "%"" - else - l_user_agent := "-" - end - if attached req.http_referer as r then - l_referer := "%"" + r + "%" " - else - l_referer := "" - end + create s.make (64) + s.append (req.remote_addr) + s.append (" - - [") create l_date.make_now_utc - io.put_string (req.remote_addr + " - - [" + l_date.formatted_out (Date_time_format) + " GMT] %"" - + req.request_method + " " + req.request_uri - + " " + {HTTP_CONSTANTS}.http_version_1_1 + "%" " + res.status_code.out + " " - + res.transfered_content_length.out + " " + l_referer + l_user_agent) - io.put_new_line + s.append (l_date.formatted_out (Date_time_format)) + s.append (" GMT] %"") + s.append (req.request_method) + s.append_character (' ') + s.append (req.request_uri) + s.append_character (' ') + s.append ({HTTP_CONSTANTS}.http_version_1_1) + s.append_character ('%"') + s.append_character (' ') + s.append_integer (res.status_code) + s.append_character (' ') + s.append_natural_64 (res.transfered_content_length) + s.append_character (' ') + if attached req.http_referer as r then + s.append_character ('%"') + s.append_character ('%"') + s.append (r) + s.append_character (' ') + end + + if attached req.http_user_agent as ua then + s.append_character ('%"') + s.append (ua) + s.append_character ('%"') + else + s.append_character ('-') + end + + output.put_string (s) + output.put_new_line execute_next (req, res) end From 20c94e927d725d7042f2612eccc4753c4f3657ed Mon Sep 17 00:00:00 2001 From: Jocelyn Fiat Date: Wed, 5 Dec 2012 22:21:36 +0100 Subject: [PATCH 23/27] use libfcgi(-safe).ecf rather than fcgi(-safe).ecf --- library/server/libfcgi/tests/eiffelweb-safe.ecf | 2 +- library/server/libfcgi/tests/eiffelweb.ecf | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/library/server/libfcgi/tests/eiffelweb-safe.ecf b/library/server/libfcgi/tests/eiffelweb-safe.ecf index 31acd804..781bae86 100644 --- a/library/server/libfcgi/tests/eiffelweb-safe.ecf +++ b/library/server/libfcgi/tests/eiffelweb-safe.ecf @@ -10,7 +10,7 @@ - + diff --git a/library/server/libfcgi/tests/eiffelweb.ecf b/library/server/libfcgi/tests/eiffelweb.ecf index 35a36f2f..2167feb5 100644 --- a/library/server/libfcgi/tests/eiffelweb.ecf +++ b/library/server/libfcgi/tests/eiffelweb.ecf @@ -10,7 +10,7 @@ - + From 9499d4aa596c9d8d36a309ab723e931c682cc9b3 Mon Sep 17 00:00:00 2001 From: Jocelyn Fiat Date: Wed, 5 Dec 2012 22:26:58 +0100 Subject: [PATCH 24/27] added tests\all-safe.ecf to compile most of EWF's lib, to quickly check the compilation state --- library/server/request/router/OBSOLETE.txt | 1 - library/server/request/router/license.lic | 10 ------- library/server/request/router/router-safe.ecf | 16 ----------- library/server/request/router/router.ecf | 16 ----------- tests/all-safe.ecf | 28 +++++++++++++++++++ 5 files changed, 28 insertions(+), 43 deletions(-) delete mode 100644 library/server/request/router/OBSOLETE.txt delete mode 100644 library/server/request/router/license.lic delete mode 100644 library/server/request/router/router-safe.ecf delete mode 100644 library/server/request/router/router.ecf create mode 100644 tests/all-safe.ecf diff --git a/library/server/request/router/OBSOLETE.txt b/library/server/request/router/OBSOLETE.txt deleted file mode 100644 index aecee2d5..00000000 --- a/library/server/request/router/OBSOLETE.txt +++ /dev/null @@ -1 +0,0 @@ -Now the router library is part of ../../wsf library \ No newline at end of file diff --git a/library/server/request/router/license.lic b/library/server/request/router/license.lic deleted file mode 100644 index d4d72876..00000000 --- a/library/server/request/router/license.lic +++ /dev/null @@ -1,10 +0,0 @@ -${NOTE_KEYWORD} - copyright: "2011-${YEAR}, Jocelyn Fiat, Javier Velilla, Eiffel Software and others" - license: "Eiffel Forum License v2 (see http://www.eiffel.com/licensing/forum.txt)" - source: "[ - Eiffel Software - 5949 Hollister Ave., Goleta, CA 93117 USA - Telephone 805-685-1006, Fax 805-685-6869 - Website http://www.eiffel.com - Customer support http://support.eiffel.com - ]" diff --git a/library/server/request/router/router-safe.ecf b/library/server/request/router/router-safe.ecf deleted file mode 100644 index 3af161c9..00000000 --- a/library/server/request/router/router-safe.ecf +++ /dev/null @@ -1,16 +0,0 @@ - - - - - - /.git$ - /EIFGENs$ - /.svn$ - - - - - - diff --git a/library/server/request/router/router.ecf b/library/server/request/router/router.ecf deleted file mode 100644 index 3ffd7d4c..00000000 --- a/library/server/request/router/router.ecf +++ /dev/null @@ -1,16 +0,0 @@ - - - - - - /.git$ - /EIFGENs$ - /.svn$ - - - - - - diff --git a/tests/all-safe.ecf b/tests/all-safe.ecf new file mode 100644 index 00000000..46d43a72 --- /dev/null +++ b/tests/all-safe.ecf @@ -0,0 +1,28 @@ + + + compile many lib from EWF + + + + /.git$ + /EIFGENs$ + /.svn$ + + + + + + + + + + + + + + + + + + From 39c3e8c5cf5a8e4cbb5700748f04044d4b17cab2 Mon Sep 17 00:00:00 2001 From: Jocelyn Fiat Date: Wed, 5 Dec 2012 22:39:05 +0100 Subject: [PATCH 25/27] corrected null connector ecf files --- library/server/ewsgi/connectors/null/null-safe.ecf | 4 ++-- library/server/ewsgi/connectors/null/null.ecf | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/library/server/ewsgi/connectors/null/null-safe.ecf b/library/server/ewsgi/connectors/null/null-safe.ecf index 9ad9cd54..6d82d779 100644 --- a/library/server/ewsgi/connectors/null/null-safe.ecf +++ b/library/server/ewsgi/connectors/null/null-safe.ecf @@ -1,6 +1,6 @@ - - + + /EIFGENs$ diff --git a/library/server/ewsgi/connectors/null/null.ecf b/library/server/ewsgi/connectors/null/null.ecf index c8df2ee7..5255edb0 100644 --- a/library/server/ewsgi/connectors/null/null.ecf +++ b/library/server/ewsgi/connectors/null/null.ecf @@ -1,6 +1,6 @@ - - + + /EIFGENs$ From 926ae823ac605da1935724fc5a11a69448bd0e2c Mon Sep 17 00:00:00 2001 From: Jocelyn Fiat Date: Wed, 5 Dec 2012 22:39:43 +0100 Subject: [PATCH 26/27] compile all-safe.ecf as windows or unix, even if not on Windows or unix --- tests/all-safe.ecf | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/tests/all-safe.ecf b/tests/all-safe.ecf index 46d43a72..98fb312d 100644 --- a/tests/all-safe.ecf +++ b/tests/all-safe.ecf @@ -25,4 +25,15 @@ + + Compiling as Windows , on other platforms than Windows + + + + + Compiling as UNIX , on other platforms than Unix + + + + From e20cb6b6edae2784da1698c0b98fa31ce6a7c246 Mon Sep 17 00:00:00 2001 From: Jocelyn Fiat Date: Fri, 7 Dec 2012 14:55:38 +0100 Subject: [PATCH 27/27] make it compiles with EiffelStudio 7.1 and 7.2 --- library/server/ewsgi/connectors/cgi/src/wgi_cgi_connector.e | 2 +- library/server/ewsgi/connectors/nino/src/wgi_nino_handler.e | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/library/server/ewsgi/connectors/cgi/src/wgi_cgi_connector.e b/library/server/ewsgi/connectors/cgi/src/wgi_cgi_connector.e index b237ef81..dc98f64f 100644 --- a/library/server/ewsgi/connectors/cgi/src/wgi_cgi_connector.e +++ b/library/server/ewsgi/connectors/cgi/src/wgi_cgi_connector.e @@ -62,7 +62,7 @@ feature -- Execution end note - copyright: "2011-2011, Eiffel Software and others" + copyright: "2011-2012, Eiffel Software and others" license: "Eiffel Forum License v2 (see http://www.eiffel.com/licensing/forum.txt)" source: "[ Eiffel Software diff --git a/library/server/ewsgi/connectors/nino/src/wgi_nino_handler.e b/library/server/ewsgi/connectors/nino/src/wgi_nino_handler.e index 7d03a525..b1602527 100644 --- a/library/server/ewsgi/connectors/nino/src/wgi_nino_handler.e +++ b/library/server/ewsgi/connectors/nino/src/wgi_nino_handler.e @@ -73,7 +73,7 @@ feature -- Request processing l_request_uri := a_handler.uri a_headers_map := a_handler.request_header_map create e - if attached e.starting_environment as vars then + if attached e.starting_environment_variables as vars then create env.make (vars.count) across vars as c @@ -197,7 +197,7 @@ feature -- Request processing end note - copyright: "2011-2011, Eiffel Software and others" + copyright: "2011-2012, Jocelyn Fiat, Javier Velilla, Eiffel Software and others" license: "Eiffel Forum License v2 (see http://www.eiffel.com/licensing/forum.txt)" source: "[ Eiffel Software