Skip to content

feat: add CloudAMQP billing plugin#81

Open
LZG3530606141 wants to merge 1 commit into
opencost:mainfrom
LZG3530606141:feat/cloudamqp-plugin
Open

feat: add CloudAMQP billing plugin#81
LZG3530606141 wants to merge 1 commit into
opencost:mainfrom
LZG3530606141:feat/cloudamqp-plugin

Conversation

@LZG3530606141
Copy link
Copy Markdown

Implements CloudAMQP billing plugin for OpenCost Plugins, as requested in #54.

Features

  • Fetch instances via CloudAMQP Customer API with plan pricing
  • Fetch invoices via CloudAMQP Customer API for detailed billing
  • Fall back to instance-based pricing if invoices unavailable
  • HTTP Basic Auth with API key
  • Maps billing fields to FOCUS spec: plan, region, nodes, node_type, pricing interval
  • Rate limiting and proper error handling

Testing

  • Unit tests for instance, invoice, and invoice item JSON unmarshalling

References

Closes #54

Signed-off-by: LZG3530606141 3530606141@qq.com

- Implement CloudAMQPCostSource for ingesting CloudAMQP billing data
- Fetch instances via CloudAMQP Customer API with plan pricing
- Fetch invoices via CloudAMQP Customer API for detailed billing
- Fall back to instance-based pricing if invoices unavailable
- Support HTTP Basic Auth with API key
- Map CloudAMQP billing fields to FOCUS spec including plan,
  region, nodes, node type, pricing interval
- Include rate limiting and proper error handling
- Add unit tests for JSON unmarshalling
- Add config validator
- Follow OpenCost plugin architecture (hashicorp go-plugin)

References:
- CloudAMQP Customer API: https://docs.cloudamqp.com/
- Issue: opencost#54

Signed-off-by: LZG3530606141 <3530606141@qq.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Cloudamqp Plugin

1 participant