Browse Source

Added HealthCheck in backgroundtasks. Modify k8s configuration to include new backgroundtask service. Modify ServiceFabric to include new service ( service fabric is not tested at this moment)

pull/491/head
Unai Zorrilla Castro 7 years ago
parent
commit
12a9cabf7b
21 changed files with 308 additions and 11 deletions
  1. +18
    -0
      ServiceFabric/Linux/eShopOnServiceFabric/ApplicationPackageRoot/ApplicationManifest.xml
  2. +0
    -2
      ServiceFabric/Linux/eShopOnServiceFabric/ApplicationPackageRoot/OrderingApiPkg/ServiceManifest.xml
  3. +9
    -0
      ServiceFabric/Linux/eShopOnServiceFabric/ApplicationPackageRoot/OrderingBackgroundPkg/Config/Settings.xml
  4. +48
    -0
      ServiceFabric/Linux/eShopOnServiceFabric/ApplicationPackageRoot/OrderingBackgroundPkg/ServiceManifest.xml
  5. +1
    -0
      ServiceFabric/Linux/eShopOnServiceFabric/ApplicationParameters/Cloud.xml
  6. +2
    -0
      ServiceFabric/Linux/eShopOnServiceFabric/eShopOnServiceFabric.sfproj
  7. +18
    -0
      ServiceFabric/Windows/eShopOnServiceFabric/ApplicationPackageRoot/ApplicationManifest.xml
  8. +0
    -2
      ServiceFabric/Windows/eShopOnServiceFabric/ApplicationPackageRoot/OrderingApiPkg/ServiceManifest.xml
  9. +9
    -0
      ServiceFabric/Windows/eShopOnServiceFabric/ApplicationPackageRoot/OrderingBackgroundPkg/Config/Settings.xml
  10. +50
    -0
      ServiceFabric/Windows/eShopOnServiceFabric/ApplicationPackageRoot/OrderingBackgroundPkg/ServiceManifest.xml
  11. +1
    -0
      ServiceFabric/Windows/eShopOnServiceFabric/ApplicationParameters/Cloud.xml
  12. +2
    -0
      ServiceFabric/Windows/eShopOnServiceFabric/eShopOnServiceFabric.sfproj
  13. +11
    -0
      docker-compose-windows.prod.yml
  14. +9
    -0
      docker-compose-windows.yml
  15. +6
    -1
      docker-compose.override.windows.yml
  16. +1
    -1
      eShopOnContainers-ServicesAndWebApps.sln
  17. +54
    -3
      eShopOnContainers.sln
  18. +1
    -1
      k8s/deploy.ps1
  19. +65
    -0
      k8s/deployments.yaml
  20. +2
    -1
      src/Services/Ordering/Ordering.BackgroundTasks/Ordering.BackgroundTasks.csproj
  21. +1
    -0
      src/Services/Ordering/Ordering.BackgroundTasks/Program.cs

+ 18
- 0
ServiceFabric/Linux/eShopOnServiceFabric/ApplicationPackageRoot/ApplicationManifest.xml View File

