We're currently writing a Ranger plugin for an open source virtual database
driver known as ‘GaianDB’.
We have the basics of a plugin working, but today a colleague tried to setup
our plugin, and on their ranger install they could not create an instance of
our ranger service, hitting the error
"Gaian failed to find service class
org.apache.ranger.services.gaiandb.RangerServiceGaian. Resource lookup will not
be available. Please make sure plugin jar is in the correct place.”
I had expected this to be a warning (fair enough), but it actually prevents the
UI from saving the service instance, and so Gaian related policies cannot be
They got this on I think a) an old 0.6.x build, and 0.7.1.
Meanwhile I had been using a HDP 2.6.3 setup, which comes with 0.7.0 and with
the same service definition did NOT of course hit this error.
We haven’t actually deployed any plugin code to the ranger server (yet) since
we have not implemented the resource lookup capability. We had though specified
an implClass in the servicedef. It’s a later task :-)
Looking at the ranger code in ServiceMgr.java it seems as if an empty string
should cause ranger to use a default class. We tried this, as well as
specifying the org.apache.ranger.plugin.service.RangerDefaultService class, but
had the same error in both cases. I was though looking at code in master and
see there have been a few changes
Any suggestions as to how to persuade 0.7.0 to load the servicedef (other than
implement the class required, albeit a no-op one…?), or an explanation as to
why we might see different behaviour?
I’m setting up a ranger install off master to debug/check latest code….
For info the servicedef begins:
The full version can be found in
<https://issues.apache.org/jira/browse/RANGER-1699> - see the latest
attachment. Not as a patch as currently getting things working in a diff. Build
If it seems like a bug (rather than a newbie error or specific to hdp) let me
know and I’ll open a jira!