Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
| Comment: | lithium-dispatchers: add expiration purge to prevent termination issue |
|---|---|
| Timelines: | family | ancestors | descendants | both | trunk |
| Files: | files | file ages | folders |
| SHA1: |
bb942f62bc5f5088bd33975e04874ddc |
| User & Date: | nat 2017-06-05 20:48:27.878 |
Context
|
2017-06-10
| ||
| 21:24 | lithium-log: add a periodic marker to the log when in debug mode check-in: e0251e7c05 user: nat tags: trunk | |
|
2017-06-05
| ||
| 20:48 | lithium-dispatchers: add expiration purge to prevent termination issue check-in: bb942f62bc user: nat tags: trunk | |
|
2017-05-30
| ||
| 20:50 | lithium-access_log: add a column for the forward protocol check-in: de8fe7bf8c user: nat tags: trunk | |
Changes
Changes to src/lithium-dispatchers.adb.
1 | ------------------------------------------------------------------------------ | | | 1 2 3 4 5 6 7 8 9 | ------------------------------------------------------------------------------ -- Copyright (c) 2015-2017, Natacha Porté -- -- -- -- Permission to use, copy, modify, and distribute this software for any -- -- purpose with or without fee is hereby granted, provided that the above -- -- copyright notice and this permission notice appear in all copies. -- -- -- -- THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES -- -- WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF -- |
| ︙ | ︙ | |||
20 21 22 23 24 25 26 27 28 29 30 31 32 33 | with Natools.Web.Exchanges; with Natools.Web.Filters.Pass_Through; with Natools.Web.Filters.Text_Blocks; with Natools.Web.Filters.Text_Replacement; with Natools.Web.Reload_Pages; with Natools.Web.Simple_Pages.Markdown_Pages; with Natools.Web.Simple_Pages.Markdown_Multipages; with Natools.Web.Tag_Pages; with Lithium.Access_Log; with Lithium.Legacy_Filters; with Lithium.Markdown.Filters; package body Lithium.Dispatchers is | > | 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 | with Natools.Web.Exchanges; with Natools.Web.Filters.Pass_Through; with Natools.Web.Filters.Text_Blocks; with Natools.Web.Filters.Text_Replacement; with Natools.Web.Reload_Pages; with Natools.Web.Simple_Pages.Markdown_Pages; with Natools.Web.Simple_Pages.Markdown_Multipages; with Natools.Web.Sites.Updates; with Natools.Web.Tag_Pages; with Lithium.Access_Log; with Lithium.Legacy_Filters; with Lithium.Markdown.Filters; package body Lithium.Dispatchers is |
| ︙ | ︙ | |||
100 101 102 103 104 105 106 107 |
("text-block", Natools.Web.Filters.Text_Blocks.Create'Access);
Holder.Load (File_Name);
return Result;
end Create;
end Lithium.Dispatchers;
| > > > > > > > | 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 |
("text-block", Natools.Web.Filters.Text_Blocks.Create'Access);
Holder.Load (File_Name);
return Result;
end Create;
not overriding procedure Purge (Object : in Handler) is
Update : Natools.Web.Sites.Updates.Expiration_Purger;
begin
Object.Ref.Update.Queue (Update);
end Purge;
end Lithium.Dispatchers;
|
Changes to src/lithium-dispatchers.ads.
1 | ------------------------------------------------------------------------------ | | | 1 2 3 4 5 6 7 8 9 | ------------------------------------------------------------------------------ -- Copyright (c) 2015-2017, Natacha Porté -- -- -- -- Permission to use, copy, modify, and distribute this software for any -- -- purpose with or without fee is hereby granted, provided that the above -- -- copyright notice and this permission notice appear in all copies. -- -- -- -- THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES -- -- WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF -- |
| ︙ | ︙ | |||
38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 |
overriding function Dispatch
(Dispatcher : Handler;
Request : AWS.Status.Data)
return AWS.Response.Data;
not overriding function Create (File_Name : String) return Handler;
private
type Handler is new AWS.Dispatchers.Handler with record
Ref : Holder_Refs.Reference;
end record;
end Lithium.Dispatchers;
| > > | 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 |
overriding function Dispatch
(Dispatcher : Handler;
Request : AWS.Status.Data)
return AWS.Response.Data;
not overriding function Create (File_Name : String) return Handler;
not overriding procedure Purge (Object : in Handler);
private
type Handler is new AWS.Dispatchers.Handler with record
Ref : Holder_Refs.Reference;
end record;
end Lithium.Dispatchers;
|
Changes to src/lithium-main.adb.
1 | ------------------------------------------------------------------------------ | | | 1 2 3 4 5 6 7 8 9 | ------------------------------------------------------------------------------ -- Copyright (c) 2015-2017, Natacha Porté -- -- -- -- Permission to use, copy, modify, and distribute this software for any -- -- purpose with or without fee is hereby granted, provided that the above -- -- copyright notice and this permission notice appear in all copies. -- -- -- -- THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES -- -- WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF -- |
| ︙ | ︙ | |||
48 49 50 51 52 53 54 55 |
end loop;
else
Ada.Text_IO.Put_Line ("Websever started, waiting for Q press");
AWS.Server.Wait (AWS.Server.Q_Key_Pressed);
end if;
AWS.Server.Shutdown (WS);
end Lithium.Main;
| > | 48 49 50 51 52 53 54 55 56 |
end loop;
else
Ada.Text_IO.Put_Line ("Websever started, waiting for Q press");
AWS.Server.Wait (AWS.Server.Q_Key_Pressed);
end if;
AWS.Server.Shutdown (WS);
Handler.Purge;
end Lithium.Main;
|