Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
05/11/10 16:47:12 (14 years ago)
Author:
gkronber
Message:

Prepared deployment service proxy classes for migration of deployment server to a production environment. #989

Location:
trunk/sources/HeuristicLab.PluginInfrastructure/Advanced
Files:
2 added
1 deleted
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.PluginInfrastructure/Advanced/DeploymentService/AdminClientFactory.cs

    r3112 r3771  
    3939    /// </summary>
    4040    static AdminClientFactory() {
    41       var stream = Assembly.GetExecutingAssembly().GetManifestResourceStream("HeuristicLab.PluginInfrastructure.Advanced.DeploymentService.servdev.cer");
     41      var stream = Assembly.GetExecutingAssembly().GetManifestResourceStream("HeuristicLab.PluginInfrastructure.Advanced.DeploymentService.services.heuristiclab.com.cer");
    4242      serverCrtData = new byte[stream.Length];
    4343      stream.Read(serverCrtData, 0, serverCrtData.Length);
     
    5858      client.ClientCredentials.UserName.Password = HeuristicLab.PluginInfrastructure.Properties.Settings.Default.UpdateLocationPassword;
    5959      client.Endpoint.Address = new EndpointAddress(HeuristicLab.PluginInfrastructure.Properties.Settings.Default.UpdateLocationAdministrationAddress);
    60       client.ClientCredentials.ServiceCertificate.DefaultCertificate = new X509Certificate2(serverCrtData);
    61       client.ClientCredentials.ServiceCertificate.Authentication.CertificateValidationMode = System.ServiceModel.Security.X509CertificateValidationMode.None;
     60      client.ClientCredentials.ServiceCertificate.Authentication.CertificateValidationMode = System.ServiceModel.Security.X509CertificateValidationMode.Custom;
     61      client.ClientCredentials.ServiceCertificate.Authentication.CustomCertificateValidator =
     62          new DeploymentServerCertificateValidator(new X509Certificate2(serverCrtData));
     63
    6264      return client;
    6365    }
  • trunk/sources/HeuristicLab.PluginInfrastructure/Advanced/DeploymentService/RegenerateServiceClasses.cmd

    r3179 r3771  
    11#
    2 svcutil http://servdev.heuristiclab.com/Deployment-3.3/Update.svc/mex http://servdev.heuristiclab.com/Deployment-3.3/Admin.svc/mex  /language:C# /targetClientVersion:Version35 /out:DeploymentService /namespace:*,HeuristicLab.PluginInfrastructure.Advanced.DeploymentService /mergeConfig /config:../../app.config
     2svcutil http://services.heuristiclab.com/Deployment-3.3/Update.svc/mex http://services.heuristiclab.com/Deployment-3.3/Admin.svc/mex  /language:C# /targetClientVersion:Version35 /out:DeploymentService /namespace:*,HeuristicLab.PluginInfrastructure.Advanced.DeploymentService /mergeConfig /config:../../app.config
  • trunk/sources/HeuristicLab.PluginInfrastructure/Advanced/DeploymentService/UpdateClientFactory.cs

    r3112 r3771  
    3939    /// </summary>
    4040    static UpdateClientFactory() {
    41       var stream = Assembly.GetExecutingAssembly().GetManifestResourceStream("HeuristicLab.PluginInfrastructure.Advanced.DeploymentService.servdev.cer");
     41      var stream = Assembly.GetExecutingAssembly().GetManifestResourceStream("HeuristicLab.PluginInfrastructure.Advanced.DeploymentService.services.heuristiclab.com.cer");
    4242      serverCrtData = new byte[stream.Length];
    4343      stream.Read(serverCrtData, 0, serverCrtData.Length);
     
    5858      client.ClientCredentials.UserName.Password = HeuristicLab.PluginInfrastructure.Properties.Settings.Default.UpdateLocationPassword;
    5959      client.Endpoint.Address = new EndpointAddress(HeuristicLab.PluginInfrastructure.Properties.Settings.Default.UpdateLocation);
    60       client.ClientCredentials.ServiceCertificate.DefaultCertificate = new X509Certificate2(serverCrtData);
    61       client.ClientCredentials.ServiceCertificate.Authentication.CertificateValidationMode = System.ServiceModel.Security.X509CertificateValidationMode.None;
     60      client.ClientCredentials.ServiceCertificate.Authentication.CertificateValidationMode = System.ServiceModel.Security.X509CertificateValidationMode.Custom;
     61      client.ClientCredentials.ServiceCertificate.Authentication.CustomCertificateValidator =
     62          new DeploymentServerCertificateValidator(new X509Certificate2(serverCrtData));
    6263      return client;
    6364    }
  • trunk/sources/HeuristicLab.PluginInfrastructure/Advanced/EditProductsView.cs

    r3721 r3771  
    139139      try {
    140140        foreach (var product in products) {
    141           adminClient.DeployProduct(product);
     141          // only upload necessary data (product name and version, and for each plugin only plugin name and version)
     142          var lightWeightProduct = new DeploymentService.ProductDescription(product.Name, product.Version);
     143          lightWeightProduct.Plugins = (from plugin in product.Plugins
     144                                        select new DeploymentService.PluginDescription(plugin.Name, plugin.Version)).ToArray();
     145          adminClient.DeployProduct(lightWeightProduct);
    142146        }
    143147        adminClient.Close();
Note: See TracChangeset for help on using the changeset viewer.