Api/views/list returns Could not load views definition file error

web_api
portfolios
governance

(Harikrishna Menon) #1

Version: 7.3

We have been using the REST API to create portfolios and applications. Once the set of portolios was created and computed, we started see the below error when we made a call to api/views/list, furthermore the admin page for portfolios also returns the same error.

“errors”:[{“msg”:“Could not load views definition file. Please validate views.def against schema at <sonar.host.url>/static/governance/views.xsd”

Is this a known issue, how do we recover from this and how can we troubleshoot what caused this error to happen in the first place


(G Ann Campbell) #2

Hi,

To clarify: you created your portfolios and applications by uploading an xml file?

And you started seeing this error on your first calculation?

Ann


(Harikrishna Menon) #3

No, I used the /api/applications/create, /api/views/create endpoint not the xml file. Also a few calculations succeeded that first time we did it. When we added a new set of portfolios, it failed. We suspect it could be due to some issue in the description field. If there is a way we can look at more detailed failure messages that would help


(Julien Lancelot) #6

Hi,

Could you try to execute GET api/view/definition ?
If it’s working you should be able to investigate your issue.

Regards