简体   繁体   English

人工延迟

[英]Artifactory Delay

As we noticed that with artifacts uploaded to Artifactory, they do not appear available via pip straight away. 正如我们注意到的,在将工件上传到Artifactory时,它们不会立即通过点子显示。 As minimum 5 minutes before they can be downloaded and installed via pip. 至少需要5分钟才能通过pip下载和安装它们。 It seems like they are not indexed straight away or waiting for some timeslot to do so. 似乎它们没有立即索引或等待某个时隙索引。 Could not find any configuration related to this which is not helpful. 找不到与此无关的任何配置。

I found this , which might be helpful to you: 我找到 ,这可能对您有帮助:

When you upload many Pypi packages to the same repository within a close period of time the indexing does not happen immediately. 当您在很短的时间内将许多Pypi软件包上传到同一存储库时,索引编制不会立即发生。 It waits for a "quiet period" which can be adjusted. 它等待一个可以调整的“安静期”。 This can be done in the $ARTIFACTORY_HOME/etc/artifactory.system.properties file by setting the values of the artifactory.pypi.index.quietPeriodSecs and the artifactory.pypi.index.sleepMilliSecs properties to an amount of seconds that meets your needs. 可以在$ARTIFACTORY_HOME/etc/artifactory.system.properties文件中,通过将artifactory.pypi.index.quietPeriodSecsartifactory.pypi.index.sleepMilliSecs属性的值设置为满足您需要的秒数来完成此操作。 If those parameters do not exist, please add them to the file. 如果这些参数不存在,请将其添加到文件中。 You will need to restart Artifactory for this setting to take affect. 您需要重新启动Artifactory才能使此设置生效。

From what I can tell, if these values aren't in that file, both default to 60 . 据我所知,如果这些值不在该文件中,则两者都默认为60 Also sleepMilliSecs appears to be a number of seconds, not milliseconds as the name would suggest. 同样, sleepMilliSecs似乎是秒数,而不是顾名思义的毫秒数。

I believe how this works is, Artifactory waits for the repository to "settle", until there hasn't been any changes (deployed or removed packages) for at least quietPeriodSecs seconds. 我相信这是如何工作的,Artifactory等待存储库“结算”,直到至少quietPeriodSecs秒没有任何更改(部署或删除软件包)。 It will check for this every sleepMilliSecs seconds. 它将每sleepMilliSecs秒检查一次。


Five minutes seems like a long time. 五分钟似乎很长一段时间。 If you're making a series of changes with under a minute before each change, that might explain why it's taking a while. 如果要在每次更改前不到一分钟进行一系列更改,则可能会解释为什么要花一些时间。 Also, the larger your repository is, the longer the indexing will take once it starts, so that might also be a factor. 另外,您的存储库越大,索引一旦开始就将花费更长的时间,因此这也可能是一个因素。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM