criteo / marathon-capabilities-plugin

A plugin to allow marathon to leverage mesos capabilities isolator
Apache License 2.0
2 stars 3 forks source link

Provider com.criteo.marathon.CapabilitiesPlugin could not be instantiated #8

Open awltux opened 4 years ago

awltux commented 4 years ago

Hi,

Any idea why the plugin can't be loaded? FYI: First time building a plugin for Marathon and relatively new to Mesos/Marathon; I've had 'Jenkins/Jenkins' running as Marathon container, but I think I need extra capabilities to run 'mesosphere/jenkins-dind'. After installing his capabilities plugin, I can no longer deploy 'jenkins/jenkins'; though reading the Marathon plugin docs, I think this is because of this exception during plugin loading.

The jar file exists @ /opt/marathon/plugin_dir/marathon-capabilities-plugin_2.12-1.0.jar Using the plugin config.json from GitHub:

[devops@dvolsmesos004 ~]$ cat /opt/marathon/plugin_conf.json
{
  "plugins": {
    "capabilities": {
      "plugin": "mesosphere.marathon.plugin.task.RunSpecTaskProcessor",
      "implementation": "com.criteo.marathon.CapabilitiesPlugin"
    }
  }
}

Versions used:

Exception in /var/log/messages:

Jul 30 13:45:48 dvolsmesos006 marathon[232517]: [2020-07-30 13:45:48,490] INFO  Loading plugins implementing 'mesosphere.marathon.plugin.task.RunSpecTaskProcessor' from these urls: [file:/opt/marathon/plugin_dir/marathon-capabilities-plugin_2.12-1.0.jar] (mesosphere.marathon.core.plugin.impl.PluginManagerImpl:marathon-akka.actor.default-dispatcher-22)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: [2020-07-30 13:45:48,492] ERROR mesosphere.marathon.plugin.task.RunSpecTaskProcessor: Provider com.criteo.marathon.CapabilitiesPlugin could not be instantiated (akka.actor.OneForOneStrategy:marathon-akka.actor.default-dispatcher-22)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: java.util.ServiceConfigurationError: mesosphere.marathon.plugin.task.RunSpecTaskProcessor: Provider com.criteo.marathon.CapabilitiesPlugin could not be instantiated
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at java.util.ServiceLoader.fail(ServiceLoader.java:232)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at java.util.ServiceLoader.access$100(ServiceLoader.java:185)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at java.util.ServiceLoader$LazyIterator.nextService(ServiceLoader.java:384)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at java.util.ServiceLoader$LazyIterator.next(ServiceLoader.java:404)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at java.util.ServiceLoader$1.next(ServiceLoader.java:480)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at mesosphere.marathon.stream.ScalaConversions$RichIterator.next(ScalaConversions.scala:26)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at scala.collection.Iterator$class.toStream(Iterator.scala:1322)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at mesosphere.marathon.stream.ScalaConversions$RichIterator.toStream(ScalaConversions.scala:23)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at scala.collection.TraversableOnce$class.toSeq(TraversableOnce.scala:298)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at mesosphere.marathon.stream.ScalaConversions$RichIterator.toSeq(ScalaConversions.scala:23)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at mesosphere.marathon.core.plugin.impl.PluginManagerImpl.load(PluginManagerImpl.scala:45)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at mesosphere.marathon.core.plugin.impl.PluginManagerImpl.mesosphere$marathon$core$plugin$impl$PluginManagerImpl$$loadAndAdd$1(PluginManagerImpl.scala:64)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at mesosphere.marathon.core.plugin.impl.PluginManagerImpl$$anonfun$plugins$3.apply(PluginManagerImpl.scala:72)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at mesosphere.marathon.core.plugin.impl.PluginManagerImpl$$anonfun$plugins$3.apply(PluginManagerImpl.scala:72)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at scala.Option.getOrElse(Option.scala:121)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at mesosphere.marathon.core.plugin.impl.PluginManagerImpl.plugins(PluginManagerImpl.scala:72)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at mesosphere.marathon.core.plugin.impl.PluginManagerImpl.plugins(PluginManagerImpl.scala:21)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at mesosphere.marathon.core.launcher.impl.InstanceOpFactoryImpl.runSpecTaskProc$lzycompute(InstanceOpFactoryImpl.scala:42)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at mesosphere.marathon.core.launcher.impl.InstanceOpFactoryImpl.runSpecTaskProc(InstanceOpFactoryImpl.scala:41)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at mesosphere.marathon.core.launcher.impl.InstanceOpFactoryImpl.inferNormalTaskOp(InstanceOpFactoryImpl.scala:93)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at mesosphere.marathon.core.launcher.impl.InstanceOpFactoryImpl.matchOfferRequest(InstanceOpFactoryImpl.scala:52)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at mesosphere.marathon.core.launchqueue.impl.TaskLauncherActor$$anonfun$receiveProcessOffers$1.applyOrElse(TaskLauncherActor.scala:365)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at scala.PartialFunction$OrElse.applyOrElse(PartialFunction.scala:170)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at scala.PartialFunction$OrElse.applyOrElse(PartialFunction.scala:171)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at scala.PartialFunction$OrElse.applyOrElse(PartialFunction.scala:171)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at scala.PartialFunction$OrElse.applyOrElse(PartialFunction.scala:171)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at scala.PartialFunction$OrElse.applyOrElse(PartialFunction.scala:171)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at scala.PartialFunction$OrElse.applyOrElse(PartialFunction.scala:171)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at scala.PartialFunction$OrElse.applyOrElse(PartialFunction.scala:171)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at akka.actor.Actor$class.aroundReceive(Actor.scala:497)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at mesosphere.marathon.core.launchqueue.impl.TaskLauncherActor.aroundReceive(TaskLauncherActor.scala:76)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at akka.actor.ActorCell.receiveMessage(ActorCell.scala:526)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at akka.actor.ActorCell.invoke(ActorCell.scala:495)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at akka.dispatch.Mailbox.processMailbox(Mailbox.scala:257)
Jul 30 13:45:48 dvolsmesos006 marathon[232517]: #011at akka.dispatch.Mailbox.run(Mailbox.scala:224)
kamaradclimber commented 4 years ago

Nothing obvious at least. Are you sure you built the plugin against recent marathon version?

awltux commented 4 years ago

Thanks for the reply. On holiday for the week. Will check when I return. I assume the version of marathon is in the build script somewhere? I'm sure I'll find it when I look at it.

On Thu, 30 Jul 2020, 14:51 Grégoire Seux, notifications@github.com wrote:

Nothing obvious at least. Are you sure you built the plugin against recent marathon version?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/criteo/marathon-capabilities-plugin/issues/8#issuecomment-666377322, or unsubscribe https://github.com/notifications/unsubscribe-auth/AARGZPLD6R35HZIG4VSBN4TR6F3GHANCNFSM4PNXI24Q .