This WorkUnit was responsible for processing a given file to find the maximum MDU. The code looked something like this
WorkUnit负责处理指定的文件,找出MDU最大值。
For each file in a given directory, the Master created a WorkUnit, providing it with location of the file it was to process.
对于指定目录下的每个文件,Master都创建一个WorkUnit,向它提供要处理的文件的位置。
From a performance perspective, we didn't want Terracotta to have to synchronize access to these WorkUnit attributes if the Master will never access them.
从性能角度来看,如果Master永不访问WorkUnit的属性,那么我们是不希望Terracotta对这些属性的访问进行同步的。
For in a more realistic and complex example, the WorkUnit may have many instance variables that are really only relevant when it is being run by the Worker.
举一个更为现实和复杂的例子,WorkUnit可能有很多实例变量,它们实际上只在由Worker运行的时候才是相关的。
Provided that your machine is successfully completing work, uploading the results, and downloading work, the occasional lost Workunit is nothing to worry about.
如果您的机器正常地完成工作,上传结果,下载工作的话,偶尔丢失工作单元是不用担忧的。
Provided that your machine is successfully completing work, uploading the results, and downloading work, the occasional lost Workunit is nothing to worry about.
如果您的机器正常地完成工作,上传结果,下载工作的话,偶尔丢失工作单元是不用担忧的。
应用推荐