6 improvements based on Oracle Architecture Center reference diagrams:
1. Edge label offset — labels pushed 15px away from edge midpoint via
mxGeometry offset injection, prevents overlap with icons
2. Auto-sizing containers — regions, VCNs, tenancy calculate dimensions
from content instead of using fixed sizes (DR region: 540→260px)
3. jettySize=auto on all edges — clean stubs leaving/entering shapes
4. Dual connection merging — duplicate from/to pairs merged into single
edge with combined label (e.g., dual FastConnect)
5. DRG placed OUTSIDE VCN, INSIDE region — matches Oracle ref arch
pattern where DRG is the central hub between external and VCN
6. container=1;collapsible=0 injected into container XML styles
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Root cause: elbow=vertical conflicted with orthogonalEdgeStyle + port
constraints, causing arrows to route backwards and cross content.
Changes to oci_diagram_gen.py (generic, all diagrams):
- Remove elbow=vertical from edge base style
- Use edgeStyle=orthogonalEdgeStyle explicitly in extra_style
- Add jumpStyle=arc;jumpSize=8 — crossing edges show arc, not overlap
- Remove drawpyo waypoints="orthogonal" (now controlled via extra_style
to avoid style merging conflicts)
- Vertical edges with labels: align=left so text doesn't overlap icons
- Regression tested with PharmaCorp (dual-region) and MELI (single-region)
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Edges now auto-detect exit/entry ports based on relative positions of
source and target services. Uses absolute coordinates from the layout
engine to determine whether connections should exit right→left,
top→bottom, etc.
- exitX/exitY/entryX/entryY added to every edge style
- 1.5x threshold favors vertical routing over horizontal when positions
are diagonal — matches Oracle ref arch top-down subnet flow
- Eliminates crossing arrows in multi-subnet, multi-region diagrams
- Verified with both PharmaCorp (dual-region) and MELI (single-region)
Generic code fix — applies to all diagrams, not just this spec.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
oci_diagram_gen.py auto-layout improvements:
- Gateways now placed FIRST, vertically centered on VCN left edge
- Subnets offset RIGHT by gateway lane width to avoid overlap
- Gateway lane width auto-calculated from widest gateway + padding
- Network edges: teal color, thicker (2px) for visual hierarchy
- Internal edges: gray dashed for management connections
- Data edges: solid charcoal (unchanged, default)
These are generic code fixes — apply to any diagram spec, not just
the PharmaCorp demo. Verified with both PharmaCorp and MELI specs.
Also regenerated all PharmaCorp deliverables with prior fixes:
- Business case: PharmaCorp (was MELI), correct TCO/ROI/value schema
- BOM: verified SKUs from catalog, 45% global discount applied
- PDF: environment catalogue with new schema
- Diagram: clean layout with gateway offset
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The diagram-spec.yaml was using a flat regions/subnets format but
the generator expects tenancy.regions[].vcns[].subnets[].services[]
with explicit IDs. Rewrote with full pharma architecture:
- Queretaro (primary): Hub VCN with 4 subnets (DB, App, Public, Mgmt),
ExaCS X11M, EBS app tier, WAF, Vault, DRG, monitoring
- Sao Paulo (DR): DR VCN with ExaCS standby, FSDR, Object Storage
- 10 connections: dual FastConnect, Data Guard, FSDR, WAF chain, RMAN
Result: 231 cells, 11 containers, 15 services, 10 connections (was empty)
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>