We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e2c5455 commit a2babf6Copy full SHA for a2babf6
dp-inntekt-api/src/main/kotlin/no/nav/dagpenger/inntekt/Application.kt
@@ -129,10 +129,18 @@ fun main() {
129
)
130
}
131
132
- val uttrekksjobb = Uttrekksjobb(dataSource, inntektskomponentHttpClient)
133
- launch {
134
- delay(10000L)
135
- uttrekksjobb.hentInntekterOgSjekk()
+ Uttrekksjobb(dataSource, inntektskomponentHttpClient).also {
+ fixedRateTimer(
+ name = "uttrekk",
+ initialDelay = TimeUnit.MINUTES.toMillis(1),
136
+ period = TimeUnit.HOURS.toMillis(1),
137
+ action = {
138
+ LOGGER.info { "UTTREKK" }
139
+ runBlocking { it.hentInntekterOgSjekk() }
140
141
+ }
142
+ )
143
144
+
145
146
0 commit comments