grouper-users - RE: [grouper-users] Cannot use external sql subject source
Subject: Grouper Users - Open Discussion List
List archive
- From: "Hyzer, Chris" <>
- To: Tornóci László <>, "" <>
- Subject: RE: [grouper-users] Cannot use external sql subject source
- Date: Sun, 30 Dec 2018 03:01:50 +0000
- Accept-language: en-US
- Authentication-results: spf=none (sender IP is ) ;
- Ironport-phdr: 9a23:NucBbB+A/Sem1P9uRHKM819IXTAuvvDOBiVQ1KB+0u4VIJqq85mqBkHD//Il1AaPAd2Lraocw8Pt8InYEVQa5piAtH1QOLdtbDQizfssogo7HcSeAlf6JvO5JwYzHcBFSUM3tyrjaRsdF8nxfUDdrWOv5jAOBBr/KRB1JuPoEYLOksi7ze+/94HQbglSmDaxfa55IQmrownWqsQYm5ZpJLwryhvOrHtIeuBWyn1tKFmOgRvy5dq+8YB6/ShItP0v68BPUaPhf6QlVrNYFygpM3o05MLwqxbOSxaE62YGXWUXlhpIBBXF7A3/U5zsvCb2qvZx1S+HNsDtU7s6RSqt4LtqSB/wiScIKTg58H3MisdtiK5XuQ+tqwBjz4LRZoyeKfhwcb7Hfd4CRWRPQNtfVzBPDI2/YYsADesBMvpXoYbyvFYOsQCxCRWwCO/z1jNFhHn71rA63eQ7FgHG2RQtE9wMvnXUrdT6Kr0SXfiox6TWzTXDdfJW2Szz5IPVdR0hpO2DXbJwcMvQ10YvDRjIjlSLqYP5JT+Vy/wNvHad7+pmT+6glXMoqxxorzWp28wihI7JhocPxVDF8yV02Ik1Jce/SE5med6rDoFQuzuAOItuWsMuW2BouCAmyrIYo567ejYFyIg5yxLFdfOIbpWI7gr4VOaWPDd4nm5qd6ykhxms7Eis0Oz8WdSs3FZRqSpFj8PMuWwT2BzI9MeHV+Fx/kG71jaKyQ/e7PxPL0MslafDNZIu2KI8mocWvEjeAyP6hUD7jKGZe0k45uSl7ubqbavpq5CCMoJ5jx/yPrgtl8CnHOg1PBQCU3Kf9OihzrHv41D1TbFQgvErkKTUsYjWJcoFqaO6HwNY14Mu5Au8Aji80dkVmGcIIVxZdB+ClYfmJV/OLOz9APq8nVujizRmyvbbNbP7GJrNNGLMkLL5cLZ99UFczA0zwMhH6Z9IDb8NPP3+VlbsudLAABI1Kgu0zP35B9ln0YMeRH6PDbSeMKPPt1+H+/gjI/GWZI8SpDbyNeQq5+LvjX8+n18RZ66p3YYLaHC8GfRmJEaZbWDwjdcGFGcGpgs+TOr0h12eSTNfeWy9U74h6jw+FY6qEJrPS4WjgLGOwCu3Aphba2JYBV2DD3jlcoCJV+kQZC+ROsNhlyYLVbmlS48vzxGuswr6xqJiLuXI+i0ZtZPi28Zv5+DIlBEy7iB7A96A02GVUW50mGUISyUo069ivExx0k2D3rRgg/xECdxT4OtEUgggNZ7b0ux6E879WhjYcteUU1apXM+mASoqQ9I1wt8OeFp9G868ghzZ3iqqBaMVmKKRBJwy7K3cw2b9K9xjxHnbyalyx2UhF/dIL2s9ja8304HIFYpS2xGFkLyufL8O9D7A8maKi3GJoEweUBMmFe2PUmoYe1Pbt5Hk/U7YVJevD6gqKA1M1ZTEJ6dXIJW9gk9BWe/uIpHDeG+rgE+xAwqF3LWBcNCsdmkAinbzEk8Bxkoz7GSLL0x2LSe7onmURGhrHlL+cU722ehlozWmVkIyyUeHY1A3hOn9wQIcmfHJE6Bb5bkDoip07mwsRAznjdvLF9qNoRZgd6xAYNQ7pU1Kzn/dqxcjYs67N643gFkYfkw3pE7o2xhtQqR42ckx5DJPrkJpLL6AllZIdjeWx5f1b7jcKnjg8QqHarXdnEzG3dCQvKoD9adwpg==
- Spamdiagnosticmetadata: NSPM
- Spamdiagnosticoutput: 1:99
Please review this example:
https://spaces.at.internet2.edu/display/Grouper/Penn+subject+source+JDBC2+example
And please run the subject api diagnostics under misc in the UI
Let me know if you need further help.
Thanks
Chris
-----Original Message-----
From:
<>
On Behalf Of Tornóci László
Sent: Friday, December 28, 2018 4:07 PM
To:
Subject: [grouper-users] Cannot use external sql subject source
Hi,
I am just starting to learn grouper. So I installed 2.4 with all the
latest patches using mariadb for SQL backend. The UI works fine with the
test data. I was trying to set up my own SQL subject source as described
here:
https://spaces.at.internet2.edu/display/Grouper/Penn+subject+source+JDBC2+example
gsh works with the vanilla subject.properties containing the "Example
JDBC Source Adapter". However, gsh won't start if I add this section to
subject.properties:
#########################################
## Configuration for source id: sourceSeu
## Source configName: sourceSeu
#########################################
subjectApi.source.sourceSeu.id = sourceSeu
# this is a friendly name for the source
subjectApi.source.sourceSeu.name = SE people
# type is not used all that much. Can have multiple types, comma
separate. Can be person, group, application
subjectApi.source.sourceSeu.types = person
# the adapter class implements the interface:
edu.internet2.middleware.subject.Source
subjectApi.source.sourceSeu.adapterClass =
edu.internet2.middleware.grouper.subj.GrouperJdbcSourceAdapter2
subjectApi.source.sourceSeu.param.jdbcConnectionProvider.value =
edu.internet2.middleware.subject.provider.C3p0JdbcConnectionProvider
subjectApi.source.sourceSeu.param.dbUrl.value =
jdbc:mysql://localhost:3306/grouper_testdata
# username when connecting to the database
subjectApi.source.sourceSeu.param.dbUser.value = grouperuser
# password when connecting to the database (or file with encrypted
password inside)
subjectApi.source.sourceSeu.param.dbPwd.value = password_here
# maximum number of results from a search, generally no need to get more
than 1000
subjectApi.source.sourceSeu.param.maxResults.value = 100
# the table or view to query results from. Note, could prefix with a
schema name
subjectApi.source.sourceSeu.param.dbTableOrView.value = person_source
# the column name to get the subjectId from
subjectApi.source.sourceSeu.param.subjectIdCol.value = uid
# the column name to get the name from
subjectApi.source.sourceSeu.param.nameCol.value = name
subjectApi.source.sourceSeu.param.descriptionCol.value = description
# search col where general searches take place, lower case
subjectApi.source.sourceSeu.param.lowerSearchCol.value = description_lower
# optional col if you want the search results sorted in the API (note,
UI might override)
subjectApi.source.sourceSeu.param.defaultSortCol.value = description
# you can count up from 0 to N of columns to search by identifier (which
might also include by id)
subjectApi.source.sourceSeu.param.subjectIdentifierCol0.value = sapid
# now you can count up from 0 to N of attributes for various cols. The
name is how to reference in subject.getAttribute()
subjectApi.source.sourceSeu.param.subjectAttributeCol0.value = email
The same setup works fine, if I copy the data to the database that
grouper itself uses and I set GrouperJdbcConnectionProvider instead of
GrouperJdbcSourceAdapter2 as an adapterClass.
I don't know what I'm doing wrong. Thank you for your help:
Laszlo
Here is the stack trace of gsh:
./gsh.sh
Detected Grouper directory structure 'api' (valid is api or webapp)
Using GROUPER_HOME:
/home/torlasz/src/grouper24/app/test/grouper.apiBinary-2.4.0
Using GROUPER_CONF:
/home/torlasz/src/grouper24/app/test/grouper.apiBinary-2.4.0/conf
Using JAVA: /etc/alternatives/java_sdk/bin/java
Using CLASSPATH:
/home/torlasz/src/grouper24/app/test/grouper.apiBinary-2.4.0/conf:/home/torlasz/src/grouper24/app/test/grouper.apiBinary-2.4.0/dist/lib/grouper.jar:/home/torlasz/src/grouper24/app/test/grouper.apiBinary-2.4.0/lib/grouper/*:/home/torlasz/src/grouper24/app/test/grouper.apiBinary-2.4.0/lib/custom/*:/home/torlasz/src/grouper24/app/test/grouper.apiBinary-2.4.0/lib/jdbcSamples/*:/home/torlasz/src/grouper24/app/test/grouper.apiBinary-2.4.0/lib/ant/*:/home/torlasz/src/grouper24/app/test/grouper.apiBinary-2.4.0/lib/test/*:/home/torlasz/src/grouper24/app/test/grouper.apiBinary-2.4.0/dist/lib/test/*:/home/torlasz/src/grouper24/app/test/grouper.apiBinary-2.4.0/src/resources
using MEMORY: 64m-750m
log4j:WARN No such property [maxBackupIndex] in
org.apache.log4j.DailyRollingFileAppender.
Grouper starting up: version: 2.4.0, build date: 2018/08/23 07:48:38,
env: <no label configured>
grouperPatchStatus read from:
/home/torlasz/src/grouper24/app/test/grouper.apiBinary-2.4.0/grouperPatchStatus.properties
api patches installed: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10
pspng patches installed: 0, 1
grouper.properties read from:
/home/torlasz/src/grouper24/app/test/grouper.apiBinary-2.4.0/conf/grouper.properties
Grouper current directory is:
/home/torlasz/src/grouper24/app/test/grouper.apiBinary-2.4.0/bin
log4j.properties read from:
/home/torlasz/src/grouper24/app/test/grouper.apiBinary-2.4.0/conf/log4j.properties
Grouper is logging to file:
/home/torlasz/src/grouper24/app/test/grouper.apiBinary-2.4.0/logs/grouper_error.log,
at min level WARN for package: edu.internet2.middleware.grouper, based
on log4j.properties
grouper.hibernate.properties:
/home/torlasz/src/grouper24/app/test/grouper.apiBinary-2.4.0/conf/grouper.hibernate.properties
grouper.hibernate.properties:
grouperuser@jdbc:mysql://localhost:3306/grouper_test?CharSet=utf8&useUnicode=true&characterEncoding=utf8
problem with sources
Couldnt startup grouper: Error initializing SourceManager
java.lang.RuntimeException: Error initializing SourceManager
at
edu.internet2.middleware.subject.provider.SourceManager.init(SourceManager.java:326)
at
edu.internet2.middleware.subject.provider.SourceManager.<init>(SourceManager.java:256)
at
edu.internet2.middleware.subject.provider.SourceManager.getInstance(SourceManager.java:266)
at
edu.internet2.middleware.grouper.misc.GrouperStartup.startup(GrouperStartup.java:284)
at
edu.internet2.middleware.grouper.app.gsh.GrouperShell.main(GrouperShell.java:165)
at
edu.internet2.middleware.grouper.app.gsh.GrouperShellWrapper.main(GrouperShellWrapper.java:31)
Caused by: edu.internet2.middleware.subject.SourceUnavailableException:
Unable to init subject.properties JDBC source, source: sourceSeu
at
edu.internet2.middleware.subject.provider.JDBCSourceAdapter.init(JDBCSourceAdapter.java:815)
at
edu.internet2.middleware.subject.provider.SourceManager.loadSource(SourceManager.java:351)
at
edu.internet2.middleware.subject.provider.SourceManager.parseConfig(SourceManager.java:365)
at
edu.internet2.middleware.subject.provider.SourceManager.init(SourceManager.java:323)
... 5 more
Caused by: edu.internet2.middleware.subject.SourceUnavailableException:
Error loading subject.properties JDBC driver: null, source: sourceSeu
at
edu.internet2.middleware.subject.provider.JDBCSourceAdapter.loadDriver(JDBCSourceAdapter.java:831)
at
edu.internet2.middleware.subject.provider.C3p0JdbcConnectionProvider.init(C3p0JdbcConnectionProvider.java:129)
at
edu.internet2.middleware.subject.provider.JDBCSourceAdapter2.setupDataSource(JDBCSourceAdapter2.java:649)
at
edu.internet2.middleware.subject.provider.JDBCSourceAdapter.init(JDBCSourceAdapter.java:759)
... 8 more
Caused by: java.lang.NullPointerException
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:264)
at
edu.internet2.middleware.subject.provider.JDBCSourceAdapter.loadDriver(JDBCSourceAdapter.java:828)
... 11 more
Exception in thread "main" java.lang.RuntimeException: Error
initializing SourceManager
at
edu.internet2.middleware.subject.provider.SourceManager.init(SourceManager.java:326)
at
edu.internet2.middleware.subject.provider.SourceManager.<init>(SourceManager.java:256)
at
edu.internet2.middleware.subject.provider.SourceManager.getInstance(SourceManager.java:266)
at
edu.internet2.middleware.grouper.misc.GrouperStartup.startup(GrouperStartup.java:284)
at
edu.internet2.middleware.grouper.app.gsh.GrouperShell.main(GrouperShell.java:165)
at
edu.internet2.middleware.grouper.app.gsh.GrouperShellWrapper.main(GrouperShellWrapper.java:31)
Caused by: edu.internet2.middleware.subject.SourceUnavailableException:
Unable to init subject.properties JDBC source, source: sourceSeu
at
edu.internet2.middleware.subject.provider.JDBCSourceAdapter.init(JDBCSourceAdapter.java:815)
at
edu.internet2.middleware.subject.provider.SourceManager.loadSource(SourceManager.java:351)
at
edu.internet2.middleware.subject.provider.SourceManager.parseConfig(SourceManager.java:365)
at
edu.internet2.middleware.subject.provider.SourceManager.init(SourceManager.java:323)
... 5 more
Caused by: edu.internet2.middleware.subject.SourceUnavailableException:
Error loading subject.properties JDBC driver: null, source: sourceSeu
at
edu.internet2.middleware.subject.provider.JDBCSourceAdapter.loadDriver(JDBCSourceAdapter.java:831)
at
edu.internet2.middleware.subject.provider.C3p0JdbcConnectionProvider.init(C3p0JdbcConnectionProvider.java:129)
at
edu.internet2.middleware.subject.provider.JDBCSourceAdapter2.setupDataSource(JDBCSourceAdapter2.java:649)
at
edu.internet2.middleware.subject.provider.JDBCSourceAdapter.init(JDBCSourceAdapter.java:759)
... 8 more
Caused by: java.lang.NullPointerException
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:264)
at
edu.internet2.middleware.subject.provider.JDBCSourceAdapter.loadDriver(JDBCSourceAdapter.java:828)
... 11 more
- [grouper-users] Cannot use external sql subject source, Tornóci László, 12/28/2018
- RE: [grouper-users] Cannot use external sql subject source, Hyzer, Chris, 12/30/2018
- Re: [grouper-users] Cannot use external sql subject source, Tornóci László, 12/30/2018
- RE: [grouper-users] Cannot use external sql subject source, Redman, Chad, 12/30/2018
- Re: [grouper-users] Cannot use external sql subject source, Tornóci László, 12/30/2018
- RE: [grouper-users] Cannot use external sql subject source, Redman, Chad, 12/30/2018
- Re: [grouper-users] Cannot use external sql subject source, Tornóci László, 12/30/2018
- RE: [grouper-users] Cannot use external sql subject source, Hyzer, Chris, 12/30/2018
Archive powered by MHonArc 2.6.19.