bunny_farm 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (106) hide show
  1. checksums.yaml +7 -0
  2. data/.envrc +1 -0
  3. data/.github/workflows/docs.yml +38 -0
  4. data/.gitignore +11 -0
  5. data/.travis.yml +3 -0
  6. data/CHANGELOG.md +61 -0
  7. data/COMMITS.md +196 -0
  8. data/Gemfile +4 -0
  9. data/LICENSE.txt +21 -0
  10. data/README.md +330 -0
  11. data/Rakefile +9 -0
  12. data/bunny_farm.gemspec +30 -0
  13. data/config/bunny.yml.erb +29 -0
  14. data/config/bunny_test.yml.erb +29 -0
  15. data/config/hipchat.yml.erb +12 -0
  16. data/docs/api/configuration.md +9 -0
  17. data/docs/api/consumer.md +8 -0
  18. data/docs/api/message-class.md +419 -0
  19. data/docs/api/publisher.md +9 -0
  20. data/docs/architecture/integration.md +8 -0
  21. data/docs/architecture/message-flow.md +11 -0
  22. data/docs/architecture/overview.md +448 -0
  23. data/docs/architecture/scaling.md +8 -0
  24. data/docs/assets/actions_dsl_flow.svg +109 -0
  25. data/docs/assets/architecture_overview.svg +152 -0
  26. data/docs/assets/best_practices_patterns.svg +203 -0
  27. data/docs/assets/bunny_farm_logo.png +0 -0
  28. data/docs/assets/configuration_api_methods.svg +104 -0
  29. data/docs/assets/configuration_flow.svg +130 -0
  30. data/docs/assets/configuration_hierarchy.svg +70 -0
  31. data/docs/assets/data_processing_pipeline.svg +131 -0
  32. data/docs/assets/debugging_monitoring.svg +165 -0
  33. data/docs/assets/ecommerce_example_flow.svg +145 -0
  34. data/docs/assets/email_campaign_example.svg +127 -0
  35. data/docs/assets/environment_variables_map.svg +78 -0
  36. data/docs/assets/error_handling_flow.svg +114 -0
  37. data/docs/assets/favicon.ico +1 -0
  38. data/docs/assets/fields_dsl_structure.svg +89 -0
  39. data/docs/assets/instance_methods_lifecycle.svg +137 -0
  40. data/docs/assets/integration_patterns.svg +207 -0
  41. data/docs/assets/json_serialization_flow.svg +153 -0
  42. data/docs/assets/logo.svg +4 -0
  43. data/docs/assets/message_api_overview.svg +126 -0
  44. data/docs/assets/message_encapsulation.svg +113 -0
  45. data/docs/assets/message_lifecycle.svg +110 -0
  46. data/docs/assets/message_structure.svg +138 -0
  47. data/docs/assets/publisher_consumer_api.svg +120 -0
  48. data/docs/assets/scaling_deployment_patterns.svg +195 -0
  49. data/docs/assets/smart_routing_diagram.svg +131 -0
  50. data/docs/assets/system_architecture_overview.svg +155 -0
  51. data/docs/assets/task_scheduling_flow.svg +139 -0
  52. data/docs/assets/testing_strategies.svg +146 -0
  53. data/docs/assets/workflow_patterns.svg +183 -0
  54. data/docs/assets/yaml_config_structure.svg +72 -0
  55. data/docs/configuration/environment-variables.md +14 -0
  56. data/docs/configuration/overview.md +373 -0
  57. data/docs/configuration/programmatic-setup.md +10 -0
  58. data/docs/configuration/yaml-configuration.md +12 -0
  59. data/docs/core-features/configuration.md +528 -0
  60. data/docs/core-features/error-handling.md +82 -0
  61. data/docs/core-features/json-serialization.md +545 -0
  62. data/docs/core-features/message-design.md +406 -0
  63. data/docs/core-features/smart-routing.md +467 -0
  64. data/docs/core-features/task-scheduling.md +67 -0
  65. data/docs/core-features/workflow-support.md +112 -0
  66. data/docs/development/contributing.md +345 -0
  67. data/docs/development/roadmap.md +9 -0
  68. data/docs/development/testing.md +14 -0
  69. data/docs/examples/order-processing.md +10 -0
  70. data/docs/examples/overview.md +269 -0
  71. data/docs/examples/real-world.md +8 -0
  72. data/docs/examples/simple-producer-consumer.md +15 -0
  73. data/docs/examples/task-scheduler.md +9 -0
  74. data/docs/getting-started/basic-concepts.md +274 -0
  75. data/docs/getting-started/installation.md +122 -0
  76. data/docs/getting-started/quick-start.md +158 -0
  77. data/docs/index.md +106 -0
  78. data/docs/message-structure/actions-dsl.md +163 -0
  79. data/docs/message-structure/fields-dsl.md +146 -0
  80. data/docs/message-structure/instance-methods.md +115 -0
  81. data/docs/message-structure/overview.md +211 -0
  82. data/examples/README.md +212 -0
  83. data/examples/consumer.rb +41 -0
  84. data/examples/images/message_flow.svg +87 -0
  85. data/examples/images/order_workflow.svg +122 -0
  86. data/examples/images/producer_consumer.svg +96 -0
  87. data/examples/images/task_scheduler.svg +140 -0
  88. data/examples/order_processor.rb +238 -0
  89. data/examples/producer.rb +60 -0
  90. data/examples/simple_message.rb +43 -0
  91. data/examples/task_scheduler.rb +263 -0
  92. data/images/architecture_overview.svg +152 -0
  93. data/images/bunny_farm_logo.png +0 -0
  94. data/images/configuration_flow.svg +130 -0
  95. data/images/message_structure.svg +138 -0
  96. data/lib/bunny_farm/.irbrc +7 -0
  97. data/lib/bunny_farm/generic_consumer.rb +12 -0
  98. data/lib/bunny_farm/hash_ext.rb +37 -0
  99. data/lib/bunny_farm/init_bunny.rb +137 -0
  100. data/lib/bunny_farm/init_hipchat.rb +49 -0
  101. data/lib/bunny_farm/message.rb +218 -0
  102. data/lib/bunny_farm/message_elements.rb +25 -0
  103. data/lib/bunny_farm/version.rb +3 -0
  104. data/lib/bunny_farm.rb +9 -0
  105. data/mkdocs.yml +148 -0
  106. metadata +244 -0
