Project

General

Profile

Actions

Bug #19698

closed

First start with branding plugin fails

Added by Nicolas CHARLES over 3 years ago. Updated over 3 years ago.

Status:
Released
Priority:
N/A
Target version:
Severity:
UX impact:
User visibility:
Effort required:
Priority:
0
Name check:
To do
Fix check:
To do
Regression:

Description

When configuratio file doesn't exist yet, we create it during cache initialisation and do a cache.set.
It fails with an NPE

[2021-08-05 15:27:24+0200] INFO  org.reflections.Reflections - Reflections took 208 ms to scan 3 urls, produc
ing 26 keys and 85 values 
Fiber failed.
An unchecked error was produced.
java.lang.NullPointerException
        at com.normation.plugins.branding.BrandingConfService.$anonfun$updateConf$2(BrandingConfService.scala
:139)
        at zio.internal.FiberContext.evaluateNow(FiberContext.scala:914)
        at zio.internal.FiberContext.$anonfun$evaluateLater$1(FiberContext.scala:776)
        at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
        at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
        at java.base/java.lang.Thread.run(Thread.java:834)

Fiber:Id(1628170044576,251) was supposed to continue to:
  a future continuation at com.normation.errors$IOChainError$.chainError(ZioCommons.scala:203)
  a future continuation at com.normation.plugins.branding.BrandingConfService.reloadCacheInternal(BrandingCon
fService.scala:111)
  a future continuation at com.normation.errors$IOChainError$.chainError(ZioCommons.scala:203)
  a future continuation at zio.ZIO$.zio$ZIO$$_succeedRight(ZIO.scala:4417)
  a future continuation at com.normation.plugins.branding.BrandingConfService.cache(BrandingConfService.scala:85)
  a future continuation at zio.ZIO.run(ZIO.scala:1730)
  a future continuation at zio.ZIO.bracket_(ZIO.scala:288)
  a future continuation at zio.ZIO.run(ZIO.scala:1730)
  a future continuation at zio.ZIO.bracket_(ZIO.scala:288)
  a future continuation at com.normation.zio$ZioRuntime$.runNow(ZioCommons.scala:413)

Fiber:Id(1628170044576,251) execution trace:
  at com.normation.plugins.branding.BrandingConfService.updateConf(BrandingConfService.scala:131)
  at com.normation.errors$IOResult$.effect(ZioCommons.scala:101)
  at zio.internal.FiberContext$InterruptExit$.apply(FiberContext.scala:160)
  at zio.internal.FiberContext$InterruptExit$.apply(FiberContext.scala:153)
  at zio.ZIO$.effectSuspendTotal(ZIO.scala:2791)
  at zio.ZIO$.bracketExit(ZIO.scala:2398)
  at zio.internal.FiberContext.evaluateNow(FiberContext.scala:559)
  at zio.ZIO$.effectSuspendTotal(ZIO.scala:2791)
  at zio.ZIO.bracket_(ZIO.scala:288)
  at zio.ZIO.run(ZIO.scala:1730)
  at zio.internal.FiberContext$InterruptExit$.apply(FiberContext.scala:153)
  at zio.internal.FiberContext$InterruptExit$.apply(FiberContext.scala:160)
  at zio.internal.FiberContext$InterruptExit$.apply(FiberContext.scala:153)
  at zio.ZIO$.effectSuspendTotal(ZIO.scala:2791)
  at zio.ZIO$.bracketExit(ZIO.scala:2398)
  at zio.ZIO$.effectSuspendTotal(ZIO.scala:2791)
  at zio.ZIO.bracket_(ZIO.scala:288)
snip
  at zio.ZIO$.effectSuspendTotal(ZIO.scala:2791)
  at zio.ZIO.bracket_(ZIO.scala:288)
  at zio.ZIO.run(ZIO.scala:1730)
  at zio.internal.FiberContext$InterruptExit$.apply(FiberContext.scala:153)
  at com.normation.plugins.branding.BrandingConfService.reloadCacheInternal(BrandingConfService.scala:89)
  at zio.ZIO$.effectSuspendTotal(ZIO.scala:2791)
  at zio.ZIO.bracket_(ZIO.scala:288)
  at zio.ZIO$.lock(ZIO.scala:3533)
  at com.normation.zio$ZioRuntime$.effectBlocking(ZioCommons.scala:409)
  at zio.ZIO$.effectSuspendTotal(ZIO.scala:2791)
  at zio.ZIO.bracket_(ZIO.scala:288)
  at zio.internal.FiberContext.evaluateNow(FiberContext.scala:555)
  at com.normation.plugins.branding.BrandingConfService.cache(BrandingConfService.scala:84)
  at zio.ZRef$.make(ZRef.scala:756)
  at zio.ZIO$.effectSuspendTotal(ZIO.scala:2791)
  at zio.ZIO.bracket_(ZIO.scala:288)
  at zio.internal.FiberContext.shift(FiberContext.scala:666)
  at zio.internal.FiberContext.shift(FiberContext.scala:666)
  at zio.ZIO$.lock(ZIO.scala:3533)
  at com.normation.zio$ZioRuntime$.blocking(ZioCommons.scala:405)
  at zio.ZIO$.effectSuspendTotal(ZIO.scala:2791)
  at zio.ZIO.bracket_(ZIO.scala:288)
  at zio.internal.FiberContext.evaluateNow(FiberContext.scala:555)

restarting seems to solve the issue

Actions #1

Updated by Nicolas CHARLES over 3 years ago

  • Description updated (diff)
Actions #2

Updated by Nicolas CHARLES over 3 years ago

deleting /var/rudder/plugins/branding/configuration.json triggers the error

Actions #3

Updated by Nicolas CHARLES over 3 years ago

  • Description updated (diff)
  • Assignee set to Nicolas CHARLES
  • Target version changed from 7.0.0~beta1-2.0 to 6.1-1.9
Actions #4

Updated by Nicolas CHARLES over 3 years ago

  • Status changed from New to In progress
Actions #5

Updated by Nicolas CHARLES over 3 years ago

  • Status changed from In progress to Pending technical review
  • Assignee changed from Nicolas CHARLES to Elaad FURREEDAN
  • Pull Request set to https://github.com/Normation/rudder-plugins/pull/394
Actions #6

Updated by Nicolas CHARLES over 3 years ago

  • Status changed from Pending technical review to Pending release
Actions #7

Updated by Vincent MEMBRÉ over 3 years ago

  • Target version changed from 6.1-1.9 to 6.2-1.11
Actions #8

Updated by Vincent MEMBRÉ over 3 years ago

  • Status changed from Pending release to Released

This bug has been fixed in Rudder 6.2-1.11 which was released today.

Actions

Also available in: Atom PDF