gocrane / crane

Crane is a FinOps Platform for Cloud Resource Analytics and Economics in Kubernetes clusters. The goal is not only to help users to manage cloud cost easier but also ensure the quality of applications.
https://gocrane.io
Apache License 2.0
1.9k stars 385 forks source link

Crane Recommendation Framework #409

Open xieydd opened 2 years ago

xieydd commented 2 years ago

Describe the feature

At present, crane Recommendation has been applied to kubernetes resource fields such as resource recommendation, replica recommendation, HPA recommendation, etc. The algorithm modules of crane, such as DSP, Max and Percentile algorithm modules, have been verified to be stable and effective in production practice.At the same time, the offline data source of crane supports prometheus, grpc protocol service, and the online data source supports prometheus and metricsserver. However, we have received a lot of feedback from developers, mainly focusing on the following aspects:

  1. After I have defined many different Recommendation types, I want to add some filtering or inject logic, but there seems to be no such interface.
  2. Our monitoring system is not in the default implementation, how can I implement a custom interface so that my resources can also use crane's recommended optimization capabilities?
  3. We found that the crane algorithm is not very effective for our business type, but we have explored some effective algorithms before, how to connect to the crane system?
  4. We want to be able to interface directly to the billing system after cost optimization, so we can directly quantify how much money is saved.

In order to solve the above problems, we hope the whole recommendation process is more open and flexible. Therefore, we propose the crane recommendation framework, which will be divided into two types. The first is to implement recommendation flow logic in crane core code, and the second is out-of-tree, you need to implement extension point through http request or gRPC call.

xieydd commented 2 years ago

TODO

ghost commented 2 years ago

Yes, please refer to the updated answer in FR #397 for the above number 3 aspect;

BTW, the above fourth TODO should be How to develop your own recommendation flow. (typo ?)

xieydd commented 2 years ago

@ClouderPing tks, fixed it yet.

wu0407 commented 1 year ago

crane resource recommend algorithm is only effective in the CPU usage monitoring chart is wavy in my company, but not suit for the CPU utilization rate suddenly increases. I want classify the application of different resource use characteristics by monitor system, use different recommend algorithm by app category