Delta<T> As a odata parameter in web api Action - odata

I have requirement where i want to take two parameters for an action in odata, First parameter as string and second as delta, where T is entity type. There isn’t any syntax error but whenever i m making a post request it is throwing an exception stating this property is not in the delta, though i am passing the valid property from request body.
Can anyone help?

Related

Cypher - query missing parameter throws an exception

I have simple query with $login parameter
MATCH (user: User {login: $login})
RETURN user
when it is set to null in Neo4j Browser with
:param login => null
execution does not throw an exception and returns nothing which is expected.
However when I do not provide $login parameter following is thrown
Neo.ClientError.Statement.ParameterMissing
Expected parameter(s): login
Is there a way to proceed with query even if parameter key is not provided?
P.S.
I think the same issue is adressed here and according to the originator droping WHERE clause should make it work.
If a parameter isn't provided, you will always encounter an error when attempting to use that parameter.
However, you can get around this a bit with a little indirection. Consider passing a map structure as the parameter, which may contain entries for all of your other parameters, optional or not. As long as you're passing in the map parameter, your query should execute, and you can use either dot notation or index/key access into the map to use the parameters from the map.
For example:
:params {params:{name:'Keanu Reeves'}}
We now have a $params parameter in scope, which is a map. Usage can be $params.login or $params['login'], both of which return null for the non-existing entry in the map.

OData call with $filter and $expand simultaneously

I've been trying to call a entity, but i'm supposed to call the results from its associated entities. I tried to do it with the following URL:
/sap/opu/odata/XXXXXXXX/SERVICE_NAME/MatnrGetdetailCollection?$filter=IVendorId eq '1701' and ILanguage eq 'P' and IMaterial eq 'M-05'&$expand=MatnrClassGetdetail
I must use the filter because the called function has these mandatory parameters.
Am I making any mistake on the URL or the error isn't there?
In general $filter and $expand can be combined, we use it in our application. Therefore please see Layla's Comment. In addition, you should tell us what the actual error is.
If MatnrGetdetailCollection is indeed an entity set, then the corresponding entity must have a navigation property of the name MatnrClassGetdetail, otherwise $expand won't work.
There is some problem with the URL when you want to go for obligatory parameters. Please pass them as key values in segw and and go for the format I'm sending:
/sap/opu/odata/sap/SERVICE_NAME/EntitySet(keyfield='value',keyfield='value')/?$expand=navigationName

Grails: Accessing the request paramters without wiping them out

According to the document on command objects and data binding. Once you read the params object, that object can never be reused again.
From the documentation:
Binding The Request Body To Command Objects
http://grails.org/doc/2.3.x/guide/theWebLayer.html#commandObjects
Note that the body of the request is being parsed to make that work. Any attempt to read the body of the request after that will fail since the corresponding input stream will be empty. The controller action can either use a command object or it can parse the body of the request on its own (either directly, or by referring to something like request.JSON), but cannot do both.
I'm trying to view the parameters within a filter (which is hit before the controller is requested). Would logging the parameters to a log cause the controller to get a null param object? From the documentation that looks to be the case. However, how can I get access to the params without wiping them out in the filter?
Once you read the params object, that object can never be reused
again.
That is not correct. You can read request parameters over and over again. What cannot be read over and over again is the body of the request. The body and the request parameters are 2 different things.

Jmeter to pass JSF View State in Post request

I am evaluating the JMeter to be used for Load testing of our JSF application.
I followed the below link to find the way to pass JSF View State Id from one requests to other and it worked.
http://wiki.apache.org/myfaces/PerformanceTestingWithJMeter
I can see the JSF View State Id getting passed ,but the issue is the String got modified as below and causing view expired exception.
Actual JSF View State returned from GET :5843186584364912760:4842974224399060609
The subsequent POST request send this :5843186584364912760%3A4842974224399060609
The ":" character in middle is replaced with %3A (hexa value), is there any way to bypass this and pass the exact string from one request to other.
Flag this parameter so that it won't be encoded.
It's a checkbox in post parameters called 'Encode?'
http://jmeter.apache.org/usermanual/component_reference.html#HTTP_Request

WIF Error: "ID3094: Cannot create WS-Federation message from the given URI 'http://myurl'"

Can anyone tell me what this error means?
I just starting getting it from the STS I build using WIF and I can't find any documentation.
The URL is missing some required parameters.
A message instance is created from the information present in the URL using the WSFederationMessage.CreateFromUri method.
This fragment from the MSDN page should provide an idea of what's going on:
Returns an appropriate implementation of WSFederationMessage based on the wa parameter in the query string; for example, if wa parameter is "wsignout1.0" then a SignOutRequestMessage object is returned.
Other exceptions may be thrown depending on the combination and values of parameters present in the query string.
Invokes the TryCreateFromUri method.

Resources