声纳(软件质量)-扩展声纳(控制器和视图)

发布于 2024-12-28 23:47:38 字数 317 浏览 2 评论 0原文

我已经摆弄 SONAR 一段时间了,我想将其扩展到某个点。我不认为我能够通过自定义插件来实现这一点,但如果我引入一个额外的控制器和一些视图 - 它就能完成工作。

现在据我了解,声纳中的 MVC 模型是用 RUBY 编写的,我还没有对 ruby​​ 编码进行研究,但在我开始之前 - 我的目标合理/可实现吗?

或者可以通过插件扩展添加额外的视图和控制器吗?

基本上,我只需要从声纳数据库收集有关该项目的某些信息,并将其显示在自定义视图中以获取其他统计信息。

谢谢。

PS我很难找到声纳开发的信息,也许有人可以推荐一些讨论声纳扩展主题的论坛?

I have been fiddling with SONAR for some time now, and I would like to extend it to some point. I don't think I will be able to achieve this with a custom plugin but if I would introduce an additional controller and some views - it would get the job done.

Now as I understand, MVC model in sonar is written in RUBY, and I have yet to do research on ruby coding, but before I get to that - is my goal reasonable/achievable ?

Or can additional views and controllers can be added via plugin extensions ?

Basically I just need certain information gathered from sonar DataBase about the project, and displayed in a custom view for additional statistics.

Thanks.

P.S. I have hard time finding information for sonar development, maybe someone could recommend some forums discussing sonar extension topics ?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

陌上芳菲 2025-01-04 23:47:38

目前还不可能通过 Sonar 插件同时添加 Ruby 控制器和视图。目前,在扩展 Sonar Web 界面时,您只能:

  • 添加 Ruby 小部件(将显示在仪表板上):这一个视图
  • 添加 Ruby Web 服务 API:这是一个控制器
  • 添加一个GWT扩展:在这里您可以定义一个控制器一个视图

但是,请注意,我们将来将放弃GWT支持,并将其替换为定义的可能性允许用 Ruby 编写控制器和视图的扩展点。

因此,为了满足您的需求,我建议您编写一个小部件,就像您可以在此处的 Sonar 源代码中看到的小部件一样: https://github.com/SonarSource/sonar/tree/master/plugins/sonar-core-plugin/src/main/resources/org/sonar/plugins/core/widgets

HTH

It is not possible yet to add Ruby controllers and views at the same time through a Sonar plugin. Currently, when extending Sonar Web interface, you can only:

  • Add a Ruby widget (that will be displayed on a dashboard): this is only a view
  • Add a Ruby web service API: this is only a controller
  • Add a GWT extension: here you can define a controller and a view

However, please note that we will drop GWT support in the future, and replace it with the possibility to define extension points that allow to write both controllers and views in Ruby.

So to answer your need, I would advise you to write a widget, like the ones you can see on Sonar source code here: https://github.com/SonarSource/sonar/tree/master/plugins/sonar-core-plugin/src/main/resources/org/sonar/plugins/core/widgets

HTH

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文