Пример #1
0
        public async Task RunAsync(CancellationToken ct)
        {
            if (rebuildOptions.Apps)
            {
                await rebuilder.RebuildAppsAsync(ct);
            }

            if (rebuildOptions.Schemas)
            {
                await rebuilder.RebuildSchemasAsync(ct);
            }

            if (rebuildOptions.Rules)
            {
                await rebuilder.RebuildRulesAsync(ct);
            }

            if (rebuildOptions.Assets)
            {
                await rebuilder.RebuildAssetsAsync(ct);
            }

            if (rebuildOptions.Contents)
            {
                await rebuilder.RebuildContentAsync(ct);
            }

            if (rebuildOptions.Indexes)
            {
                await populateGrainIndexes.UpdateAsync();
            }
        }
Пример #2
0
        public async Task RunAsync(CancellationToken ct)
        {
            var batchSize = rebuildOptions.CalculateBatchSize();

            if (rebuildOptions.Apps)
            {
                await rebuilder.RebuildAppsAsync(batchSize, ct);
            }

            if (rebuildOptions.Schemas)
            {
                await rebuilder.RebuildSchemasAsync(batchSize, ct);
            }

            if (rebuildOptions.Rules)
            {
                await rebuilder.RebuildRulesAsync(batchSize, ct);
            }

            if (rebuildOptions.Assets)
            {
                await rebuilder.RebuildAssetsAsync(batchSize, ct);

                await rebuilder.RebuildAssetFoldersAsync(batchSize, ct);
            }

            if (rebuildOptions.AssetFiles)
            {
                await rebuildFiles.RepairAsync(ct);
            }

            if (rebuildOptions.Contents)
            {
                await rebuilder.RebuildContentAsync(batchSize, ct);
            }

            if (rebuildOptions.Indexes)
            {
                await populateGrainIndexes.UpdateAsync(ct);
            }
        }