@ -5,6 +5,7 @@
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<Parameters>
<Parameter Name="OrderingBackground_InstanceCount" DefaultValue="-1" />
<Parameter Name="MarketingApi_InstanceCount" DefaultValue="-1" />
<Parameter Name="LocationsApi_InstanceCount" DefaultValue="-1" />
<Parameter Name="PaymentApi_InstanceCount" DefaultValue="-1" />
@ -19,6 +20,18 @@
<!-- Import the ServiceManifest from the ServicePackage. The ServiceManifestName and ServiceManifestVersion
should match the Name and Version attributes of the ServiceManifest element defined in the
ServiceManifest.xml file. -->
<ServiceManifestImport>
<ServiceManifestRef ServiceManifestName="OrderingBackgroundPkg" ServiceManifestVersion="1.0.0" />
<ConfigOverrides />
<EnvironmentOverrides CodePackageRef="Code">
<EnvironmentVariable Name="ApplicationInsights__InstrumentationKey" Value="[InstrumentationKey]"/>
</EnvironmentOverrides>
<Policies>
<ContainerHostPolicies CodePackageRef="Code">
<PortBinding ContainerPort="80" EndpointRef="OrderingBackgroundTypeEndpoint"/>
</ContainerHostPolicies>
</Policies>
</ServiceManifestImport>
<ServiceManifestImport>
<ServiceManifestRef ServiceManifestName="MarketingApiPkg" ServiceManifestVersion="1.0.0" />
@ -99,6 +112,11 @@
ServiceFabric PowerShell module.
The attribute ServiceTypeName below must match the name defined in the imported ServiceManifest.xml file. -->
<Service Name="OrderingBackground" ServicePackageActivationMode="ExclusiveProcess">
<StatelessService ServiceTypeName="OrderingBackgroundType" InstanceCount="[OrderingBackground_InstanceCount]">
<SingletonPartition />
</StatelessService>
</Service>
<Service Name="MarketingApi" ServiceDnsName="marketingapi.eshoponservicefabric" ServicePackageActivationMode="ExclusiveProcess">
<StatelessService ServiceTypeName="MarketingApiType" InstanceCount="[MarketingApi_InstanceCount]">


+ 0
- 2
ServiceFabric/Linux/eShopOnServiceFabric/ApplicationPackageRoot/OrderingApiPkg/ServiceManifest.xml View File

@ -28,8 +28,6 @@
<EnvironmentVariable Name="EventBusConnection" Value="rabbitmq.eshoponservicefabricbus"/>
<EnvironmentVariable Name="AzureServiceBusEnabled" Value="False"/>
<EnvironmentVariable Name="UseCustomizationData" Value="True"/>
<EnvironmentVariable Name="GracePeriodTime" Value="1"/>
<EnvironmentVariable Name="CheckUpdateTime" Value="30000"/>
<EnvironmentVariable Name="ApplicationInsights__InstrumentationKey" Value=""/>
<EnvironmentVariable Name="OrchestratorType" Value="SF"/>
<EnvironmentVariable Name="UseLoadTest" Value="True"/>


+ 9
- 0
ServiceFabric/Linux/eShopOnServiceFabric/ApplicationPackageRoot/OrderingBackgroundPkg/Config/Settings.xml View File

@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8" ?>
<Settings xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.microsoft.com/2011/01/fabric">
<!-- Add your custom configuration sections and parameters here -->
<!--
<Section Name="MyConfigSection">
<Parameter Name="MyParameter" Value="Value1" />
</Section>
-->
</Settings>

+ 48
- 0
ServiceFabric/Linux/eShopOnServiceFabric/ApplicationPackageRoot/OrderingBackgroundPkg/ServiceManifest.xml View File

@ -0,0 +1,48 @@
<?xml version="1.0" encoding="utf-8"?>
<ServiceManifest Name="OrderingBackgroundPkg"
Version="1.0.0"
xmlns="http://schemas.microsoft.com/2011/01/fabric"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<ServiceTypes>
<!-- This is the name of your ServiceType.
The UseImplicitHost attribute indicates this is a guest service. -->
<StatelessServiceType ServiceTypeName="OrderingBackgroundType" UseImplicitHost="true" />
</ServiceTypes>
<!-- Code package is your service executable. -->
<CodePackage Name="Code" Version="1.0.0">
<EntryPoint>
<!-- Follow this link for more information about deploying Windows containers to Service Fabric: https://aka.ms/sfguestcontainers -->
<ContainerHost>
<ImageName>eshop/ordering.backgroundtasks</ImageName>
</ContainerHost>
</EntryPoint>
<!-- Pass environment variables to your container: -->
<EnvironmentVariables>
<EnvironmentVariable Name="ASPNETCORE_ENVIRONMENT" Value="Development"/>
<EnvironmentVariable Name="ASPNETCORE_URLS" Value="http://0.0.0.0:80"/>
<EnvironmentVariable Name="ConnectionString" Value="Data Source=sqlserver.eshoponservicefabricsql,5433;Database=Microsoft.eShopOnContainers.Services.OrderingDb;User Id=sa;Password=Pass@word"/>
<EnvironmentVariable Name="EventBusConnection" Value="rabbitmq.eshoponservicefabricbus"/>
<EnvironmentVariable Name="AzureServiceBusEnabled" Value="False"/>
<EnvironmentVariable Name="GracePeriodTime" Value="1"/>
<EnvironmentVariable Name="CheckUpdateTime" Value="30000"/>
<EnvironmentVariable Name="ApplicationInsights__InstrumentationKey" Value=""/>
<EnvironmentVariable Name="OrchestratorType" Value="SF"/>
<EnvironmentVariable Name="UseLoadTest" Value="True"/>
</EnvironmentVariables>
</CodePackage>
<!-- Config package is the contents of the Config directoy under PackageRoot that contains an
independently-updateable and versioned set of custom configuration settings for your service. -->
<ConfigPackage Name="Config" Version="1.0.0" />
<Resources>
<Endpoints>
<!-- This endpoint is used by the communication listener to obtain the port on which to
listen. Please note that if your service is partitioned, this port is shared with
replicas of different partitions that are placed in your code. -->
<Endpoint Name="OrderingBackgroundTypeEndpoint" Port="5111" UriScheme="http"/>
</Endpoints>
</Resources>
</ServiceManifest>

+ 1
- 0
ServiceFabric/Linux/eShopOnServiceFabric/ApplicationParameters/Cloud.xml View File

@ -1,6 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<Application Name="fabric:/eShopOnServiceFabric" xmlns="http://schemas.microsoft.com/2011/01/fabric" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<Parameters>
<Parameter Name="OrderingBackground_InstanceCount" Value="-1" />
<Parameter Name="MarketingApi_InstanceCount" Value="1" />
<Parameter Name="LocationsApi_InstanceCount" Value="1" />
<Parameter Name="PaymentApi_InstanceCount" Value="1" />


+ 2
- 0
ServiceFabric/Linux/eShopOnServiceFabric/eShopOnServiceFabric.sfproj View File

@ -38,6 +38,8 @@
<Content Include="ApplicationPackageRoot\MarketingApiPkg\ServiceManifest.xml" />
<Content Include="ApplicationPackageRoot\OrderingApiPkg\Config\Settings.xml" />
<Content Include="ApplicationPackageRoot\OrderingApiPkg\ServiceManifest.xml" />
<Content Include="ApplicationPackageRoot\OrderingBackgroundPkg\Config\Settings.xml" />
<Content Include="ApplicationPackageRoot\OrderingBackgroundPkg\ServiceManifest.xml" />
<Content Include="ApplicationPackageRoot\PaymentApiPkg\Config\Settings.xml" />
<Content Include="ApplicationPackageRoot\PaymentApiPkg\ServiceManifest.xml" />
<Content Include="packages.config" />


+ 18
- 0
ServiceFabric/Windows/eShopOnServiceFabric/ApplicationPackageRoot/ApplicationManifest.xml View File

@ -5,6 +5,7 @@
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<Parameters>
<Parameter Name="OrderingBackground_InstanceCount" DefaultValue="-1" />
<Parameter Name="MarketingApi_InstanceCount" DefaultValue="-1" />
<Parameter Name="LocationsApi_InstanceCount" DefaultValue="-1" />
<Parameter Name="PaymentApi_InstanceCount" DefaultValue="-1" />
@ -19,6 +20,18 @@
<!-- Import the ServiceManifest from the ServicePackage. The ServiceManifestName and ServiceManifestVersion
should match the Name and Version attributes of the ServiceManifest element defined in the
ServiceManifest.xml file. -->
<ServiceManifestImport>
<ServiceManifestRef ServiceManifestName="OrderingBackgroundPkg" ServiceManifestVersion="1.0.0" />
<ConfigOverrides />
<EnvironmentOverrides CodePackageRef="Code">
<EnvironmentVariable Name="ApplicationInsights:InstrumentationKey" Value="[InstrumentationKey]"/>
</EnvironmentOverrides>
<Policies>
<ContainerHostPolicies CodePackageRef="Code">
<PortBinding ContainerPort="80" EndpointRef="OrderingBackgroundTasksTypeEndpoint"/>
</ContainerHostPolicies>
</Policies>
</ServiceManifestImport>
<ServiceManifestImport>
<ServiceManifestRef ServiceManifestName="MarketingApiPkg" ServiceManifestVersion="1.0.0" />
@ -99,6 +112,11 @@
ServiceFabric PowerShell module.
The attribute ServiceTypeName below must match the name defined in the imported ServiceManifest.xml file. -->
<Service Name="OrderingBackground" ServicePackageActivationMode="ExclusiveProcess">
<StatelessService ServiceTypeName="OrderingBackgroundType" InstanceCount="[OrderingBackground_InstanceCount]">
<SingletonPartition />
</StatelessService>
</Service>
<Service Name="MarketingApi" ServiceDnsName="marketingapi.eshoponservicefabric" ServicePackageActivationMode="ExclusiveProcess">
<StatelessService ServiceTypeName="MarketingApiType" InstanceCount="[MarketingApi_InstanceCount]">


+ 0
- 2
ServiceFabric/Windows/eShopOnServiceFabric/ApplicationPackageRoot/OrderingApiPkg/ServiceManifest.xml View File

@ -28,8 +28,6 @@
<EnvironmentVariable Name="EventBusConnection" Value="rabbitmq.eshoponservicefabricbus"/>
<EnvironmentVariable Name="AzureServiceBusEnabled" Value="False"/>
<EnvironmentVariable Name="UseCustomizationData" Value="True"/>
<EnvironmentVariable Name="GracePeriodTime" Value="1"/>
<EnvironmentVariable Name="CheckUpdateTime" Value="30000"/>
<EnvironmentVariable Name="EventBusUserName" Value="admin"/>
<EnvironmentVariable Name="EventBusPassword" Value="password"/>
<EnvironmentVariable Name="ApplicationInsights:InstrumentationKey" Value=""/>


+ 9
- 0
ServiceFabric/Windows/eShopOnServiceFabric/ApplicationPackageRoot/OrderingBackgroundPkg/Config/Settings.xml View File

@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8" ?>
<Settings xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.microsoft.com/2011/01/fabric">
<!-- Add your custom configuration sections and parameters here -->
<!--
<Section Name="MyConfigSection">
<Parameter Name="MyParameter" Value="Value1" />
</Section>
-->
</Settings>

+ 50
- 0
ServiceFabric/Windows/eShopOnServiceFabric/ApplicationPackageRoot/OrderingBackgroundPkg/ServiceManifest.xml View File

