This repository was archived by the owner on Aug 28, 2024. It is now read-only.
Commit 11a0148 1 parent 45f5d76 commit 11a0148 Copy full SHA for 11a0148
File tree 1 file changed +33
-0
lines changed
azure-spring-boot-tests/azure-spring-boot-test-application/src/main/java/com/microsoft/azure/config
1 file changed +33
-0
lines changed Original file line number Diff line number Diff line change
1
+ /**
2
+ * Copyright (c) Microsoft Corporation. All rights reserved.
3
+ * Licensed under the MIT License. See LICENSE in the project root for
4
+ * license information.
5
+ */
6
+ package com .microsoft .azure .keyvault .spring ;
7
+
8
+ import org .springframework .boot .SpringApplication ;
9
+ import org .springframework .boot .context .config .ConfigFileApplicationListener ;
10
+ import org .springframework .boot .env .EnvironmentPostProcessor ;
11
+ import org .springframework .core .Ordered ;
12
+ import org .springframework .core .env .ConfigurableEnvironment ;
13
+
14
+ public class IncreaseStartupTimeHelper implements EnvironmentPostProcessor , Ordered {
15
+
16
+ public static final int DEFAULT_ORDER = ConfigFileApplicationListener .DEFAULT_ORDER ;
17
+ private int order = DEFAULT_ORDER ;
18
+
19
+ @ Override
20
+ public void postProcessEnvironment (ConfigurableEnvironment environment , SpringApplication application ) {
21
+ try {
22
+ Thread .sleep (100_000 );
23
+ } catch (InterruptedException e ) {
24
+ e .printStackTrace ();
25
+ }
26
+ }
27
+
28
+ @ Override
29
+ public int getOrder () {
30
+ return order ;
31
+ }
32
+
33
+ }
You can’t perform that action at this time.
0 commit comments