java.lang.IllegalStateException

If you like a tip written by other Samebug users, mark is as helpful! Marks help our algorithm provide you better solutions and also help other users.
tip

Check if there is no nexus running. If not, delete sonatype-work/nexus/nexus.lock .


rp

You have a different solution? A short tip here would help you and many other users who saw this issue last week.

  • Unpack and start Nexus * Create an internal user * Delete the internal user * Exception will appear in log: {code} 2014-09-11 18:32:55,611+0100 ERROR [qtp357251045-230] admin com.google.common.eventbus.EventBus.default - Could not dispatch event: com.sonatype.nexus.usertoken.plugin.internal.UserTokenEventInspector@41df9bb6 to public void com.sonatype.nexus.usertoken.plugin.internal.UserTokenEventInspector.inspect(org.sonatype.security.events.UserPrincipalsExpired) java.lang.IllegalStateException: User-token feature is not enabled at com.google.common.base.Preconditions.checkState(Preconditions.java:176) [com.google.guava:16.0.1] at com.sonatype.nexus.usertoken.plugin.internal.UserTokenServiceImpl.ensureEnabled(UserTokenServiceImpl.java:172) [na:na] at com.sonatype.nexus.usertoken.plugin.internal.UserTokenServiceImpl.remove(UserTokenServiceImpl.java:362) [na:na] at com.sonatype.nexus.usertoken.plugin.internal.UserTokenEventInspector.handle(UserTokenEventInspector.java:52) [na:na] at com.sonatype.nexus.usertoken.plugin.internal.UserTokenEventInspector.inspect(UserTokenEventInspector.java:46) [na:na] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [na:1.7.0_51] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) [na:1.7.0_51] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) [na:1.7.0_51] at java.lang.reflect.Method.invoke(Method.java:606) [na:1.7.0_51] at com.google.common.eventbus.EventSubscriber.handleEvent(EventSubscriber.java:74) [com.google.guava:16.0.1] at com.google.common.eventbus.EventBus.dispatch(EventBus.java:322) [com.google.guava:16.0.1] at com.google.common.eventbus.DefaultGuavaEventBus.dispatch(DefaultGuavaEventBus.java:41) [com.google.guava:16.0.1] at com.google.common.eventbus.ReentrantGuavaEventBus.dispatchQueuedEvents(ReentrantGuavaEventBus.java:56) [com.google.guava:16.0.1] at com.google.common.eventbus.EventBus.post(EventBus.java:275) [com.google.guava:16.0.1] at org.sonatype.sisu.goodies.eventbus.internal.DefaultEventBus.post(DefaultEventBus.java:73) [com.google.guava:16.0.1] at org.sonatype.security.DefaultSecuritySystem.deleteUser(DefaultSecuritySystem.java:418) [org.sonatype.nexus.core:3.0.0.SNAPSHOT] at org.sonatype.security.SecuritySystem$deleteUser.call(Unknown Source) [3.0.0-SNAPSHOT:3.0.0-SNAPSHOT] at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:45) [groovy-all:2.1.5] at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:108) [groovy-all:2.1.5] at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:120) [groovy-all:2.1.5] at org.sonatype.nexus.coreui.UserComponent.delete_(UserComponent.groovy:292) [org.sonatype.nexus.plugins.nexus-coreui-plugin:3.0.0.SNAPSHOT] {code}
    via by Stuart McCulloch,
  • GitHub comment 82#263121005
    via GitHub by itinance
    ,
    • java.lang.IllegalStateException: User-token feature is not enabled at com.google.common.base.Preconditions.checkState(Preconditions.java:176)[com.google.guava:16.0.1] at com.sonatype.nexus.usertoken.plugin.internal.UserTokenServiceImpl.ensureEnabled(UserTokenServiceImpl.java:172)[na:na] at com.sonatype.nexus.usertoken.plugin.internal.UserTokenServiceImpl.remove(UserTokenServiceImpl.java:362)[na:na] at com.sonatype.nexus.usertoken.plugin.internal.UserTokenEventInspector.handle(UserTokenEventInspector.java:52)[na:na] at com.sonatype.nexus.usertoken.plugin.internal.UserTokenEventInspector.inspect(UserTokenEventInspector.java:46)[na:na] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)[na:1.7.0_51] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)[na:1.7.0_51] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)[na:1.7.0_51] at java.lang.reflect.Method.invoke(Method.java:606)[na:1.7.0_51] at com.google.common.eventbus.EventSubscriber.handleEvent(EventSubscriber.java:74)[com.google.guava:16.0.1] at com.google.common.eventbus.EventBus.dispatch(EventBus.java:322)[com.google.guava:16.0.1] at com.google.common.eventbus.DefaultGuavaEventBus.dispatch(DefaultGuavaEventBus.java:41)[com.google.guava:16.0.1] at com.google.common.eventbus.ReentrantGuavaEventBus.dispatchQueuedEvents(ReentrantGuavaEventBus.java:56)[com.google.guava:16.0.1] at com.google.common.eventbus.EventBus.post(EventBus.java:275)[com.google.guava:16.0.1] at org.sonatype.sisu.goodies.eventbus.internal.DefaultEventBus.post(DefaultEventBus.java:73)[com.google.guava:16.0.1] at org.sonatype.security.DefaultSecuritySystem.deleteUser(DefaultSecuritySystem.java:418)[org.sonatype.nexus.core:3.0.0.SNAPSHOT] at org.sonatype.security.SecuritySystem$deleteUser.call(Unknown Source)[3.0.0-SNAPSHOT:3.0.0-SNAPSHOT] at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:45)[groovy-all:2.1.5] at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:108)[groovy-all:2.1.5] at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:120)[groovy-all:2.1.5] at org.sonatype.nexus.coreui.UserComponent.delete_(UserComponent.groovy:292)[org.sonatype.nexus.plugins.nexus-coreui-plugin:3.0.0.SNAPSHOT]

    Users with the same issue

    nasimk
    6 times, last one,
    Unknown visitor1 times, last one,
    Unknown visitor1 times, last one,
    Unknown visitor1 times, last one,
    Unknown visitor1 times, last one,
    84 more bugmates