[JIRA] (JSE-49) Allow NamespaceHandler base class to sub-delegate to additional handlers

Rod Widdowson (Jira) jira at shibboleth.atlassian.net
Sat Jun 18 15:16:13 UTC 2022


Rod Widdowson ( https://shibboleth.atlassian.net/secure/ViewProfile.jspa?accountId=59fb32bbc24efb3c4ed3c977 ) *commented* on JSE-49 ( https://shibboleth.atlassian.net/browse/JSE-49?atlOrigin=eyJpIjoiNTk4NzdmNzViYTc0NDAzY2I4YTNmOTc5YTI3MWFjYTYiLCJwIjoiaiJ9 )

Re: Allow NamespaceHandler base class to sub-delegate to additional handlers ( https://shibboleth.atlassian.net/browse/JSE-49?atlOrigin=eyJpIjoiNTk4NzdmNzViYTc0NDAzY2I4YTNmOTc5YTI3MWFjYTYiLCJwIjoiaiJ9 )

So the expected precondition is that the lower layer has (and will remain to have) the real handler (i.e. the one whose class name crops up in spring.handlers )

We also expect to want to have multiple upper layer parsers (why ham string ourselves)

A secondary (but important) consideration is whether we want mandate code changes for existing parsers. I don’t like that since there are parsers out in the wild and breaking API consistency would be gratuitous (especially for plugins). This means that the init() remains in the lower layer handler which is a PITA.

Proposal

Existing handlers do what they currently do and carry on doing so.

If an existing handler wants to allow upper layer delegates it calls into the base class with a uniquifiying string (I’d suggest the urn with colons replaced by full stops).

This string has net.shibboleth.spring.handlers prepended all all classpath searched for all files of that name (i.e. META-INF\net.shibboleth.spring.handlers\urn.mace.shibboleth.2.0,resolver ) and the class loaded.

The code for these classes look just like one of our NameSpaceHandlers (i.e an init() which calls registerBeanDefinitionParser() ) but the second method actually delegates straight in to the lower layer’s map.

I’ll prototype this up and see what it looks like.

( https://shibboleth.atlassian.net/browse/JSE-49#add-comment?atlOrigin=eyJpIjoiNTk4NzdmNzViYTc0NDAzY2I4YTNmOTc5YTI3MWFjYTYiLCJwIjoiaiJ9 ) Add Comment ( https://shibboleth.atlassian.net/browse/JSE-49#add-comment?atlOrigin=eyJpIjoiNTk4NzdmNzViYTc0NDAzY2I4YTNmOTc5YTI3MWFjYTYiLCJwIjoiaiJ9 )

Get Jira notifications on your phone! Download the Jira Cloud app for Android ( https://play.google.com/store/apps/details?id=com.atlassian.android.jira.core&referrer=utm_source%3DNotificationLink%26utm_medium%3DEmail ) or iOS ( https://itunes.apple.com/app/apple-store/id1006972087?pt=696495&ct=EmailNotificationLink&mt=8 ) This message was sent by Atlassian Jira (v1001.0.0-SNAPSHOT#100201- sha1:07cea57 )
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://shibboleth.net/pipermail/commits/attachments/20220618/1dfdd8f5/attachment-0001.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: jira-generated-image-avatar-a87dda4f-1d73-4b81-8983-5dd88a8d7fb7
Type: image/png
Size: 341 bytes
Desc: not available
URL: <http://shibboleth.net/pipermail/commits/attachments/20220618/1dfdd8f5/attachment-0003.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: jira-generated-image-static-comment-icon-c0a5cb49-f2f6-4595-9cfe-ca2119b2d694
Type: image/png
Size: 1084 bytes
Desc: not available
URL: <http://shibboleth.net/pipermail/commits/attachments/20220618/1dfdd8f5/attachment-0004.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: jira-generated-image-static-footer-desktop-logo-92f5bd6c-9842-4875-91ce-9100de02eb83
Type: image/png
Size: 10805 bytes
Desc: not available
URL: <http://shibboleth.net/pipermail/commits/attachments/20220618/1dfdd8f5/attachment-0005.png>


More information about the commits mailing list