Environment Manager for Unified Persistence Context Provision

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Developers face complexity in managing persistence for program components across different environments, such as J2EE and J2SE, due to differing standards and requirements for enterprise and standalone operations, necessitating separate handling for each environment.

Innovation Solution

An environment manager provides a common interface to a core persistence engine, abstracting dependencies and simplifying the process by offering a unified method for obtaining persistence contexts and JDBC connections, decoupling the entity manager from transactional dependencies and managing transactions effectively.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Adaptability or versatility

If separate persistence handling is implemented for different environments (J2EE and J2SE), then environment-specific requirements are met, but development complexity increases

Engineering Contradiction:
Improveenvironment compatibilityVSAvoiddevelopment complexity
Core Design Contradiction:
Adaptability or versatilityVSDevice complexity

Solution Approach 1:

The persistence engine implements a universal interface that works across both J2EE and J2SE environments. The environment manager provides a common persistence context retrieval mechanism that adapts to different transaction types (JTA and resource-local) without requiring separate implementation paths, thereby achieving environment compatibility while reducing development complexity

Inventive Principle:
Principle #6Universality (Multi-functionality)

Solution Approach 2:

The environment manager acts as an intermediary layer between the persistence engine and the underlying transactional environments. It abstracts the differences between JTA and resource-local transactions, allowing the persistence engine to interact with a standardized interface while the environment manager handles environment-specific details, thus resolving the contradiction between adaptability and complexity

Inventive Principle:
Principle #24Intermediary (Mediator)

2Ease of operation

If developers manually manage different transaction types and resource management, then fine-grained control is achieved, but ease of operation decreases

Engineering Contradiction:
Improvepersistence management easeVSAvoidtransaction management complexity
Core Design Contradiction:
Ease of operationVSDevice complexity

Solution Approach 1:

The persistence engine and environment manager implement self-service mechanisms that automatically retrieve and manage persistence contexts based on the current transactional environment. The system automatically detects whether it's operating in JTA or resource-local mode and retrieves the appropriate persistence context without requiring manual intervention, thereby improving ease of operation while managing complexity internally

Inventive Principle:
Principle #25Self-service

Solution Approach 2:

The environment manager serves as an intermediary that shields developers from the complexity of transaction management. It automatically handles the retrieval of persistence contexts for different transaction types (JTA and resource-local) through a unified interface, allowing developers to operate easily without needing to understand or manually manage the underlying transactional complexity

Inventive Principle:
Principle #24Intermediary (Mediator)

Data Source

PatentUS8032560B2Provision of persistence context to program components
Publication Date: 2011.10.04 SAP SE
  • US8032560B2 patent drawing
  • US8032560B2 patent drawing
  • US8032560B2 patent drawing

AI summary

A method and apparatus for provision of persistence context to program components. An embodiment of a method includes receiving a call from a persistence engine, the call requesting a persistence context for a program component of a computer application. There is a method call to obtain the persistence context; and the persistence context is provided to the persistence engine. Other embodiments are also disclosed and claimed.