on 2018 Jul 31 8:18 AM
HI Experts,
I have just built a business rule project in my trail account in SAP cloud platform. Everything went well. When I click on Deploy button from Rule services tab, system asks me to select the system . I select SAP cloud platform and i get a deployment error screen. Screen shot attached. i am not sure where to check the details of the error or what is the error about. before deploying i clicked validate and there are no errors.
yes, the rule has executed but it seems your body (request variable) is not set correctly. Please see in the blogs how I have constructed the input payload when it is passed as request variable in service task. You can test rule service from API Business Hub (api.sap.com) or via any rest client. For workflow, you need to use Monitor App (as you have been using) to see any errors. There is no way to debug. You need to use the tools to find the errors. Error messages are self explanatory and the workflow can be corrected. Hope that helps.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Archana,
I have now made some progress and trying to learn few tricks by reading several blogs. I added postman addon to my chrome and trying to test my ruleservvice from there. First I have used below URL to get the xsrf-token. the call was successful and I got the token guid
https://bpmrulesruntimebpm-p1942918606trial.hanatrial.ondemand.com/rules-service/v1/rules/xsrf-token
then I tried a post request with the below URL by passing xsrf-token from above step and also content-type as application/json. In the body I placed the json as below
[ { "__type__" : "ImportDO", "price" : "7", "product" : "AAA" } ]
I get response code as "404 not found". is there something wrong with the URL above?
Yes, the URL. It should be this:
Update:
I have changed the URL to below and now i get status code 500. looks like the call is working now.
the response is
{ "error": "Index: 0, Size: 0" }
I feel there is something wrong in the way I defined the rule
Yes you have. As seen from the screenshot you have given the condition value expression in the condition header itself. When you click to open the Table Settings dialog (as seen in your screenshot) you just need to enter product of the ImportDO. Then in the decision table condition value you say is equal to 'AAA'. You can create another condition header with expression price of the ImportDO and then give the value as is equal to 7. Your decision table should look like this:
Please follow these blogs carefully and you would know the answers:
https://blogs.sap.com/2017/05/02/overview-of-business-rules-in-cloud-platform/
https://blogs.sap.com/2018/01/18/use-sap-cloud-platform-business-rules-in-your-custom-applications/
There are sample decision table that you can import and see how the rules are modelled.
Hope that helps.
Hurray.
Hurray!!.. Finally after struggling for 2 days I am able to execute my workflow without any error along with business rules. Thank you so much for your patience. I would like to move another step.
I have three steps in my workflow Purcahser, Functional and Manager steps.
In my ruleservice, I have output strucure containing below fields
I would like to skip steps based on the values of individual fields in the above strucuture. I believe exclusive gateways help here to achive that. is it the right way to do it?
Good that you achieved it. And Yes, gateways are way to go ahead:
https://help.sap.com/viewer/f85276c5069a429fa37d1cd352785c25/Cloud/en-US/22cda7ec05514383b914229b57b...
There could be many reasons for 500 internal server error. Please raise a ticket in LOB-BPM-RUL component and attach the rules project.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Can anybody suggest i am getting the
The HTTP request to 'https://bpmruleruntime.cfapps.eu10.hana.ondemand.com/rules-service/rest/v2/workingset-rule-services' failed with status code 500 (Internal Server Error) and response body '{"error":{"code":"bpm.rulesruntime.internalservererror","message":"Error encountered during processing of request","details":[]}}'.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I am facing so many issues and seeing so many bugs in this product. Is it possible to scedule a call with you archana.shukla?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
No there are not. Can you please schedule a call with me and I can help you with that or you can use POSTMAN or any other REST client that you have.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
The URL is wrong to fetch the XSRF token. Please read the blog carefully and configure your destination and XSRF correctly.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
HI,
May be i missed something. As I am completely new to this, could you guide me where the mistake is?
thanks in advance
Hi,
I have read the comments in your blog and adjusted the URLs and now I am getting below error in workflow log. Does this mean the rule got executed but it encountered an error. How do i actually debug these things. is there any way I can debug?
The HTTP request to 'https://bpmrulesruntimebpm-p1942918606trial.hanatrial.ondemand.com/rules-service/rest/v1/rule-services/java/MyApprovalProject/ApprovalService' failed with status code 500 () and response body '{"error" : "Index: 0, Size: 0"}'.
Ok I found the issue seeing your rules screenshot. Empty values are not supported.
Fill in the values and then try and deploy
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thank you, you saved my day 🙂 I am now able to deploy. Now I have another problem wiht workflow. I have created a service task and used the business rule there by following your blog
https://blogs.sap.com/2018/02/02/using-business-rules-in-sap-cloud-platform-workflow/
I have attached the screen shot of the details section of the service task
When I create a new instance for the workflow in the service task step i see below error
The XSRF token request to URL 'https://bpmrulesruntimebpm-p1942918606trial.hanatrial.ondemand.com/xsrf-token' failed with HTTP status code 404 () and response body
what could be the reason?
Hello Sankara,
This happens when you have missed any Input DO in rule service. Please ensure that you have added all the data objects that you have used in rule modelling added as Input. Additionally, if you have 2-3 DO as Input ensure that there is association between them.
Regards,
Archana
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Ruleservice screenshot
Rule screeshot
Ruleset screenshot
User | Count |
---|---|
73 | |
10 | |
9 | |
8 | |
8 | |
6 | |
6 | |
6 | |
5 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.