Request to /MDX2JSON/PivotVariables/Patients?Namespace=IRISAPP show 404 error
When requesting pivot variables from a cube, a 404 error is displayed. What's the problem? Is it IRIS or is it API?
<HTML>
<HEAD>
<TITLE>Not Found</TITLE>
</HEAD>
<BODY>
<H1>Not Found</H1>
The requested URL /MDX2JSON/PivotVariables/Patients was not found on this server.
</BODY>
</HTML>
Comments
HTTP 404 normally states that URL you're requesting does not exist.
This may be due to various reasons... a few that pop up in my mind:
1) web application for MDX2JSON is misconfigured or has another root path
2) the cube doesn't exist or has a different logical name (cubes can be retrieved here )
....
Do you receive positive response with /MDX2JSON/Test ?
/MDX2JSON/Test gives an adequate response yes
How can i retrieve a logical name of a cube?
Do you have this line:
<!-- Get info about pivot variables-->
<Route Url="/PivotVariables/:Cube" Method="GET" Call="WritePivotVariablesForCube"/>in the UrlMap of the MDX2JSON.REST class?
Yes, exactly like your example
The WritePivotVariablesForCube upon debug however return proper response
{
"children":[
{
"name":"Year",
"caption":"Year",
"defValue":2018,
"context":"literal",
"desc":""
}
]
}
404 is also returned when there are some permissions issues. Try to give %All to the user that you calling this API with and see if it helps. If yes -- then this is permissions issue. Or enable Audit and auditing for Protect event and see if it is logged in Audit when the problem happens
Other idea -- enable ISCLOG, reproduce the problem, disable ISCLOG and see if there are any errors there. ISCLOG is very verbose, so just do one HTTP request with ISCLOG enabled
enable:
%SYS>kill ^ISCLOG,^%ISCLOG
%SYS>set ^%ISCLOG = 3
disable:
%SYS>set ^%ISCLOG = 0
analyze:
%SYS>zw ^ISCLOG (yes, without %)
It is very useful! At first it gave out "The web application does not exist." Then I create it manually and then the response was "Illegal web request".
This is something to start with! Thank you.