Quick update... I worked around this for now by implementing a dummy
resource lookup class and deploying to the server.

On Tue, 27 Feb 2018 at 13:08 Nigel Jones <ni...@cherrybyte.me.uk> wrote:

> Having tried this against master (for about a week ago) I am still getting
> the same issue deploying the plugin on a base ranger install (it works ok
> in HDP)
>
> The exception trace in the log included as an attachment
>
> My ews/lib directory does include
> ranger-plugins-common-1.0.0-SNAPSHOT.jar
>
> and is readable by the user ranger is started with
>
> It is also available within ews/webapp/WEB-INF/lib
>
> Currently my implClass is blank
>
> Any ideas?
>
> On Sat, 3 Feb 2018 at 00:37 Ramesh Mani <rm...@hortonworks.com> wrote:
>
>> Nigel,
>>
>> Could you please provide the exception stack that is printed along with
>> error message you are showing. Please check in xa_portal.log ( Ranger
>> log).
>>
>> Also check in Ranger class path ranger-plugins-common*jar is there. Check
>> in {install.dir}/ranger-admin/ews/lib and
>> {install.dir}/ranger-admin/ews/webapp/WEB-INF/lib and it has the necessary
>> permission for the process user who start ranger admin.
>>
>> As you notice it should have used the base implementation when you leave
>> implClass blank / or not in the service def.
>>
>> Regards,
>> Ramesh
>>
>>
>> On 2/2/18, 6:24 AM, "Nigel Jones" <nigel.l.jo...@gmail.com> wrote:
>>
>> >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 created.
>> >
>> >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:
>> >{
>> >  "id":99,
>> >  "name": "gaian",
>> >  "implClass": "org.apache.ranger.services.gaiandb.RangerServiceGaian",
>> >  "label": "Gaian",
>> >  "description": "Gaian",
>> >  "options": {
>> >    "enableDenyAndExceptionsInPolicies": "true"
>> >  },
>> >    "guid": "86d10748-e4fc-442b-8991-f6a727054ece",
>> >
>> >  "resources": [
>> >The full version can be found in
>> >https://issues.apache.org/jira/browse/RANGER-1699
>> ><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 tree
>> >
>> >If it seems like a bug (rather than a newbie error or specific to hdp)
>> >let me know and I¹ll open a jira!
>> >
>> >Many thanks
>> >Nigel.
>> >
>> >
>> >
>>
>>

Reply via email to