Skip to content

Commit c3ec26f

Browse files
authored
Refactor AdminConsole vs. OptionalFeatureService (#1091)
1 parent 78bde11 commit c3ec26f

1 file changed

Lines changed: 10 additions & 5 deletions

File tree

src/org/labkey/targetedms/TargetedMSModule.java

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@
4848
import org.labkey.api.security.permissions.AdminPermission;
4949
import org.labkey.api.security.permissions.ApplicationAdminPermission;
5050
import org.labkey.api.settings.AdminConsole;
51+
import org.labkey.api.settings.OptionalFeatureFlag;
5152
import org.labkey.api.settings.OptionalFeatureService;
5253
import org.labkey.api.targetedms.TargetedMSService;
5354
import org.labkey.api.usageMetrics.UsageMetricsService;
@@ -217,11 +218,6 @@ public TargetedMSModule()
217218
MAX_PRECURSORS_PROPERTY.setDescription("If a document has more than a specified number of precursors AND more than the separate transition/replicate chromatogram limit, Panorama will skip storing them in the database to save space and import time");
218219
MAX_PRECURSORS_PROPERTY.setShowDescriptionInline(true);
219220
addModuleProperty(MAX_PRECURSORS_PROPERTY);
220-
221-
AdminConsole.addOptionalFeatureFlag(new AdminConsole.OptionalFeatureFlag(USE_TEMP_DIR_FOR_SKYD_IMPORT,
222-
"Stage SKYD files to a temporary local file for import purposes",
223-
"When using a non-local file system, the latency for random access requests can be significantly slower than first copying to local storage",
224-
false, false, OptionalFeatureService.FeatureType.Optional));
225221
}
226222

227223
@Override
@@ -606,6 +602,15 @@ protected void init()
606602
{
607603
folderRegistry.addFactories(new QCFolderWriterFactory(), new QCFolderImporter.Factory());
608604
}
605+
606+
OptionalFeatureService.get().addFeatureFlag(
607+
new OptionalFeatureFlag(
608+
USE_TEMP_DIR_FOR_SKYD_IMPORT,
609+
"Stage SKYD files to a temporary local file for import purposes",
610+
"When using a non-local file system, the latency for random access requests can be significantly slower than first copying to local storage",
611+
false, false, OptionalFeatureService.FeatureType.Optional
612+
)
613+
);
609614
}
610615

611616
@Override

0 commit comments

Comments
 (0)