[英]Write on a folder location on the web servers of a web farm
I have a web application hosted on a web farm. 我在Web场上托管了一个Web应用程序。 In the application there is a functionality where by user can write the files on a folder located on the virtual directory in the IIS like this: 在应用程序中,有一种功能,用户可以通过该功能将文件写入IIS中虚拟目录下的文件夹中,如下所示:
var compressedFile = FileCompression.GetCompressedAndEncrypted(xml);
File.WriteAllBytes((filePath), compressedFile);
The issue here is that only the server that hooked to the client gets the updated files, but the requirement is to do this on both the servers of the farm simultaneously . 这里的问题是,只有挂接到客户端的服务器才能获取更新的文件,但要求同时在服务器场的两台服务器上执行此操作 。 There are two servers in the farm. 服务器场中有两个服务器。
I want to achieve this programmatically. 我想以编程方式实现这一目标。 Please suggest... 请建议...
You can do one of the following - 您可以执行以下任一操作-
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.