Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change event action service to context event service #8087

Merged
merged 2 commits into from
Mar 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ List<ToDoElement> getActionsForActionTarget(String userId,
UserNotAuthorizedException;

/**
* Retrieve the "To Dos" that are chained off of an owner element.
* Retrieve the "To Dos" that are chained off of a sponsor's element.
*
* @param userId calling user
* @param elementGUID unique identifier of the element to start with
Expand All @@ -174,13 +174,13 @@ List<ToDoElement> getActionsForActionTarget(String userId,
* @throws PropertyServerException the server is not available
* @throws UserNotAuthorizedException the calling user is not authorized to issue the call
*/
List<ToDoElement> getActionsForOwner(String userId,
String elementGUID,
ToDoStatus toDoStatus,
int startFrom,
int pageSize) throws InvalidParameterException,
PropertyServerException,
UserNotAuthorizedException;
List<ToDoElement> getActionsForSponsor(String userId,
String elementGUID,
ToDoStatus toDoStatus,
int startFrom,
int pageSize) throws InvalidParameterException,
PropertyServerException,
UserNotAuthorizedException;


/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,7 @@ public String createToDo(String userId,
openMetadataStoreClient.createRelatedElementsInStore(userId,
null,
null,
OpenMetadataType.ACTIONS_RELATIONSHIP_TYPE_NAME,
OpenMetadataType.ACTION_SPONSOR_RELATIONSHIP_TYPE_NAME,
actionOwnerGUID,
toDoGUID,
false,
Expand Down Expand Up @@ -496,7 +496,7 @@ public List<ToDoElement> getActionsForActionTarget(String userId,


/**
* Retrieve the "To Dos" that are chained off of an owner element.
* Retrieve the "To Dos" that are chained off of a sponsor's element.
*
* @param userId calling user
* @param elementGUID unique identifier of the element to start with
Expand All @@ -511,15 +511,15 @@ public List<ToDoElement> getActionsForActionTarget(String userId,
* @throws UserNotAuthorizedException the calling user is not authorized to issue the call
*/
@Override
public List<ToDoElement> getActionsForOwner(String userId,
String elementGUID,
ToDoStatus toDoStatus,
int startFrom,
int pageSize) throws InvalidParameterException,
PropertyServerException,
UserNotAuthorizedException
public List<ToDoElement> getActionsForSponsor(String userId,
String elementGUID,
ToDoStatus toDoStatus,
int startFrom,
int pageSize) throws InvalidParameterException,
PropertyServerException,
UserNotAuthorizedException
{
final String methodName = "getActionsForOwner";
final String methodName = "getActionsForSponsor";
final String guidParameterName = "elementGUID";

invalidParameterHandler.validateUserId(userId, methodName);
Expand All @@ -528,7 +528,7 @@ public List<ToDoElement> getActionsForOwner(String userId,
List<RelatedMetadataElement> relatedMetadataElements = openMetadataStoreClient.getRelatedMetadataElements(userId,
elementGUID,
1,
OpenMetadataType.ACTIONS_RELATIONSHIP_TYPE_NAME,
OpenMetadataType.ACTION_SPONSOR_RELATIONSHIP_TYPE_NAME,
false,
false,
new Date(),
Expand Down Expand Up @@ -594,13 +594,13 @@ public List<ToDoElement> getAssignedActions(String userId,
* @throws UserNotAuthorizedException the calling user is not authorized to issue the call
*/
@Override
public List<ToDoElement> findToDos(String userId,
String searchString,
public List<ToDoElement> findToDos(String userId,
String searchString,
ToDoStatus toDoStatus,
int startFrom,
int pageSize) throws InvalidParameterException,
PropertyServerException,
UserNotAuthorizedException
int startFrom,
int pageSize) throws InvalidParameterException,
PropertyServerException,
UserNotAuthorizedException
{
final String methodName = "findToDos";
final String searchStringParameterName = "searchString";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,18 +68,18 @@ public enum EngineServiceDescription
/**
* Executes requested event action services to monitor, assess and maintain context events.
*/
EVENT_ACTION_OMES(403,
ComponentDevelopmentStatus.IN_DEVELOPMENT,
"Event Action",
"Event Action OMES",
"event-action",
"Executes requested event action services to monitor, assess and maintain context events.",
"https://egeria-project.org/services/omes/event-action/overview/",
AccessServiceDescription.GOVERNANCE_ENGINE_OMAS.getAccessServiceFullName(),
DeployedImplementationType.EVENT_ACTION_ENGINE.getAssociatedTypeName(),
DeployedImplementationType.EVENT_ACTION_SERVICE_CONNECTOR.getAssociatedTypeName(),
DeployedImplementationType.EVENT_ACTION_ENGINE.getDeployedImplementationType(),
DeployedImplementationType.EVENT_ACTION_SERVICE_CONNECTOR.getDeployedImplementationType()),
CONTEXT_EVENT_OMES(403,
ComponentDevelopmentStatus.IN_DEVELOPMENT,
"Context Event",
"Context Event OMES",
"context-event",
"Executes requested context event services to monitor, assess and maintain context events.",
"https://egeria-project.org/services/omes/context-event/overview/",
AccessServiceDescription.GOVERNANCE_ENGINE_OMAS.getAccessServiceFullName(),
DeployedImplementationType.CONTEXT_EVENT_ENGINE.getAssociatedTypeName(),
DeployedImplementationType.CONTEXT_EVENT_SERVICE_CONNECTOR.getAssociatedTypeName(),
DeployedImplementationType.CONTEXT_EVENT_ENGINE.getDeployedImplementationType(),
DeployedImplementationType.CONTEXT_EVENT_SERVICE_CONNECTOR.getDeployedImplementationType()),


/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -339,7 +339,7 @@ private void setServerDescription(OMAGServerConfig serverConfig,
configAuditTrail = new ArrayList<>();
}

if (description != null && (description.length() == 0))
if ((description != null) && (description.isEmpty()))
{
description = null;
}
Expand Down
2 changes: 1 addition & 1 deletion open-metadata-implementation/frameworks/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ about the data that can be stored in an open metadata repository.
(called survey action services) that survey and extract characteristics
about the real-world resources and stores them in an open metadata repository.

* **[Event Action Framework (EAF)](event-action-framework)** provides the interfaces and base implementations for components
* **[Event Action Framework (EAF)](context-event-framework)** provides the interfaces and base implementations for components
(called event action services) that manage context events and time-based services.


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@

![InDevelopment](../../../images/egeria-content-status-in-development.png#pagewidth)

# Event Action Framework (EAF)
# Context Event Framework (EAF)

The Event Action Framework (EAF) enables the creation of governance services that manage events.
The Context Event Framework (CEF) enables the creation of governance services that manage significant events.
These events may be instantaneous, or cover an extended time period. An event may be in the past, occurring now, or is something in the future that is being planned for.

Events are described in open metadata using [context events](https://egeria-project.org/concepts/context-event). The context event provides an anchor point for information and activity around the event. Services that use the event action framework are:
Expand All @@ -15,7 +15,7 @@ Events are described in open metadata using [context events](https://egeria-proj
* Sending and receiving notifications related to an event.
* Initiating other actions at specific moments in time that related to the event.

More information is available on Egeria's [documentation site](https://egeria-project.org/frameworks/eaf/overview/).
More information is available on Egeria's [documentation site](https://egeria-project.org/frameworks/cef/overview/).


----
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -318,20 +318,20 @@ public enum OpenMetadataType
/**
* A governance engine for managing context events and associated actions.
*/
EVENT_ACTION_ENGINE("796f6493-3c3e-4091-8b21-46ea4e54d011",
"EventActionEngine",
OpenMetadataWikiPages.MODEL_0461_GOVERNANCE_ENGINES,
"cebad26a-08f6-40b7-a0e0-4f9b1b439992",
"A governance engine for managing context events and associated actions."),
CONTEXT_EVENT_ENGINE("796f6493-3c3e-4091-8b21-46ea4e54d011",
"ContextEventEngine",
OpenMetadataWikiPages.MODEL_0461_GOVERNANCE_ENGINES,
"cebad26a-08f6-40b7-a0e0-4f9b1b439992",
"A governance engine for managing context events and associated actions."),

/**
* A governance service for managing context events and associated actions.
*/
EVENT_ACTION_SERVICE("464bb4d8-f865-4b9d-a06e-7ed19518ff13",
"EventActionService",
OpenMetadataWikiPages.MODEL_0461_GOVERNANCE_ENGINES,
"6e030483-39ff-4b1b-bd50-1faa64e44690",
"A governance service for managing context events and associated actions."),
CONTEXT_EVENT_SERVICE("464bb4d8-f865-4b9d-a06e-7ed19518ff13",
"ContextEventService",
OpenMetadataWikiPages.MODEL_0461_GOVERNANCE_ENGINES,
"6e030483-39ff-4b1b-bd50-1faa64e44690",
"A governance service for managing context events and associated actions."),

/**
* A governance engine for managing the surveying of real-world resources and capturing the results in survey report attached to the associated asset.
Expand Down Expand Up @@ -2119,7 +2119,7 @@ public enum OpenMetadataType
/**
* Actions - End1 = originator - Referenceable; End 2 = To Do
*/
public static final String ACTIONS_RELATIONSHIP_TYPE_NAME = "Actions"; /* from Area 1 */
public static final String ACTION_SPONSOR_RELATIONSHIP_TYPE_NAME = "ActionSponsor"; /* from Area 1 */

/**
* 207e2594-e3e4-4be8-a12c-4c401656e241
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -351,25 +351,25 @@ public enum DeployedImplementationType


/**
* Event Action Service - A connector that coordinates governance of context events.
* Context Event Service - A connector that coordinates governance of context events.
*/
EVENT_ACTION_SERVICE_CONNECTOR("Event Action Service",
DeployedImplementationType.GOVERNANCE_SERVICE,
OpenMetadataType.EVENT_ACTION_SERVICE.typeName,
null,
"A connector that coordinates governance of context events.",
"https://egeria-project.org/concepts/event-action-service/"),
CONTEXT_EVENT_SERVICE_CONNECTOR("Context Event Service",
DeployedImplementationType.GOVERNANCE_SERVICE,
OpenMetadataType.CONTEXT_EVENT_SERVICE.typeName,
null,
"A connector that coordinates governance of context events.",
"https://egeria-project.org/concepts/context-event-service/"),


/**
* Event Action Engine - A governance engine that runs event action services.
* Context Event Engine - A governance engine that runs context event services.
*/
EVENT_ACTION_ENGINE("Event Action Engine",
DeployedImplementationType.GOVERNANCE_ENGINE,
OpenMetadataType.EVENT_ACTION_ENGINE.typeName,
null,
"A governance engine that runs event action services.",
"https://egeria-project.org/concepts/event-action-engine/"),
CONTEXT_EVENT_ENGINE("Context Event Engine",
DeployedImplementationType.GOVERNANCE_ENGINE,
OpenMetadataType.CONTEXT_EVENT_ENGINE.typeName,
null,
"A governance engine that runs context event services.",
"https://egeria-project.org/concepts/context-event-engine/"),

/**
* Event Action Service - A connector that coordinates asset surveys.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -490,7 +490,7 @@ Content-Type: application/json

{
"class" : "InitiateGovernanceActionTypeRequestBody",
"governanceActionTypeQualifiedName": "Egeria:GovernanceActionProcessStep:2adeb8f1-0f59-4970-b6f2-6cc25d4d2402survey-folder",
"governanceActionTypeQualifiedName": "Egeria:GovernanceActionType:2adeb8f1-0f59-4970-b6f2-6cc25d4d2402survey-folder",
"actionTargets": [
{
"class" : "NewActionTarget",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,10 @@
public class ToDoRequestBody extends CommunityProfileOMASAPIRequestBody
{
private List<NewActionTargetProperties> newActionTargetProperties = null;
private ToDoProperties properties = null;
private String originatorGUID = null;
private String actionOwnerGUID = null;
private String assignToActorGUID = null;
private ToDoProperties properties = null;
private String originatorGUID = null;
private String actionSponsorGUID = null;
private String assignToActorGUID = null;
/**
* Default constructor
*/
Expand All @@ -51,9 +51,9 @@ public ToDoRequestBody(ToDoRequestBody template)
{
this.newActionTargetProperties = template.getNewActionTargetProperties();
this.properties = template.getProperties();
this.originatorGUID = template.getOriginatorGUID();
this.actionOwnerGUID = template.getActionOwnerGUID();
this.assignToActorGUID = template.getAssignToActorGUID();
this.originatorGUID = template.getOriginatorGUID();
this.actionSponsorGUID = template.getActionSponsorGUID();
this.assignToActorGUID = template.getAssignToActorGUID();
}
}

Expand Down Expand Up @@ -125,24 +125,24 @@ public void setOriginatorGUID(String originatorGUID)


/**
* Return the unique identifier of the owner of the To Do.
* Return the unique identifier of the sponsor of the To Do.
*
* @return guid
*/
public String getActionOwnerGUID()
public String getActionSponsorGUID()
{
return actionOwnerGUID;
return actionSponsorGUID;
}


/**
* Set up the unique identifier of the owner of the To Do.
* Set up the unique identifier of the sponsor of the To Do.
*
* @param actionOwnerGUID guid
* @param actionSponsorGUID guid
*/
public void setActionOwnerGUID(String actionOwnerGUID)
public void setActionSponsorGUID(String actionSponsorGUID)
{
this.actionOwnerGUID = actionOwnerGUID;
this.actionSponsorGUID = actionSponsorGUID;
}


Expand Down Expand Up @@ -181,7 +181,7 @@ public String toString()
"newActionTargetProperties=" + newActionTargetProperties +
", properties=" + properties +
", originatorGUID='" + originatorGUID + '\'' +
", actionOwnerGUID='" + actionOwnerGUID + '\'' +
", actionSponsorGUID='" + actionSponsorGUID + '\'' +
", assignToActorGUID='" + assignToActorGUID + '\'' +
"} " + super.toString();
}
Expand Down Expand Up @@ -209,7 +209,7 @@ public boolean equals(Object objectToCompare)
return Objects.equals(newActionTargetProperties, that.newActionTargetProperties) &&
Objects.equals(properties, that.properties) &&
Objects.equals(originatorGUID, that.originatorGUID) &&
Objects.equals(actionOwnerGUID, that.actionOwnerGUID) &&
Objects.equals(actionSponsorGUID, that.actionSponsorGUID) &&
Objects.equals(assignToActorGUID, that.assignToActorGUID);
}

Expand All @@ -222,6 +222,6 @@ public boolean equals(Object objectToCompare)
@Override
public int hashCode()
{
return Objects.hash(newActionTargetProperties, properties, originatorGUID, actionOwnerGUID, assignToActorGUID);
return Objects.hash(newActionTargetProperties, properties, originatorGUID, actionSponsorGUID, assignToActorGUID);
}
}
Loading
Loading