Skip to content

IAV-91/feat: Add parent agent relationship to Agent entity

salaheddine zidani a demandé de fusionner feature/IAV-91 vers develop

Summary

This MR adds support for hierarchical agent structures by introducing a parent-child relationship within the Agent entity.

Changes

  • Added parentAgent field with @ManyToOne relationship to the Agent entity
  • Configured lazy fetching to optimize query performance
  • Enables agents to reference a parent agent for inheritance or delegation patterns

Technical Details

  • Self-referential relationship using @JoinColumn(name = "parent_agent_id")
  • Foreign key stored in parent_agent_id column
  • Fetch type set to LAZY to prevent unnecessary data loading

Database Impact

  • New column: parent_agent_id (nullable) in agents table
  • Foreign key constraint to agents.id****

Closes IAV-91

Rapports de requête de fusion