@ -0,0 +1,50 @@
<?xml version="1.0" encoding="utf-8"?>
<ServiceManifest Name="OrderingBackgroundPkg"
Version="1.0.0"
xmlns="http://schemas.microsoft.com/2011/01/fabric"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<ServiceTypes>
<!-- This is the name of your ServiceType.
The UseImplicitHost attribute indicates this is a guest service. -->
<StatelessServiceType ServiceTypeName="OrderingBackgroundType" UseImplicitHost="true" />
</ServiceTypes>
<!-- Code package is your service executable. -->
<CodePackage Name="Code" Version="1.0.0">
<EntryPoint>
<!-- Follow this link for more information about deploying Windows containers to Service Fabric: https://aka.ms/sfguestcontainers -->
<ContainerHost>
<ImageName>eshop/ordering.backgroundtasks-win</ImageName>
</ContainerHost>
</EntryPoint>
<!-- Pass environment variables to your container: -->
<EnvironmentVariables>
<EnvironmentVariable Name="ASPNETCORE_ENVIRONMENT" Value="Development"/>
<EnvironmentVariable Name="ASPNETCORE_URLS" Value="http://0.0.0.0:80"/>
<EnvironmentVariable Name="ConnectionString" Value="Data Source=sqlserver.eshoponservicefabricsql,5433;Database=Microsoft.eShopOnContainers.Services.OrderingDb;User Id=sa;Password=Pass@word"/>
<EnvironmentVariable Name="EventBusConnection" Value="rabbitmq.eshoponservicefabricbus"/>
<EnvironmentVariable Name="AzureServiceBusEnabled" Value="False"/>
<EnvironmentVariable Name="GracePeriodTime" Value="1"/>
<EnvironmentVariable Name="CheckUpdateTime" Value="30000"/>
<EnvironmentVariable Name="EventBusUserName" Value="admin"/>
<EnvironmentVariable Name="EventBusPassword" Value="password"/>
<EnvironmentVariable Name="ApplicationInsights:InstrumentationKey" Value=""/>
<EnvironmentVariable Name="OrchestratorType" Value="SF"/>
<EnvironmentVariable Name="UseLoadTest" Value="False"/>
</EnvironmentVariables>
</CodePackage>
<!-- Config package is the contents of the Config directoy under PackageRoot that contains an
independently-updateable and versioned set of custom configuration settings for your service. -->
<ConfigPackage Name="Config" Version="1.0.0" />
<Resources>
<Endpoints>
<!-- This endpoint is used by the communication listener to obtain the port on which to
listen. Please note that if your service is partitioned, this port is shared with
replicas of different partitions that are placed in your code. -->
<Endpoint Name="OrderingBackgroundTasksTypeEndpoint" Port="5111" UriScheme="http" PathSuffix="eShopOnServiceFabric/OrderingBackgroundTasks"/>
</Endpoints>
</Resources>
</ServiceManifest>

+ 1
- 0
ServiceFabric/Windows/eShopOnServiceFabric/ApplicationParameters/Cloud.xml View File

@ -1,6 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<Application Name="fabric:/eShopOnServiceFabric" xmlns="http://schemas.microsoft.com/2011/01/fabric" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<Parameters>
<Parameter Name="OrderingBackground_InstanceCount" Value="-1" />
<Parameter Name="MarketingApi_InstanceCount" Value="1" />
<Parameter Name="LocationsApi_InstanceCount" Value="1" />
<Parameter Name="PaymentApi_InstanceCount" Value="1" />


+ 2
- 0
ServiceFabric/Windows/eShopOnServiceFabric/eShopOnServiceFabric.sfproj View File

@ -38,6 +38,8 @@
<Content Include="ApplicationPackageRoot\MarketingApiPkg\ServiceManifest.xml" />
<Content Include="ApplicationPackageRoot\OrderingApiPkg\Config\Settings.xml" />
<Content Include="ApplicationPackageRoot\OrderingApiPkg\ServiceManifest.xml" />
<Content Include="ApplicationPackageRoot\OrderingBackgroundPkg\Config\Settings.xml" />
<Content Include="ApplicationPackageRoot\OrderingBackgroundPkg\ServiceManifest.xml" />
<Content Include="ApplicationPackageRoot\PaymentApiPkg\Config\Settings.xml" />
<Content Include="ApplicationPackageRoot\PaymentApiPkg\ServiceManifest.xml" />
<Content Include="packages.config" />


+ 11
- 0
docker-compose-windows.prod.yml View File

@ -68,6 +68,17 @@ services:
- AzureServiceBusEnabled=False
ports:
- "5102:80"
ordering.backgroundtasks:
environment:
- ASPNETCORE_ENVIRONMENT=Production
- ASPNETCORE_URLS=http://0.0.0.0:80
- ConnectionString=${ESHOP_AZURE_ORDERING_DB:-Server=sql.data;Database=Microsoft.eShopOnContainers.Services.OrderingDb;User Id=sa;Password=Pass@word}
- EventBusConnection=${ESHOP_AZURE_SERVICE_BUS:-rabbitmq}
- UseCustomizationData=True
- AzureServiceBusEnabled=False
ports:
- "5111:80"
webspa:
environment:


