diff --git a/Quartzmin.sln b/Quartzmin.sln index 8e421a0..f622db1 100644 --- a/Quartzmin.sln +++ b/Quartzmin.sln @@ -19,7 +19,9 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NetCoreSelfHost", "Source\E EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WinFormSelfHost", "Source\Examples\WinFormSelfHost\WinFormSelfHost.csproj", "{C54F4403-F40A-497C-B3A7-D1F1E1830D52}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "AspNetCoreDocker", "Source\Examples\AspNetCoreDocker\AspNetCoreDocker.csproj", "{68D816F2-21BF-4376-ABF4-70390E4783C5}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "AspNetCoreDocker", "Source\Examples\AspNetCoreDocker\AspNetCoreDocker.csproj", "{68D816F2-21BF-4376-ABF4-70390E4783C5}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NetSelfHost", "Source\Examples\NetSelfHost\NetSelfHost.csproj", "{55BCC363-DA5E-478B-9141-E570C63FBC2D}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution @@ -59,6 +61,10 @@ Global {68D816F2-21BF-4376-ABF4-70390E4783C5}.Debug|Any CPU.Build.0 = Debug|Any CPU {68D816F2-21BF-4376-ABF4-70390E4783C5}.Release|Any CPU.ActiveCfg = Release|Any CPU {68D816F2-21BF-4376-ABF4-70390E4783C5}.Release|Any CPU.Build.0 = Release|Any CPU + {55BCC363-DA5E-478B-9141-E570C63FBC2D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {55BCC363-DA5E-478B-9141-E570C63FBC2D}.Debug|Any CPU.Build.0 = Debug|Any CPU + {55BCC363-DA5E-478B-9141-E570C63FBC2D}.Release|Any CPU.ActiveCfg = Release|Any CPU + {55BCC363-DA5E-478B-9141-E570C63FBC2D}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE @@ -69,43 +75,9 @@ Global {7CF90DB9-37C4-4704-910E-BF1DB8AB79F1} = {B669A725-70A9-4E80-BAC7-9765A14CAAA4} {C54F4403-F40A-497C-B3A7-D1F1E1830D52} = {B669A725-70A9-4E80-BAC7-9765A14CAAA4} {68D816F2-21BF-4376-ABF4-70390E4783C5} = {B669A725-70A9-4E80-BAC7-9765A14CAAA4} + {55BCC363-DA5E-478B-9141-E570C63FBC2D} = {B669A725-70A9-4E80-BAC7-9765A14CAAA4} EndGlobalSection GlobalSection(ExtensibilityGlobals) = postSolution SolutionGuid = {0357313D-BD09-4C5D-AF0D-439B3BD33B5A} EndGlobalSection - GlobalSection(TeamFoundationVersionControl) = preSolution - SccNumberOfProjects = 9 - SccEnterpriseProvider = {4CA58AB2-18FA-4F8D-95D4-32DDF27D184C} - SccTeamFoundationServer = http://tfs/defaultcollection - SccLocalPath0 = . - SccProjectUniqueName1 = Source\\Quartzmin\\Quartzmin.csproj - SccProjectName1 = Source/Quartzmin - SccLocalPath1 = Source\\Quartzmin - SccProjectUniqueName2 = Source\\Quartz.Plugins.RecentHistory\\Quartz.Plugins.RecentHistory.csproj - SccProjectName2 = Source/Quartz.Plugins.RecentHistory - SccLocalPath2 = Source\\Quartz.Plugins.RecentHistory - SccProjectUniqueName3 = Source\\Quartzmin.SelfHost\\Quartzmin.SelfHost.csproj - SccProjectName3 = Source/Quartzmin.SelfHost - SccLocalPath3 = Source\\Quartzmin.SelfHost - SccProjectUniqueName4 = Source\\Examples\\NetCoreSelfHost\\NetCoreSelfHost.csproj - SccProjectTopLevelParentUniqueName4 = Quartzmin.sln - SccProjectName4 = Source/Examples/NetCoreSelfHost - SccLocalPath4 = Source\\Examples\\NetCoreSelfHost - SccProjectUniqueName5 = Source\\Examples\\AspNetCoreHost\\AspNetCoreHost.csproj - SccProjectTopLevelParentUniqueName5 = Quartzmin.sln - SccProjectName5 = Source/Examples/AspNetCoreHost - SccLocalPath5 = Source\\Examples\\AspNetCoreHost - SccProjectUniqueName6 = Source\\Examples\\AspNetWebHost\\AspNetWebHost.csproj - SccProjectTopLevelParentUniqueName6 = Quartzmin.sln - SccProjectName6 = Source/Examples/AspNetWebHost - SccLocalPath6 = Source\\Examples\\AspNetWebHost - SccProjectUniqueName7 = Source\\Examples\\WinFormSelfHost\\WinFormSelfHost.csproj - SccProjectTopLevelParentUniqueName7 = Quartzmin.sln - SccProjectName7 = Source/Examples/WinFormSelfHost - SccLocalPath7 = Source\\Examples\\WinFormSelfHost - SccProjectUniqueName8 = Source\\Examples\\AspNetCoreDocker\\AspNetCoreDocker.csproj - SccProjectTopLevelParentUniqueName8 = Quartzmin.sln - SccProjectName8 = Source/Examples/AspNetCoreDocker - SccLocalPath8 = Source\\Examples\\AspNetCoreDocker - EndGlobalSection EndGlobal diff --git a/Source/Examples/NetCoreSelfHost/Program.cs b/Source/Examples/NetCoreSelfHost/Program.cs index e704f16..e52ca7c 100644 --- a/Source/Examples/NetCoreSelfHost/Program.cs +++ b/Source/Examples/NetCoreSelfHost/Program.cs @@ -1,4 +1,5 @@ -using Quartzmin; +using System; +using Quartzmin; using System.Threading; namespace NetCoreSelfHost @@ -11,7 +12,10 @@ static void Main(string[] args) scheduler.Start(); while (!scheduler.IsShutdown) + { + Console.WriteLine("Working"); Thread.Sleep(500); + } } } } diff --git a/Source/Examples/NetCoreSelfHost/app.config b/Source/Examples/NetCoreSelfHost/app.config index 1a13585..34c4488 100644 --- a/Source/Examples/NetCoreSelfHost/app.config +++ b/Source/Examples/NetCoreSelfHost/app.config @@ -9,6 +9,6 @@ - + diff --git a/Source/Examples/NetSelfHost/App.config b/Source/Examples/NetSelfHost/App.config new file mode 100644 index 0000000..9645098 --- /dev/null +++ b/Source/Examples/NetSelfHost/App.config @@ -0,0 +1,32 @@ + + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/Source/Examples/NetSelfHost/NetSelfHost.csproj b/Source/Examples/NetSelfHost/NetSelfHost.csproj new file mode 100644 index 0000000..5f4f31f --- /dev/null +++ b/Source/Examples/NetSelfHost/NetSelfHost.csproj @@ -0,0 +1,95 @@ + + + + + Debug + AnyCPU + {55BCC363-DA5E-478B-9141-E570C63FBC2D} + Exe + NetSelfHost + NetSelfHost + v4.6.2 + 512 + true + true + + + AnyCPU + true + full + false + bin\Debug\ + DEBUG;TRACE + prompt + 4 + + + AnyCPU + pdbonly + true + bin\Release\ + TRACE + prompt + 4 + + + + ..\..\..\packages\Microsoft.Owin.2.1.0\lib\net45\Microsoft.Owin.dll + + + ..\..\..\packages\Microsoft.Owin.Host.HttpListener.2.1.0\lib\net45\Microsoft.Owin.Host.HttpListener.dll + + + ..\..\..\packages\Microsoft.Owin.Host.SystemWeb.2.1.0\lib\net45\Microsoft.Owin.Host.SystemWeb.dll + + + ..\..\..\packages\Microsoft.Owin.Hosting.2.1.0\lib\net45\Microsoft.Owin.Hosting.dll + + + ..\..\..\packages\Newtonsoft.Json.11.0.2\lib\net45\Newtonsoft.Json.dll + + + ..\..\..\packages\Owin.1.0\lib\net40\Owin.dll + + + ..\..\..\packages\Quartz.3.0.7\lib\net452\Quartz.dll + + + + + + ..\..\..\packages\Microsoft.AspNet.WebApi.Client.5.2.6\lib\net45\System.Net.Http.Formatting.dll + + + + ..\..\..\packages\Microsoft.AspNet.WebApi.Core.5.2.6\lib\net45\System.Web.Http.dll + + + ..\..\..\packages\Microsoft.AspNet.WebApi.Owin.5.2.6\lib\net45\System.Web.Http.Owin.dll + + + + + + + + + + + DemoScheduler.cs + + + + + + + + + + + {89097967-adcb-4b14-8497-eb336c6c4cb3} + Quartzmin.SelfHost + + + + \ No newline at end of file diff --git a/Source/Examples/NetSelfHost/Program.cs b/Source/Examples/NetSelfHost/Program.cs new file mode 100644 index 0000000..5ca6e28 --- /dev/null +++ b/Source/Examples/NetSelfHost/Program.cs @@ -0,0 +1,21 @@ +using System; +using Quartzmin; +using System.Threading; + +namespace NetSelfHost +{ + class Program + { + static void Main(string[] args) + { + var scheduler = DemoScheduler.Create().Result; + scheduler.Start(); + + while (!scheduler.IsShutdown) + { + Console.WriteLine("Working"); + Thread.Sleep(500); + } + } + } +} diff --git a/Source/Examples/NetSelfHost/Properties/AssemblyInfo.cs b/Source/Examples/NetSelfHost/Properties/AssemblyInfo.cs new file mode 100644 index 0000000..eae749d --- /dev/null +++ b/Source/Examples/NetSelfHost/Properties/AssemblyInfo.cs @@ -0,0 +1,36 @@ +using System.Reflection; +using System.Runtime.CompilerServices; +using System.Runtime.InteropServices; + +// General Information about an assembly is controlled through the following +// set of attributes. Change these attribute values to modify the information +// associated with an assembly. +[assembly: AssemblyTitle("NetSelfHost")] +[assembly: AssemblyDescription("")] +[assembly: AssemblyConfiguration("")] +[assembly: AssemblyCompany("")] +[assembly: AssemblyProduct("NetSelfHost")] +[assembly: AssemblyCopyright("Copyright © 2020")] +[assembly: AssemblyTrademark("")] +[assembly: AssemblyCulture("")] + +// Setting ComVisible to false makes the types in this assembly not visible +// to COM components. If you need to access a type in this assembly from +// COM, set the ComVisible attribute to true on that type. +[assembly: ComVisible(false)] + +// The following GUID is for the ID of the typelib if this project is exposed to COM +[assembly: Guid("55bcc363-da5e-478b-9141-e570c63fbc2d")] + +// Version information for an assembly consists of the following four values: +// +// Major Version +// Minor Version +// Build Number +// Revision +// +// You can specify all the values or you can default the Build and Revision Numbers +// by using the '*' as shown below: +// [assembly: AssemblyVersion("1.0.*")] +[assembly: AssemblyVersion("1.0.0.0")] +[assembly: AssemblyFileVersion("1.0.0.0")] diff --git a/Source/Examples/NetSelfHost/packages.config b/Source/Examples/NetSelfHost/packages.config new file mode 100644 index 0000000..dd9c87b --- /dev/null +++ b/Source/Examples/NetSelfHost/packages.config @@ -0,0 +1,14 @@ + + + + + + + + + + + + + + \ No newline at end of file diff --git a/Source/Quartzmin.SelfHost/QuartzminPlugin.cs b/Source/Quartzmin.SelfHost/QuartzminPlugin.cs index 949feaa..4a658ed 100644 --- a/Source/Quartzmin.SelfHost/QuartzminPlugin.cs +++ b/Source/Quartzmin.SelfHost/QuartzminPlugin.cs @@ -21,6 +21,8 @@ public class QuartzminPlugin : ISchedulerPlugin public string Logo { get; set; } public string ProductName { get; set; } + public string VirtualPathRoot { get; set; } + private IScheduler _scheduler; private IDisposable _webApp; @@ -80,6 +82,8 @@ private QuartzminOptions CreateQuartzminOptions() options.Logo = Logo; if (!string.IsNullOrEmpty(ProductName)) options.ProductName = ProductName; + if (!string.IsNullOrEmpty(VirtualPathRoot)) + options.VirtualPathRoot = VirtualPathRoot; return options; }