@@ -0,0 +1,130 @@
1
+ <svg width="800" height="500" xmlns="http://www.w3.org/2000/svg">
2
+ <!-- Background transparent -->
3
+ <rect width="800" height="500" fill="transparent"/>
4
+
5
+ <!-- Title -->
6
+ <text x="400" y="30" text-anchor="middle" font-family="Arial, sans-serif" font-size="20" font-weight="bold" fill="#e0e0e0">
7
+ BunnyFarm Configuration Options
8
+ </text>
9
+
10
+ <!-- Environment Variables -->
11
+ <g>
12
+ <rect x="50" y="70" width="220" height="180" rx="10" fill="#2d3748" stroke="#68d391" stroke-width="2"/>
13
+ <text x="160" y="95" text-anchor="middle" font-family="Arial, sans-serif" font-size="14" font-weight="bold" fill="#68d391">Environment Variables</text>
14
+
15
+ <rect x="70" y="110" width="180" height="130" fill="#1a202c" stroke="#4a5568" stroke-width="1"/>
16
+ <text x="75" y="125" font-family="monospace" font-size="10" fill="#68d391">AMQP_HOST</text>
17
+ <text x="140" y="125" font-family="monospace" font-size="10" fill="#e0e0e0">=localhost</text>
18
+
19
+ <text x="75" y="140" font-family="monospace" font-size="10" fill="#68d391">AMQP_VHOST</text>
20
+ <text x="140" y="140" font-family="monospace" font-size="10" fill="#e0e0e0">=/</text>
21
+
22
+ <text x="75" y="155" font-family="monospace" font-size="10" fill="#68d391">AMQP_PORT</text>
23
+ <text x="140" y="155" font-family="monospace" font-size="10" fill="#e0e0e0">=5672</text>
24
+
25
+ <text x="75" y="170" font-family="monospace" font-size="10" fill="#68d391">AMQP_USER</text>
26
+ <text x="140" y="170" font-family="monospace" font-size="10" fill="#e0e0e0">=guest</text>
27
+
28
+ <text x="75" y="185" font-family="monospace" font-size="10" fill="#68d391">AMQP_PASS</text>
29
+ <text x="140" y="185" font-family="monospace" font-size="10" fill="#e0e0e0">=guest</text>
30
+
31
+ <text x="75" y="200" font-family="monospace" font-size="10" fill="#68d391">AMQP_EXCHANGE</text>
32
+ <text x="155" y="200" font-family="monospace" font-size="10" fill="#e0e0e0">=my_exchange</text>
33
+
34
+ <text x="75" y="215" font-family="monospace" font-size="10" fill="#68d391">AMQP_QUEUE</text>
35
+ <text x="135" y="215" font-family="monospace" font-size="10" fill="#e0e0e0">=my_queue</text>
36
+
37
+ <text x="75" y="230" font-family="monospace" font-size="10" fill="#68d391">AMQP_ROUTING_KEY</text>
38
+ <text x="175" y="230" font-family="monospace" font-size="10" fill="#e0e0e0">=#</text>
39
+ </g>
40
+
41
+ <!-- YAML Configuration -->
42
+ <g>
43
+ <rect x="300" y="70" width="220" height="180" rx="10" fill="#2d3748" stroke="#4299e1" stroke-width="2"/>
44
+ <text x="410" y="95" text-anchor="middle" font-family="Arial, sans-serif" font-size="14" font-weight="bold" fill="#4299e1">YAML Configuration</text>
45
+ <text x="410" y="110" text-anchor="middle" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">config/bunny.yml.erb</text>
46
+
47
+ <rect x="320" y="120" width="180" height="120" fill="#1a202c" stroke="#4a5568" stroke-width="1"/>
48
+ <text x="325" y="135" font-family="monospace" font-size="10" fill="#4299e1">defaults: and defaults</text>
49
+ <text x="330" y="150" font-family="monospace" font-size="10" fill="#68d391">host:</text>
50
+ <text x="360" y="150" font-family="monospace" font-size="10" fill="#f6e05e">ENV['AMQP_HOST']</text>
51
+ <text x="330" y="165" font-family="monospace" font-size="10" fill="#68d391">port:</text>
52
+ <text x="360" y="165" font-family="monospace" font-size="10" fill="#f6e05e">ENV['AMQP_PORT']</text>
53
+ <text x="325" y="180" font-family="monospace" font-size="10" fill="#4299e1">development:</text>
54
+ <text x="330" y="195" font-family="monospace" font-size="10" fill="#e0e0e0">inherits: defaults</text>
55
+ <text x="325" y="210" font-family="monospace" font-size="10" fill="#4299e1">production:</text>
56
+ <text x="330" y="225" font-family="monospace" font-size="10" fill="#e0e0e0">inherits: defaults</text>
57
+ </g>
58
+
59
+ <!-- Programmatic Configuration -->
60
+ <g>
61
+ <rect x="550" y="70" width="220" height="180" rx="10" fill="#2d3748" stroke="#9f7aea" stroke-width="2"/>
62
+ <text x="660" y="95" text-anchor="middle" font-family="Arial, sans-serif" font-size="14" font-weight="bold" fill="#9f7aea">Ruby Configuration</text>
63
+ <text x="660" y="110" text-anchor="middle" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">BunnyFarm.config block</text>
64
+
65
+ <rect x="570" y="120" width="180" height="120" fill="#1a202c" stroke="#4a5568" stroke-width="1"/>
66
+ <text x="575" y="135" font-family="monospace" font-size="10" fill="#9f7aea">BunnyFarm.config do</text>
67
+ <text x="580" y="150" font-family="monospace" font-size="10" fill="#68d391">env</text>
68
+ <text x="605" y="150" font-family="monospace" font-size="10" fill="#e0e0e0">'production'</text>
69
+ <text x="580" y="165" font-family="monospace" font-size="10" fill="#68d391">app_id</text>
70
+ <text x="620" y="165" font-family="monospace" font-size="10" fill="#e0e0e0">'my_worker'</text>
71
+ <text x="580" y="180" font-family="monospace" font-size="10" fill="#68d391">bunny_file</text>
72
+ <text x="645" y="180" font-family="monospace" font-size="10" fill="#e0e0e0">'custom.yml'</text>
73
+ <text x="580" y="195" font-family="monospace" font-size="10" fill="#9ca3af"># Custom settings</text>
74
+ <text x="575" y="230" font-family="monospace" font-size="10" fill="#9f7aea">end</text>
75
+ </g>
76
+
77
+ <!-- Configuration Flow -->
78
+ <g>
79
+ <rect x="50" y="280" width="700" height="120" rx="10" fill="#2d3748" stroke="#f6e05e" stroke-width="2"/>
80
+ <text x="400" y="305" text-anchor="middle" font-family="Arial, sans-serif" font-size="16" font-weight="bold" fill="#f6e05e">Configuration Priority Flow</text>
81
+
82
+ <!-- Priority boxes -->
83
+ <rect x="80" y="325" width="120" height="60" rx="8" fill="#68d391" stroke="#68d391" stroke-width="1"/>
84
+ <text x="140" y="345" text-anchor="middle" font-family="Arial, sans-serif" font-size="12" font-weight="bold" fill="#1a202c">1. Defaults</text>
85
+ <text x="140" y="365" text-anchor="middle" font-family="Arial, sans-serif" font-size="10" fill="#1a202c">Built-in values</text>
86
+
87
+ <rect x="220" y="325" width="120" height="60" rx="8" fill="#4299e1" stroke="#4299e1" stroke-width="1"/>
88
+ <text x="280" y="345" text-anchor="middle" font-family="Arial, sans-serif" font-size="12" font-weight="bold" fill="#1a202c">2. YAML</text>
89
+ <text x="280" y="365" text-anchor="middle" font-family="Arial, sans-serif" font-size="10" fill="#1a202c">Config file</text>
90
+
91
+ <rect x="360" y="325" width="120" height="60" rx="8" fill="#68d391" stroke="#68d391" stroke-width="1"/>
92
+ <text x="420" y="345" text-anchor="middle" font-family="Arial, sans-serif" font-size="12" font-weight="bold" fill="#1a202c">3. ENV Vars</text>
93
+ <text x="420" y="365" text-anchor="middle" font-family="Arial, sans-serif" font-size="10" fill="#1a202c">Environment</text>
94
+
95
+ <rect x="500" y="325" width="120" height="60" rx="8" fill="#9f7aea" stroke="#9f7aea" stroke-width="1"/>
96
+ <text x="560" y="345" text-anchor="middle" font-family="Arial, sans-serif" font-size="12" font-weight="bold" fill="#1a202c">4. Ruby Code</text>
97
+ <text x="560" y="365" text-anchor="middle" font-family="Arial, sans-serif" font-size="10" fill="#1a202c">Programmatic</text>
98
+
99
+ <rect x="640" y="325" width="120" height="60" rx="8" fill="#e53e3e" stroke="#e53e3e" stroke-width="1"/>
100
+ <text x="700" y="345" text-anchor="middle" font-family="Arial, sans-serif" font-size="12" font-weight="bold" fill="#1a202c">Final Config</text>
101
+ <text x="700" y="365" text-anchor="middle" font-family="Arial, sans-serif" font-size="10" fill="#1a202c">Used by app</text>
102
+
103
+ <!-- Arrows -->
104
+ <defs>
105
+ <marker id="arrow-priority" markerWidth="10" markerHeight="7" refX="9" refY="3.5" orient="auto">
106
+ <polygon points="0 0, 10 3.5, 0 7" fill="#f6e05e"/>
107
+ </marker>
108
+ </defs>
109
+
110
+ <line x1="200" y1="355" x2="220" y2="355" stroke="#f6e05e" stroke-width="2" marker-end="url(#arrow-priority)"/>
111
+ <line x1="340" y1="355" x2="360" y2="355" stroke="#f6e05e" stroke-width="2" marker-end="url(#arrow-priority)"/>
112
+ <line x1="480" y1="355" x2="500" y2="355" stroke="#f6e05e" stroke-width="2" marker-end="url(#arrow-priority)"/>
113
+ <line x1="620" y1="355" x2="640" y2="355" stroke="#f6e05e" stroke-width="2" marker-end="url(#arrow-priority)"/>
114
+ </g>
115
+
116
+ <!-- Example Use Cases -->
117
+ <g>
118
+ <rect x="50" y="420" width="700" height="70" rx="10" fill="#1a202c" stroke="#4a5568" stroke-width="1"/>
119
+ <text x="400" y="440" text-anchor="middle" font-family="Arial, sans-serif" font-size="14" font-weight="bold" fill="#f6e05e">Common Configuration Patterns</text>
120
+
121
+ <text x="70" y="460" font-family="Arial, sans-serif" font-size="11" font-weight="bold" fill="#68d391">Development:</text>
122
+ <text x="150" y="460" font-family="Arial, sans-serif" font-size="11" fill="#e0e0e0">Local RabbitMQ, default settings</text>
123
+
124
+ <text x="400" y="460" font-family="Arial, sans-serif" font-size="11" font-weight="bold" fill="#4299e1">Production:</text>
125
+ <text x="470" y="460" font-family="Arial, sans-serif" font-size="11" fill="#e0e0e0">Environment variables for security</text>
126
+
127
+ <text x="70" y="475" font-family="Arial, sans-serif" font-size="11" font-weight="bold" fill="#ed8936">Testing:</text>
128
+ <text x="125" y="475" font-family="Arial, sans-serif" font-size="11" fill="#e0e0e0">Custom config with test-specific settings</text>
129
+ </g>
130
+ </svg>
@@ -0,0 +1,70 @@
1
+ <svg width="800" height="600" xmlns="http://www.w3.org/2000/svg">
2
+ <rect width="800" height="600" fill="transparent"/>
3
+
4
+ <!-- Title -->
5
+ <text x="400" y="30" text-anchor="middle" font-family="Arial, sans-serif" font-size="18" font-weight="bold" fill="#e0e0e0">
6
+ BunnyFarm Configuration Hierarchy
7
+ </text>
8
+
9
+ <!-- Configuration Sources -->
10
+ <g>
11
+ <text x="400" y="70" text-anchor="middle" font-family="Arial, sans-serif" font-size="16" font-weight="bold" fill="#ff9800">
12
+ Configuration Priority (High to Low)
13
+ </text>
14
+
15
+ <!-- 1. Code Configuration -->
16
+ <rect x="50" y="100" width="700" height="80" rx="8" fill="#2d3748" stroke="#e53e3e" stroke-width="3"/>
17
+ <text x="70" y="125" font-family="Arial, sans-serif" font-size="14" font-weight="bold" fill="#e53e3e">1. Code Configuration (Highest Priority)</text>
18
+ <text x="70" y="145" font-family="monospace" font-size="12" fill="#e0e0e0">BunnyFarm.configure do |config|</text>
19
+ <text x="80" y="160" font-family="monospace" font-size="12" fill="#e0e0e0">config.rabbitmq_url = "amqp://localhost:5672"</text>
20
+ <text x="70" y="175" font-family="monospace" font-size="12" fill="#e0e0e0">end</text>
21
+
22
+ <!-- 2. Environment Variables -->
23
+ <rect x="50" y="200" width="700" height="80" rx="8" fill="#2d3748" stroke="#f6e05e" stroke-width="2"/>
24
+ <text x="70" y="225" font-family="Arial, sans-serif" font-size="14" font-weight="bold" fill="#f6e05e">2. Environment Variables</text>
25
+ <text x="70" y="245" font-family="monospace" font-size="12" fill="#e0e0e0">RABBITMQ_URL="amqp://prod-rabbit:5672"</text>
26
+ <text x="70" y="260" font-family="monospace" font-size="12" fill="#e0e0e0">BUNNY_FARM_EXCHANGE="production_exchange"</text>
27
+ <text x="70" y="275" font-family="monospace" font-size="12" fill="#e0e0e0">BUNNY_FARM_RETRY_ATTEMPTS=5</text>
28
+
29
+ <!-- 3. YAML Files -->
30
+ <rect x="50" y="300" width="700" height="80" rx="8" fill="#2d3748" stroke="#4299e1" stroke-width="2"/>
31
+ <text x="70" y="325" font-family="Arial, sans-serif" font-size="14" font-weight="bold" fill="#4299e1">3. YAML Configuration Files</text>
32
+ <text x="70" y="345" font-family="monospace" font-size="12" fill="#e0e0e0">config/bunny_farm.yml</text>
33
+ <text x="70" y="360" font-family="monospace" font-size="12" fill="#e0e0e0">config/environments/production.yml</text>
34
+ <text x="70" y="375" font-family="monospace" font-size="12" fill="#e0e0e0">~/.bunny_farm/config.yml</text>
35
+
36
+ <!-- 4. Defaults -->
37
+ <rect x="50" y="400" width="700" height="80" rx="8" fill="#2d3748" stroke="#68d391" stroke-width="1"/>
38
+ <text x="70" y="425" font-family="Arial, sans-serif" font-size="14" font-weight="bold" fill="#68d391">4. Framework Defaults (Lowest Priority)</text>
39
+ <text x="70" y="445" font-family="monospace" font-size="12" fill="#e0e0e0">rabbitmq_url: "amqp://localhost:5672"</text>
40
+ <text x="70" y="460" font-family="monospace" font-size="12" fill="#e0e0e0">exchange_name: "bunny_farm"</text>
41
+ <text x="70" y="475" font-family="monospace" font-size="12" fill="#e0e0e0">retry_attempts: 3</text>
42
+ </g>
43
+
44
+ <!-- Configuration Categories -->
45
+ <g>
46
+ <text x="400" y="530" text-anchor="middle" font-family="Arial, sans-serif" font-size="16" font-weight="bold" fill="#e0e0e0">
47
+ Configuration Categories
48
+ </text>
49
+
50
+ <!-- RabbitMQ -->
51
+ <rect x="50" y="550" width="140" height="40" rx="6" fill="#1a202c" stroke="#9f7aea" stroke-width="1"/>
52
+ <text x="120" y="570" text-anchor="middle" font-family="Arial, sans-serif" font-size="11" font-weight="bold" fill="#9f7aea">RabbitMQ</text>
53
+ <text x="120" y="585" text-anchor="middle" font-family="Arial, sans-serif" font-size="9" fill="#e0e0e0">Connection and Auth</text>
54
+
55
+ <!-- Routing -->
56
+ <rect x="210" y="550" width="140" height="40" rx="6" fill="#1a202c" stroke="#68d391" stroke-width="1"/>
57
+ <text x="280" y="570" text-anchor="middle" font-family="Arial, sans-serif" font-size="11" font-weight="bold" fill="#68d391">Routing</text>
58
+ <text x="280" y="585" text-anchor="middle" font-family="Arial, sans-serif" font-size="9" fill="#e0e0e0">Exchange and Queues</text>
59
+
60
+ <!-- Retry Logic -->
61
+ <rect x="370" y="550" width="140" height="40" rx="6" fill="#1a202c" stroke="#4299e1" stroke-width="1"/>
62
+ <text x="440" y="570" text-anchor="middle" font-family="Arial, sans-serif" font-size="11" font-weight="bold" fill="#4299e1">Retry Logic</text>
63
+ <text x="440" y="585" text-anchor="middle" font-family="Arial, sans-serif" font-size="9" fill="#e0e0e0">Attempts and Backoff</text>
64
+
65
+ <!-- Logging -->
66
+ <rect x="530" y="550" width="140" height="40" rx="6" fill="#1a202c" stroke="#f6e05e" stroke-width="1"/>
67
+ <text x="600" y="570" text-anchor="middle" font-family="Arial, sans-serif" font-size="11" font-weight="bold" fill="#f6e05e">Logging</text>
68
+ <text x="600" y="585" text-anchor="middle" font-family="Arial, sans-serif" font-size="9" fill="#e0e0e0">Level and Format</text>
69
+ </g>
70
+ </svg>
@@ -0,0 +1,131 @@
1
+ <svg width="1000" height="600" xmlns="http://www.w3.org/2000/svg">
2
+ <rect width="1000" height="600" fill="transparent"/>
3
+
4
+ <!-- Title -->
5
+ <text x="500" y="30" text-anchor="middle" font-family="Arial, sans-serif" font-size="18" font-weight="bold" fill="#e0e0e0">
6
+ Data Processing Pipeline Example
7
+ </text>
8
+
9
+ <!-- Pipeline Stages -->
10
+ <g>
11
+ <text x="500" y="70" text-anchor="middle" font-family="Arial, sans-serif" font-size="16" font-weight="bold" fill="#4299e1">
12
+ Multi-Stage Data Processing Workflow
13
+ </text>
14
+
15
+ <!-- Stage 1: Ingest -->
16
+ <rect x="50" y="100" width="180" height="80" rx="8" fill="#2d3748" stroke="#68d391" stroke-width="2"/>
17
+ <text x="140" y="125" text-anchor="middle" font-family="Arial, sans-serif" font-size="12" font-weight="bold" fill="#68d391">1. Data Ingestion</text>
18
+ <text x="60" y="145" font-family="monospace" font-size="10" fill="#e0e0e0">• CSV uploads</text>
19
+ <text x="60" y="160" font-family="monospace" font-size="10" fill="#e0e0e0">• API webhooks</text>
20
+ <text x="60" y="175" font-family="monospace" font-size="10" fill="#e0e0e0">• Database exports</text>
21
+
22
+ <!-- Stage 2: Validate -->
23
+ <rect x="250" y="100" width="180" height="80" rx="8" fill="#2d3748" stroke="#4299e1" stroke-width="2"/>
24
+ <text x="340" y="125" text-anchor="middle" font-family="Arial, sans-serif" font-size="12" font-weight="bold" fill="#4299e1">2. Data Validation</text>
25
+ <text x="260" y="145" font-family="monospace" font-size="10" fill="#e0e0e0">• Schema validation</text>
26
+ <text x="260" y="160" font-family="monospace" font-size="10" fill="#e0e0e0">• Data quality checks</text>
27
+ <text x="260" y="175" font-family="monospace" font-size="10" fill="#e0e0e0">• Duplicate detection</text>
28
+
29
+ <!-- Stage 3: Transform -->
30
+ <rect x="450" y="100" width="180" height="80" rx="8" fill="#2d3748" stroke="#9f7aea" stroke-width="2"/>
31
+ <text x="540" y="125" text-anchor="middle" font-family="Arial, sans-serif" font-size="12" font-weight="bold" fill="#9f7aea">3. Data Transform</text>
32
+ <text x="460" y="145" font-family="monospace" font-size="10" fill="#e0e0e0">• Normalize formats</text>
33
+ <text x="460" y="160" font-family="monospace" font-size="10" fill="#e0e0e0">• Calculate metrics</text>
34
+ <text x="460" y="175" font-family="monospace" font-size="10" fill="#e0e0e0">• Enrich with lookups</text>
35
+
36
+ <!-- Stage 4: Aggregate -->
37
+ <rect x="650" y="100" width="180" height="80" rx="8" fill="#2d3748" stroke="#f6e05e" stroke-width="2"/>
38
+ <text x="740" y="125" text-anchor="middle" font-family="Arial, sans-serif" font-size="12" font-weight="bold" fill="#f6e05e">4. Data Aggregate</text>
39
+ <text x="660" y="145" font-family="monospace" font-size="10" fill="#e0e0e0">• Group by dimensions</text>
40
+ <text x="660" y="160" font-family="monospace" font-size="10" fill="#e0e0e0">• Statistical analysis</text>
41
+ <text x="660" y="175" font-family="monospace" font-size="10" fill="#e0e0e0">• Time series rollups</text>
42
+
43
+ <!-- Stage 5: Output -->
44
+ <rect x="850" y="100" width="140" height="80" rx="8" fill="#2d3748" stroke="#e53e3e" stroke-width="2"/>
45
+ <text x="920" y="125" text-anchor="middle" font-family="Arial, sans-serif" font-size="12" font-weight="bold" fill="#e53e3e">5. Data Output</text>
46
+ <text x="860" y="145" font-family="monospace" font-size="10" fill="#e0e0e0">• Database load</text>
47
+ <text x="860" y="160" font-family="monospace" font-size="10" fill="#e0e0e0">• Dashboard update</text>
48
+ <text x="860" y="175" font-family="monospace" font-size="10" fill="#e0e0e0">• Report generation</text>
49
+ </g>
50
+
51
+ <!-- Message Implementation -->
52
+ <g>
53
+ <text x="500" y="230" text-anchor="middle" font-family="Arial, sans-serif" font-size="16" font-weight="bold" fill="#e0e0e0">
54
+ DataProcessingMessage Implementation
55
+ </text>
56
+
57
+ <rect x="50" y="250" width="900" height="140" rx="8" fill="#2d3748" stroke="#4299e1" stroke-width="2"/>
58
+ <text x="500" y="275" text-anchor="middle" font-family="Arial, sans-serif" font-size="14" font-weight="bold" fill="#4299e1">Data Processing Message Class</text>
59
+
60
+ <text x="70" y="300" font-family="monospace" font-size="11" fill="#68d391">class DataProcessingMessage &lt; BunnyFarm::Message</text>
61
+ <text x="80" y="320" font-family="monospace" font-size="11" fill="#f6e05e">fields</text>
62
+ <text x="130" y="320" font-family="monospace" font-size="11" fill="#e0e0e0">:batch_id, :source_type, :data_path, :schema_version, :processing_options</text>
63
+ <text x="80" y="340" font-family="monospace" font-size="11" fill="#f6e05e">actions</text>
64
+ <text x="140" y="340" font-family="monospace" font-size="11" fill="#e0e0e0">:ingest, :validate, :transform, :aggregate, :output, :cleanup</text>
65
+
66
+ <text x="80" y="365" font-family="monospace" font-size="11" fill="#9f7aea">def ingest</text>
67
+ <text x="90" y="380" font-family="monospace" font-size="11" fill="#e0e0e0">load_data and publish('validate')</text>
68
+ <text x="80" y="395" font-family="monospace" font-size="11" fill="#9f7aea">end</text>
69
+
70
+ <text x="350" y="365" font-family="monospace" font-size="11" fill="#9f7aea">def validate</text>
71
+ <text x="360" y="380" font-family="monospace" font-size="11" fill="#e0e0e0">validate_schema and publish('transform')</text>
72
+ <text x="350" y="395" font-family="monospace" font-size="11" fill="#9f7aea">end</text>
73
+
74
+ <text x="620" y="365" font-family="monospace" font-size="11" fill="#9f7aea">def transform</text>
75
+ <text x="630" y="380" font-family="monospace" font-size="11" fill="#e0e0e0">normalize_data and publish('aggregate')</text>
76
+ <text x="620" y="395" font-family="monospace" font-size="11" fill="#9f7aea">end</text>
77
+
78
+ <text x="70" y="415" font-family="monospace" font-size="11" fill="#68d391">end</text>
79
+ </g>
80
+
81
+ <!-- Processing Patterns -->
82
+ <g>
83
+ <text x="500" y="450" text-anchor="middle" font-family="Arial, sans-serif" font-size="16" font-weight="bold" fill="#e0e0e0">
84
+ Common Data Processing Patterns
85
+ </text>
86
+
87
+ <!-- Batch Processing -->
88
+ <rect x="50" y="470" width="200" height="100" rx="6" fill="#1a202c" stroke="#68d391" stroke-width="1"/>
89
+ <text x="150" y="490" text-anchor="middle" font-family="Arial, sans-serif" font-size="12" font-weight="bold" fill="#68d391">Batch Processing</text>
90
+ <text x="60" y="510" font-family="monospace" font-size="10" fill="#e0e0e0">Large file uploads</text>
91
+ <text x="60" y="525" font-family="monospace" font-size="10" fill="#e0e0e0">Daily/hourly imports</text>
92
+ <text x="60" y="540" font-family="monospace" font-size="10" fill="#e0e0e0">Scheduled ETL jobs</text>
93
+ <text x="60" y="555" font-family="monospace" font-size="10" fill="#e0e0e0">Historical data migration</text>
94
+
95
+ <!-- Stream Processing -->
96
+ <rect x="270" y="470" width="200" height="100" rx="6" fill="#1a202c" stroke="#4299e1" stroke-width="1"/>
97
+ <text x="370" y="490" text-anchor="middle" font-family="Arial, sans-serif" font-size="12" font-weight="bold" fill="#4299e1">Stream Processing</text>
98
+ <text x="280" y="510" font-family="monospace" font-size="10" fill="#e0e0e0">Real-time events</text>
99
+ <text x="280" y="525" font-family="monospace" font-size="10" fill="#e0e0e0">API webhooks</text>
100
+ <text x="280" y="540" font-family="monospace" font-size="10" fill="#e0e0e0">Sensor data</text>
101
+ <text x="280" y="555" font-family="monospace" font-size="10" fill="#e0e0e0">User activity logs</text>
102
+
103
+ <!-- Error Recovery -->
104
+ <rect x="490" y="470" width="200" height="100" rx="6" fill="#1a202c" stroke="#e53e3e" stroke-width="1"/>
105
+ <text x="590" y="490" text-anchor="middle" font-family="Arial, sans-serif" font-size="12" font-weight="bold" fill="#e53e3e">Error Recovery</text>
106
+ <text x="500" y="510" font-family="monospace" font-size="10" fill="#e0e0e0">Partial batch reprocessing</text>
107
+ <text x="500" y="525" font-family="monospace" font-size="10" fill="#e0e0e0">Data quality quarantine</text>
108
+ <text x="500" y="540" font-family="monospace" font-size="10" fill="#e0e0e0">Manual review queue</text>
109
+ <text x="500" y="555" font-family="monospace" font-size="10" fill="#e0e0e0">Rollback capabilities</text>
110
+
111
+ <!-- Monitoring -->
112
+ <rect x="710" y="470" width="200" height="100" rx="6" fill="#1a202c" stroke="#9f7aea" stroke-width="1"/>
113
+ <text x="810" y="490" text-anchor="middle" font-family="Arial, sans-serif" font-size="12" font-weight="bold" fill="#9f7aea">Monitoring</text>
114
+ <text x="720" y="510" font-family="monospace" font-size="10" fill="#e0e0e0">Processing metrics</text>
115
+ <text x="720" y="525" font-family="monospace" font-size="10" fill="#e0e0e0">Data quality alerts</text>
116
+ <text x="720" y="540" font-family="monospace" font-size="10" fill="#e0e0e0">Performance tracking</text>
117
+ <text x="720" y="555" font-family="monospace" font-size="10" fill="#e0e0e0">SLA monitoring</text>
118
+ </g>
119
+
120
+ <!-- Flow arrows -->
121
+ <defs>
122
+ <marker id="arrow-data" markerWidth="8" markerHeight="6" refX="7" refY="3" orient="auto">
123
+ <polygon points="0 0, 8 3, 0 6" fill="#ff9800"/>
124
+ </marker>
125
+ </defs>
126
+
127
+ <line x1="230" y1="140" x2="250" y2="140" stroke="#ff9800" stroke-width="2" marker-end="url(#arrow-data)"/>
128
+ <line x1="430" y1="140" x2="450" y2="140" stroke="#ff9800" stroke-width="2" marker-end="url(#arrow-data)"/>
129
+ <line x1="630" y1="140" x2="650" y2="140" stroke="#ff9800" stroke-width="2" marker-end="url(#arrow-data)"/>
130
+ <line x1="830" y1="140" x2="850" y2="140" stroke="#ff9800" stroke-width="2" marker-end="url(#arrow-data)"/>
131
+ </svg>
@@ -0,0 +1,165 @@
1
+ <svg width="1000" height="700" xmlns="http://www.w3.org/2000/svg">
2
+ <rect width="1000" height="700" fill="transparent"/>
3
+
4
+ <!-- Title -->
5
+ <text x="500" y="30" text-anchor="middle" font-family="Arial, sans-serif" font-size="18" font-weight="bold" fill="#e0e0e0">
6
+ Debugging and Monitoring BunnyFarm Applications
7
+ </text>
8
+
9
+ <!-- Logging Layers -->
10
+ <g>
11
+ <text x="500" y="70" text-anchor="middle" font-family="Arial, sans-serif" font-size="16" font-weight="bold" fill="#4299e1">
12
+ Logging and Observability Stack
13
+ </text>
14
+
15
+ <!-- Application Logs -->
16
+ <rect x="50" y="100" width="180" height="80" rx="8" fill="#2d3748" stroke="#68d391" stroke-width="2"/>
17
+ <text x="140" y="125" text-anchor="middle" font-family="Arial, sans-serif" font-size="12" font-weight="bold" fill="#68d391">Application Logs</text>
18
+ <text x="60" y="145" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">• Message processing</text>
19
+ <text x="60" y="160" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">• Business logic events</text>
20
+ <text x="60" y="175" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">• Error details</text>
21
+
22
+ <!-- Message Logs -->
23
+ <rect x="250" y="100" width="180" height="80" rx="8" fill="#2d3748" stroke="#4299e1" stroke-width="2"/>
24
+ <text x="340" y="125" text-anchor="middle" font-family="Arial, sans-serif" font-size="12" font-weight="bold" fill="#4299e1">Message Logs</text>
25
+ <text x="260" y="145" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">• Publish/consume events</text>
26
+ <text x="260" y="160" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">• Routing information</text>
27
+ <text x="260" y="175" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">• Message tracing</text>
28
+
29
+ <!-- RabbitMQ Logs -->
30
+ <rect x="450" y="100" width="180" height="80" rx="8" fill="#2d3748" stroke="#2b6cb0" stroke-width="2"/>
31
+ <text x="540" y="125" text-anchor="middle" font-family="Arial, sans-serif" font-size="12" font-weight="bold" fill="#2b6cb0">RabbitMQ Logs</text>
32
+ <text x="460" y="145" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">• Connection events</text>
33
+ <text x="460" y="160" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">• Queue operations</text>
34
+ <text x="460" y="175" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">• Performance metrics</text>
35
+
36
+ <!-- Infrastructure Logs -->
37
+ <rect x="650" y="100" width="180" height="80" rx="8" fill="#2d3748" stroke="#9f7aea" stroke-width="2"/>
38
+ <text x="740" y="125" text-anchor="middle" font-family="Arial, sans-serif" font-size="12" font-weight="bold" fill="#9f7aea">Infrastructure</text>
39
+ <text x="660" y="145" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">• System resources</text>
40
+ <text x="660" y="160" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">• Container metrics</text>
41
+ <text x="660" y="175" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">• Network performance</text>
42
+ </g>
43
+
44
+ <!-- Debugging Tools -->
45
+ <g>
46
+ <text x="500" y="230" text-anchor="middle" font-family="Arial, sans-serif" font-size="16" font-weight="bold" fill="#e0e0e0">
47
+ Debugging Tools and Techniques
48
+ </text>
49
+
50
+ <!-- Message Inspector -->
51
+ <rect x="50" y="260" width="300" height="120" rx="6" fill="#2d3748" stroke="#68d391" stroke-width="1"/>
52
+ <text x="200" y="285" text-anchor="middle" font-family="Arial, sans-serif" font-size="13" font-weight="bold" fill="#68d391">Message Inspector</text>
53
+
54
+ <text x="70" y="305" font-family="monospace" font-size="10" fill="#9ca3af"># Interactive debugging</text>
55
+ <text x="70" y="320" font-family="monospace" font-size="10" fill="#e0e0e0">BunnyFarm::Inspector.start</text>
56
+ <text x="70" y="335" font-family="monospace" font-size="10" fill="#e0e0e0">inspector.watch_queue('orders')</text>
57
+ <text x="70" y="350" font-family="monospace" font-size="10" fill="#e0e0e0">inspector.inspect_message(id)</text>
58
+ <text x="70" y="365" font-family="monospace" font-size="10" fill="#e0e0e0">inspector.replay_message(id)</text>
59
+
60
+ <!-- Queue Browser -->
61
+ <rect x="370" y="260" width="300" height="120" rx="6" fill="#2d3748" stroke="#4299e1" stroke-width="1"/>
62
+ <text x="520" y="285" text-anchor="middle" font-family="Arial, sans-serif" font-size="13" font-weight="bold" fill="#4299e1">Queue Browser</text>
63
+
64
+ <text x="390" y="305" font-family="monospace" font-size="10" fill="#9ca3af"># Queue inspection</text>
65
+ <text x="390" y="320" font-family="monospace" font-size="10" fill="#e0e0e0">BunnyFarm::QueueBrowser.new</text>
66
+ <text x="390" y="335" font-family="monospace" font-size="10" fill="#e0e0e0">browser.peek_messages(10)</text>
67
+ <text x="390" y="350" font-family="monospace" font-size="10" fill="#e0e0e0">browser.queue_stats</text>
68
+ <text x="390" y="365" font-family="monospace" font-size="10" fill="#e0e0e0">browser.purge_queue</text>
69
+
70
+ <!-- RabbitMQ Management -->
71
+ <rect x="690" y="260" width="260" height="120" rx="6" fill="#2d3748" stroke="#2b6cb0" stroke-width="1"/>
72
+ <text x="820" y="285" text-anchor="middle" font-family="Arial, sans-serif" font-size="13" font-weight="bold" fill="#2b6cb0">RabbitMQ Management</text>
73
+
74
+ <text x="710" y="305" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">• Web UI dashboard</text>
75
+ <text x="710" y="320" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">• Queue depth monitoring</text>
76
+ <text x="710" y="335" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">• Connection tracking</text>
77
+ <text x="710" y="350" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">• Message flow visualization</text>
78
+ <text x="710" y="365" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">• Performance metrics</text>
79
+ </g>
80
+
81
+ <!-- Monitoring Dashboard -->
82
+ <g>
83
+ <text x="500" y="430" text-anchor="middle" font-family="Arial, sans-serif" font-size="16" font-weight="bold" fill="#e0e0e0">
84
+ Monitoring Dashboard Components
85
+ </text>
86
+
87
+ <!-- Message Metrics -->
88
+ <rect x="50" y="450" width="200" height="100" rx="6" fill="#1a202c" stroke="#68d391" stroke-width="1"/>
89
+ <text x="150" y="475" text-anchor="middle" font-family="Arial, sans-serif" font-size="12" font-weight="bold" fill="#68d391">Message Metrics</text>
90
+ <text x="60" y="495" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">Messages per second</text>
91
+ <text x="60" y="510" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">Processing time</text>
92
+ <text x="60" y="525" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">Success/failure rates</text>
93
+ <text x="60" y="540" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">Retry counts</text>
94
+
95
+ <!-- Queue Health -->
96
+ <rect x="270" y="450" width="200" height="100" rx="6" fill="#1a202c" stroke="#4299e1" stroke-width="1"/>
97
+ <text x="370" y="475" text-anchor="middle" font-family="Arial, sans-serif" font-size="12" font-weight="bold" fill="#4299e1">Queue Health</text>
98
+ <text x="280" y="495" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">Queue depth</text>
99
+ <text x="280" y="510" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">Consumer count</text>
100
+ <text x="280" y="525" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">Dead letter queue</text>
101
+ <text x="280" y="540" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">Memory usage</text>
102
+
103
+ <!-- Error Tracking -->
104
+ <rect x="490" y="450" width="200" height="100" rx="6" fill="#1a202c" stroke="#e53e3e" stroke-width="1"/>
105
+ <text x="590" y="475" text-anchor="middle" font-family="Arial, sans-serif" font-size="12" font-weight="bold" fill="#e53e3e">Error Tracking</text>
106
+ <text x="500" y="495" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">Error rates by type</text>
107
+ <text x="500" y="510" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">Error details and stack</text>
108
+ <text x="500" y="525" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">Alert notifications</text>
109
+ <text x="500" y="540" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">Error trends</text>
110
+
111
+ <!-- Performance -->
112
+ <rect x="710" y="450" width="200" height="100" rx="6" fill="#1a202c" stroke="#f6e05e" stroke-width="1"/>
113
+ <text x="810" y="475" text-anchor="middle" font-family="Arial, sans-serif" font-size="12" font-weight="bold" fill="#f6e05e">Performance</text>
114
+ <text x="720" y="495" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">Throughput graphs</text>
115
+ <text x="720" y="510" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">Latency percentiles</text>
116
+ <text x="720" y="525" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">Memory/CPU usage</text>
117
+ <text x="720" y="540" font-family="Arial, sans-serif" font-size="10" fill="#e0e0e0">Connection pools</text>
118
+ </g>
119
+
120
+ <!-- Alerting Strategy -->
121
+ <g>
122
+ <text x="500" y="600" text-anchor="middle" font-family="Arial, sans-serif" font-size="16" font-weight="bold" fill="#e0e0e0">
123
+ Alerting and Incident Response
124
+ </text>
125
+
126
+ <!-- Critical Alerts -->
127
+ <rect x="80" y="620" width="160" height="60" rx="6" fill="#1a202c" stroke="#e53e3e" stroke-width="1"/>
128
+ <text x="160" y="640" text-anchor="middle" font-family="Arial, sans-serif" font-size="11" font-weight="bold" fill="#e53e3e">Critical Alerts</text>
129
+ <text x="90" y="655" font-family="Arial, sans-serif" font-size="9" fill="#e0e0e0">• Queue depth > threshold</text>
130
+ <text x="90" y="670" font-family="Arial, sans-serif" font-size="9" fill="#e0e0e0">• Error rate > 5%</text>
131
+
132
+ <!-- Warning Alerts -->
133
+ <rect x="260" y="620" width="160" height="60" rx="6" fill="#1a202c" stroke="#f6e05e" stroke-width="1"/>
134
+ <text x="340" y="640" text-anchor="middle" font-family="Arial, sans-serif" font-size="11" font-weight="bold" fill="#f6e05e">Warning Alerts</text>
135
+ <text x="270" y="655" font-family="Arial, sans-serif" font-size="9" fill="#e0e0e0">• Slow processing times</text>
136
+ <text x="270" y="670" font-family="Arial, sans-serif" font-size="9" fill="#e0e0e0">• Memory pressure</text>
137
+
138
+ <!-- Info Alerts -->
139
+ <rect x="440" y="620" width="160" height="60" rx="6" fill="#1a202c" stroke="#4299e1" stroke-width="1"/>
140
+ <text x="520" y="640" text-anchor="middle" font-family="Arial, sans-serif" font-size="11" font-weight="bold" fill="#4299e1">Info Alerts</text>
141
+ <text x="450" y="655" font-family="Arial, sans-serif" font-size="9" fill="#e0e0e0">• Deployment events</text>
142
+ <text x="450" y="670" font-family="Arial, sans-serif" font-size="9" fill="#e0e0e0">• Scaling events</text>
143
+
144
+ <!-- Response Actions -->
145
+ <rect x="620" y="620" width="260" height="60" rx="6" fill="#1a202c" stroke="#68d391" stroke-width="1"/>
146
+ <text x="750" y="640" text-anchor="middle" font-family="Arial, sans-serif" font-size="11" font-weight="bold" fill="#68d391">Automated Response</text>
147
+ <text x="630" y="655" font-family="Arial, sans-serif" font-size="9" fill="#e0e0e0">• Auto-scaling workers</text>
148
+ <text x="630" y="670" font-family="Arial, sans-serif" font-size="9" fill="#e0e0e0">• Circuit breaker activation</text>
149
+ </g>
150
+
151
+ <!-- Data Flow Arrows -->
152
+ <defs>
153
+ <marker id="arrow-debug" markerWidth="8" markerHeight="6" refX="7" refY="3" orient="auto">
154
+ <polygon points="0 0, 8 3, 0 6" fill="#ff9800"/>
155
+ </marker>
156
+ </defs>
157
+
158
+ <!-- Log flow to monitoring -->
159
+ <line x1="140" y1="180" x2="140" y2="260" stroke="#ff9800" stroke-width="2" marker-end="url(#arrow-debug)"/>
160
+ <line x1="340" y1="180" x2="340" y2="260" stroke="#ff9800" stroke-width="2" marker-end="url(#arrow-debug)"/>
161
+ <line x1="540" y1="180" x2="540" y2="260" stroke="#ff9800" stroke-width="2" marker-end="url(#arrow-debug)"/>
162
+
163
+ <!-- Monitoring to alerts -->
164
+ <line x1="450" y1="550" x2="450" y2="620" stroke="#ff9800" stroke-width="2" marker-end="url(#arrow-debug)"/>
165
+ </svg>