+ 9
- 0
docker-compose-windows.yml View File

@ -37,6 +37,15 @@ services:
- sql.data
- rabbitmq
ordering.backgroundtasks:
image: eshop/ordering.backgroundtasks-win:${TAG:-latest}
build:
context: .
dockerfile: src/Services/Ordering/Ordering.BackgroundTasks/Dockerfile
depends_on:
- sql.data
- rabbitmq
marketing.api:
image: eshop/marketing.api-win:${TAG:-latest}
build:


+ 6
- 1
docker-compose.override.windows.yml View File

@ -37,7 +37,12 @@ services:
- EventBusUserName=admin
- EventBusPassword=password
marketing.api:
ordering.api:
environment:
- EventBusUserName=admin
- EventBusPassword=password
ordering.backgroundtasks:
environment:
- EventBusUserName=admin
- EventBusPassword=password


+ 1
- 1
eShopOnContainers-ServicesAndWebApps.sln View File

@ -97,7 +97,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "WebHost", "WebHost", "{1815
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "WebHost.Customization", "src\BuildingBlocks\WebHostCustomization\WebHost.Customization\WebHost.Customization.csproj", "{15F4B3AA-89B6-4A0D-9051-414305974781}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Ordering.BackgroundTasks", "src\Services\Ordering\Ordering.BackgroundTasks\Ordering.BackgroundTasks.csproj", "{2FF56999-0266-48B2-ACC1-FEBC482A5105}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Ordering.BackgroundTasks", "src\Services\Ordering\Ordering.BackgroundTasks\Ordering.BackgroundTasks.csproj", "{2FF56999-0266-48B2-ACC1-FEBC482A5105}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution


+ 54
- 3
eShopOnContainers.sln View File

