Class SimonContributionRecorderConnector

All Implemented Interfaces:
AuditLoggingComponent, SecureConnectorExtension, VirtualConnectorExtension, IntegrationConnector, OpenMetadataEventListener

public class SimonContributionRecorderConnector extends IntegrationConnectorBase implements OpenMetadataEventListener
SimonContributionRecorderConnector recognizes the contributions that people make to the open metadata ecosystem, in recognition of Herbert A. Simon (1916-2001), whose study of bounded rationality revolutionized how we understand human decision-making. It listens to the open metadata events and awards a karma point to the user responsible for each change - the user that last updated the element, relationship or classification, or the user that created it if it has not been updated. The total is kept in the karmaPoints property of the ContributionRecord attached to the user's actor profile. Only users with an actor profile are awarded karma points.

The karma points are gathered in memory as the events arrive and written on each refresh, so a busy user costs one read and one update per refresh rather than one per change. Karma points that could not be written are kept and tried again on the next refresh. The unique identifier of each user's contribution record is cached so that the actor profile is only looked up the first time.

The users whose userIds match one of the patterns in the ignoredUserIdPatterns configuration property are not awarded karma points. The core content pack sets them to match the non-personal accounts (ending in npa) and the governance engines (ending in engine), so only the contributions of people are recognized. The patterns are used rather than a list of userIds because the servers' userIds differ in each environment. The connector's own userId is always ignored, whether a pattern matches it or not - each update it makes to a contribution record produces an event of its own, and otherwise it would award itself a karma point for every one, without end.