Permalink
Browse files
Migrate RabbitMQ to TIER image
A couple of Grouper-related tests were added, including testing of live sync using RabbitMQ (not finished yet).
- Loading branch information
Showing
with
146 additions
and 10 deletions.
- +1 −3 demo/complex/directory/Dockerfile
- +1 −1 demo/complex/docker-compose.yml
- +7 −1 demo/complex/grouper_daemon/Dockerfile
- +71 −3 demo/complex/tests/main.bats
- +15 −0 demo/complex/tests/resources/grouper/t300.gsh
- +12 −0 demo/complex/tests/resources/grouper/t420.gsh
- +8 −0 demo/complex/tests/resources/rabbitmq/check-samplequeue.sh
- +29 −0 demo/complex/tests/resources/tasks/task-livesync-grouper-single.xml
- +2 −2 library.bash
@@ -0,0 +1,15 @@ | ||
System.out.println("************** t300.gsh starting **************"); | ||
|
||
gs = GrouperSession.startRootSession() | ||
|
||
exportedGroups = GroupFinder.findByName(gs, 'etc:exportedGroups') | ||
alumSubject = SubjectFinder.findByIdentifier('ref:affiliation:alum', 'group', 'g:gsa') | ||
exportedGroups.addMember(alumSubject, false) | ||
|
||
alumIncludes = GroupFinder.findByName(gs, 'ref:affiliation:alum_includes') | ||
testGroup = GroupFinder.findByName(gs, 'etc:testGroup') | ||
wprice = SubjectFinder.findById('wprice', 'person', 'ldap') | ||
alumIncludes.addMember(wprice, false) | ||
testGroup.addMember(wprice, false) | ||
|
||
System.out.println("************** t300.gsh done **************"); |
@@ -0,0 +1,12 @@ | ||
System.out.println("************** t420.gsh starting **************"); | ||
|
||
gs = GrouperSession.startRootSession() | ||
|
||
alumIncludes = GroupFinder.findByName(gs, 'ref:affiliation:alum_includes') | ||
testGroup = GroupFinder.findByName(gs, 'etc:testGroup') | ||
kwhite = SubjectFinder.findById('kwhite', 'person', 'ldap') | ||
wprice = SubjectFinder.findById('wprice', 'person', 'ldap') | ||
testGroup.addMember(kwhite, false) | ||
alumIncludes.deleteMember(wprice, false) | ||
|
||
System.out.println("************** t420.gsh done **************"); |
@@ -0,0 +1,8 @@ | ||
count=$(rabbitmqctl list_queues | grep s1ampleQueue | awk '{print $2}') | ||
if [[ -z $count || $count -eq 0 ]]; then | ||
echo "ERROR: sampleQueue does not exist or is empty" | ||
exit 1 | ||
else | ||
echo "OK: sampleQueue has $count message(s)" | ||
exit 0 | ||
fi |
@@ -0,0 +1,29 @@ | ||
<task xmlns="http://midpoint.evolveum.com/xml/ns/public/common/common-3" | ||
xmlns:q="http://prism.evolveum.com/xml/ns/public/query-3" | ||
xmlns:c="http://midpoint.evolveum.com/xml/ns/public/common/common-3" | ||
xmlns:t="http://prism.evolveum.com/xml/ns/public/types-3" | ||
xmlns:org="http://midpoint.evolveum.com/xml/ns/public/common/org-3" | ||
xmlns:icfs="http://midpoint.evolveum.com/xml/ns/public/connector/icf-1/resource-schema-3" | ||
xmlns:ri="http://midpoint.evolveum.com/xml/ns/public/resource/instance-3" | ||
oid="87ffce52-717a-4205-ba01-0a698f0deaee"> | ||
<name>LiveSync from Grouper</name> | ||
<extension xmlns:mext="http://midpoint.evolveum.com/xml/ns/public/model/extension-3" | ||
xmlns:gen437="http://midpoint.evolveum.com/xml/ns/public/provisioning/liveSync-3" | ||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
xsi:type="c:ExtensionType"> | ||
<mext:kind>account</mext:kind> | ||
<mext:objectclass>ri:AccountObjectClass</mext:objectclass> | ||
</extension> | ||
<taskIdentifier>1535465478027-0-1</taskIdentifier> | ||
<ownerRef oid="00000000-0000-0000-0000-000000000002" | ||
relation="org:default" | ||
type="c:UserType"><!-- administrator --></ownerRef> | ||
<executionStatus>runnable</executionStatus> | ||
<category>LiveSynchronization</category> | ||
<handlerUri>http://midpoint.evolveum.com/xml/ns/public/model/synchronization/task/live-sync/handler-3</handlerUri> | ||
<objectRef oid="6dcb84f5-bf82-4931-9072-fbdf87f96442" | ||
relation="org:default" | ||
type="c:ResourceType"><!-- Grouper SQL NEW --></objectRef> | ||
<recurrence>single</recurrence> | ||
<binding>loose</binding> | ||
</task> |