@ -1,7 +1,7 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 15
VisualStudioVersion = 15.0.27130.2010
VisualStudioVersion = 15.0.27130.2024
MinimumVisualStudioVersion = 10.0.40219.1
Project("{E53339B2-1760-4266-BCC7-CA923CBCF16C}") = "docker-compose", "docker-compose.dcproj", "{FEA0C318-FFED-4D39-8781-265718CA43DD}"
EndProject
@ -103,7 +103,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Shared Code", "Shared Code"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Targets", "Targets", "{2BB81612-8D04-49CD-B17F-38DAB176E583}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "eShopOnContainers.Core", "src\Mobile\eShopOnContainers\eShopOnContainers.Core\eShopOnContainers.Core.csproj", "{BA96A12C-4EE3-46C4-BB3F-F811B554CD01}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "eShopOnContainers.Core", "src\Mobile\eShopOnContainers\eShopOnContainers.Core\eShopOnContainers.Core.csproj", "{BA96A12C-4EE3-46C4-BB3F-F811B554CD01}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "eShopOnContainers.Droid", "src\Mobile\eShopOnContainers\eShopOnContainers.Droid\eShopOnContainers.Droid.csproj", "{62DBB163-9CA9-4818-B48B-13233DF37C24}"
EndProject
@ -113,7 +113,7 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "eShopOnContainers.Windows",
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Mobile Apps", "Mobile Apps", "{0AAED9FF-3260-43BB-B586-9AAF1E010A90}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "eShopOnContainers.UnitTests", "src\Mobile\eShopOnContainers\eShopOnContainers.UnitTests\eShopOnContainers.UnitTests.csproj", "{6E4285E7-7611-4440-A1B5-3513EBB13807}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "eShopOnContainers.UnitTests", "src\Mobile\eShopOnContainers\eShopOnContainers.UnitTests\eShopOnContainers.UnitTests.csproj", "{6E4285E7-7611-4440-A1B5-3513EBB13807}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "eShopOnContainers.TestRunner.Droid", "src\Mobile\eShopOnContainers\eShopOnContainers.TestRunner.Droid\eShopOnContainers.TestRunner.Droid.csproj", "{A289A7F0-ACD8-42AE-87B6-AB1AFD310BF1}"
EndProject
@ -121,6 +121,8 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "eShopOnContainers.TestRunne
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "eShopOnContainers.TestRunner.Windows", "src\Mobile\eShopOnContainers\eShopOnContainers.TestRunner.Windows\eShopOnContainers.TestRunner.Windows.csproj", "{A7337243-33B8-463A-87AD-944B75EFD820}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Ordering.BackgroundTasks", "src\Services\Ordering\Ordering.BackgroundTasks\Ordering.BackgroundTasks.csproj", "{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Ad-Hoc|Any CPU = Ad-Hoc|Any CPU
@ -1759,6 +1761,54 @@ Global
{A7337243-33B8-463A-87AD-944B75EFD820}.Release|x86.ActiveCfg = Release|x86
{A7337243-33B8-463A-87AD-944B75EFD820}.Release|x86.Build.0 = Release|x86
{A7337243-33B8-463A-87AD-944B75EFD820}.Release|x86.Deploy.0 = Release|x86
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Ad-Hoc|Any CPU.ActiveCfg = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Ad-Hoc|Any CPU.Build.0 = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Ad-Hoc|ARM.ActiveCfg = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Ad-Hoc|ARM.Build.0 = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Ad-Hoc|iPhone.ActiveCfg = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Ad-Hoc|iPhone.Build.0 = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Ad-Hoc|iPhoneSimulator.ActiveCfg = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Ad-Hoc|iPhoneSimulator.Build.0 = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Ad-Hoc|x64.ActiveCfg = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Ad-Hoc|x64.Build.0 = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Ad-Hoc|x86.ActiveCfg = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Ad-Hoc|x86.Build.0 = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.AppStore|Any CPU.ActiveCfg = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.AppStore|Any CPU.Build.0 = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.AppStore|ARM.ActiveCfg = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.AppStore|ARM.Build.0 = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.AppStore|iPhone.ActiveCfg = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.AppStore|iPhone.Build.0 = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.AppStore|iPhoneSimulator.ActiveCfg = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.AppStore|iPhoneSimulator.Build.0 = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.AppStore|x64.ActiveCfg = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.AppStore|x64.Build.0 = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.AppStore|x86.ActiveCfg = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.AppStore|x86.Build.0 = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Debug|Any CPU.Build.0 = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Debug|ARM.ActiveCfg = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Debug|ARM.Build.0 = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Debug|iPhone.ActiveCfg = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Debug|iPhone.Build.0 = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Debug|iPhoneSimulator.ActiveCfg = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Debug|iPhoneSimulator.Build.0 = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Debug|x64.ActiveCfg = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Debug|x64.Build.0 = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Debug|x86.ActiveCfg = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Debug|x86.Build.0 = Debug|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Release|Any CPU.ActiveCfg = Release|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Release|Any CPU.Build.0 = Release|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Release|ARM.ActiveCfg = Release|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Release|ARM.Build.0 = Release|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Release|iPhone.ActiveCfg = Release|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Release|iPhone.Build.0 = Release|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Release|iPhoneSimulator.ActiveCfg = Release|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Release|iPhoneSimulator.Build.0 = Release|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Release|x64.ActiveCfg = Release|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Release|x64.Build.0 = Release|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Release|x86.ActiveCfg = Release|Any CPU
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480}.Release|x86.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
@ -1817,6 +1867,7 @@ Global
{A289A7F0-ACD8-42AE-87B6-AB1AFD310BF1} = {0AAED9FF-3260-43BB-B586-9AAF1E010A90}
{B68C2B56-7581-46AE-B55D-D25DDFD3BFE3} = {0AAED9FF-3260-43BB-B586-9AAF1E010A90}
{A7337243-33B8-463A-87AD-944B75EFD820} = {0AAED9FF-3260-43BB-B586-9AAF1E010A90}
{16CDE5D2-2DDE-4AF2-B902-AD9CC42DE480} = {0BD0DB92-2D98-44D9-9AC0-C59186D59B0B}
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {25728519-5F0F-4973-8A64-0A81EB4EA8D9}


+ 1
- 1
k8s/deploy.ps1 View File

@ -62,7 +62,7 @@ if ($buildImages) {
docker-compose -p .. -f ../docker-compose.yml build
Write-Host "Pushing images to $registry/$dockerOrg..." -ForegroundColor Yellow
$services = ("basket.api", "catalog.api", "identity.api", "ordering.api", "marketing.api","payment.api","locations.api", "webmvc", "webspa", "webstatus")
$services = ("basket.api", "catalog.api", "identity.api", "ordering.api", "ordering.backgroundtasks", "marketing.api","payment.api","locations.api", "webmvc", "webspa", "webstatus")
foreach ($service in $services) {
$imageFqdn = if ($useDockerHub) {"$dockerOrg/${service}"} else {"$registry/$dockerOrg/${service}"}


+ 65
- 0
k8s/deployments.yaml View File

@ -259,6 +259,71 @@ spec:
configMapKeyRef:
name: urls
key: IdentityUrl
- name: ApplicationInsights__InstrumentationKey
valueFrom:
configMapKeyRef:
name: externalcfg
key: Instrumentation_Key
- name: UseLoadTest
valueFrom:
configMapKeyRef:
name: externalcfg
key: EnableLoadTest
- name: OrchestratorType
value: 'K8S'
ports:
- containerPort: 80
readinessProbe:
httpGet:
path: /hc
port: 80
scheme: HTTP
initialDelaySeconds: 5
periodSeconds: 10
livenessProbe:
httpGet:
path: /hc
port: 80
scheme: HTTP
initialDelaySeconds: 60
periodSeconds: 10
imagePullSecrets:
- name: registry-key
---
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
name: ordering.backgroundtasks
spec:
paused: true
template:
metadata:
labels:
app: eshop
component: orderingbackground
spec:
containers:
- name: ordering
image: eshop/ordering.backgroundtasks
imagePullPolicy: Always
env:
- name: PATH_BASE
value: /ordering-backgroundtasks
- name: ConnectionString
valueFrom:
configMapKeyRef:
name: externalcfg
key: OrderingSqlDb
- name: EventBusConnection
valueFrom:
configMapKeyRef:
name: externalcfg
key: OrderingBus
- name: AzureServiceBusEnabled
valueFrom:
configMapKeyRef:
name: externalcfg
key: UseAzureServiceBus
- name: CheckUpdateTime
valueFrom:
configMapKeyRef:


+ 2
- 1
src/Services/Ordering/Ordering.BackgroundTasks/Ordering.BackgroundTasks.csproj View File

@ -2,6 +2,7 @@
<PropertyGroup>
<TargetFramework>netcoreapp2.0</TargetFramework>
<AssetTargetFallback>$(AssetTargetFallback);portable-net45+win8+wp8+wpa81;</AssetTargetFallback>
<DockerComposeProjectPath>..\..\..\..\docker-compose.dcproj</DockerComposeProjectPath>
</PropertyGroup>
@ -12,7 +13,7 @@
<ItemGroup>
<PackageReference Include="Autofac.Extensions.DependencyInjection" Version="4.2.0" />
<PackageReference Include="Dapper" Version="1.50.4" />
<PackageReference Include="Microsoft.AspNetCore.All" Version="2.0.5" />
<PackageReference Include="Microsoft.AspNetCore.All" Version="2.0.3" />
</ItemGroup>
<ItemGroup>


+ 1
- 0
src/Services/Ordering/Ordering.BackgroundTasks/Program.cs View File

@ -14,6 +14,7 @@ namespace Ordering.BackgroundTasks
public static IWebHost BuildWebHost(string[] args) =>
WebHost.CreateDefaultBuilder(args)
.UseStartup<Startup>()
.UseHealthChecks("/hc")
.ConfigureLogging((hostingContext, builder) =>
{
builder.AddConfiguration(hostingContext.Configuration.GetSection("Logging"));


Loading…
Cancel
Save