How to address the cross browser issue?

382 views
Skip to first unread message

Takafumi Sakai

unread,
Jun 8, 2015, 3:24:51 AM6/8/15
to suppor...@runmyprocess.com
Although this is too familiar to raise here, I have to say this because I can't see any solution in terms of RMP.

I've got the following error:

No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'null' is therefore not allowed access. The response had HTTP status code 401.

There are some options to resolve this issue such as using JSONP or adding Access-Control-Allow-Origin header, but I can't believe that any of these solutions are allowed in RMP.

Then, how can I deal with it?

Takafumi Sakai

Pankaj Kumar

unread,
Jun 9, 2015, 1:34:46 AM6/9/15
to suppor...@runmyprocess.com, Takafumi Sakai
Hi Takafumi,

Kindly share the details/steps when you are getting this error so we can analysis it and propose a solution/workaround.


Thank you,
Pankaj Kumar
Fujitsu RunMyProcess Support


Takafumi Sakai

--
Fujitsu - RunMyProcess
---
You received this message because you are subscribed to the Google Groups "Fujitsu RunMyProcess Developer Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to supportforum...@runmyprocess.com.
To post to this group, send email to suppor...@runmyprocess.com.
Visit this group at http://groups.google.com/a/runmyprocess.com/group/supportforum/.
To view this discussion on the web visit https://groups.google.com/a/runmyprocess.com/d/msgid/supportforum/98cb2cb1-c9a7-43b7-a59d-6f67e448ecdf%40runmyprocess.com.
For more options, visit https://groups.google.com/a/runmyprocess.com/d/optout.

lagavulin.isla...@gmail.com

unread,
Jun 11, 2015, 4:36:27 AM6/11/15
to suppor...@runmyprocess.com, lagavulin.isla...@gmail.com
Hi Pankaj,

Thank you for your reply to my question.

Here is the error I got on Chrome when I request JSON data from RMP composite API.

XMLHttpRequest cannot load https://live.runmyprocess.jp/live/113921369218575832/host/81377/service/115…EAS2354&count=3&freeword=%E5%B1%85%E9%85%92%E5%B1%8B&callback=testCallback. No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'null' is therefore not allowed access. The response had HTTP status code 401.

The request method is GET. I could get a response when using IE, but Chrome and FireFox show the same kind of error.

I could correctly get a response when I use JSONP from a certain restaurant search site. When I choose XML or regular JSON format response, I got the same error for this site as well. I guess that the same thing is happening with RMP composite API. So I need to know how I can avoid this issue.

If you need more information for this, please let me know.

Pankaj Kumar

unread,
Jun 13, 2015, 5:01:43 AM6/13/15
to suppor...@runmyprocess.com, Takafumi Sakai
Hi Takafumi,

The error details suggests the issue is related to "Cross-origin resource sharing" and that is why by "JSONP" error is not coming as its uses a callback function to wrap the JSON (in string) in the function. Though by using connectors in the CAPI we connect to the outside RMP world.

Please give us more details of your CAPI in order to give us more understanding on this issue.

Thank you,
Pankaj Kumar
Fujitsu RunMyProcess Support


lagavulin.isla...@gmail.com

unread,
Jun 14, 2015, 10:35:21 PM6/14/15
to suppor...@runmyprocess.com, lagavulin.isla...@gmail.com
Hi Pankaj,

Thank you for your response. Here is the screen captures of my CAPI. Please check those out and let me know when you need more information about those.

Thanks,
Takafumi Sakai
CAPI1.jpg
CAPI2.jpg

Pankaj Kumar

unread,
Jun 20, 2015, 3:39:13 PM6/20/15
to suppor...@runmyprocess.com, Takafumi Sakai
Hi Takafumi,

I try to reproduce this error in my local project by creating the CAPI and connector of some open web services like restaurant search though not able to do so. Kindly share the details of your connector, which service you are integrating.

Thank you,
Pankaj Kumar
Fujitsu RunMyProcess Support

lagavulin.isla...@gmail.com

unread,
Jun 21, 2015, 10:17:37 PM6/21/15
to suppor...@runmyprocess.com
Hi Pankaj,

Any CAPI could reproduce the problem. Just making a simple CAPI which doesn't have any connection with other outside services and have some output values on a CAPI process. Then connect from a certain HTML which uses $get method of JQuery to get JSON data from CAPI.

A get method of JQuery could be the source of this problem, but I don't know how I can get data from a CAPI.

If more information is necessary, let me know.

Thanks,
Takafumi Sakai

Pankaj Kumar

unread,
Jun 23, 2015, 9:00:22 AM6/23/15
to suppor...@runmyprocess.com, Takafumi Sakai
Hi Takafumi,

A composite API can be triggered in the following ways:

  • As a task in a process.
  • As a listener in a web interface.
  • Directly via its exposed API (from a third-party).
Below user guide links will be useful for triggering the CAPI.:-
You can use the "trigger" method to invoke the CAPI using javascript in web interface.

function ok(P_computed){
    alert("success:  "+JSON.stringify(P_computed))
}

function ko(P_error){
    alert(JSON.stringify(P_error));
    }

var input = {};
var options = {};

CAPI_identifier_Name.trigger(input,options,ok,ko);

Also when I tried calling the CAPI from the web interface, using the $get method, I get the result successfully.

Thank you,
Pankaj Kumar
Fujitsu RunMyProcess Support

lagavulin.isla...@gmail.com

unread,
Jun 24, 2015, 2:32:05 AM6/24/15
to suppor...@runmyprocess.com
Hi Pankaj,

Thank you for your answer.

I forget to tell you that I'm developing a web application outside RMP using its exposed API. In this case, I could not get the data correctly in Chrome and Firefox.

Please check this out.

Thanks,
Takafumi Sakai

On Tuesday, June 23, 2015 at 10:00:22 PM UTC+9, Pankaj Kumar wrote:
> Hi Takafumi,
>
>
>
> A composite API can be triggered in the following ways:As a task in a process.As a listener in a web interface.Directly via its exposed API (from a third-party).

lagavulin.isla...@gmail.com

unread,
Jun 29, 2015, 8:31:01 PM6/29/15
to suppor...@runmyprocess.com, lagavulin.isla...@gmail.com
Hi,

Is there any progress for my issue?

Thanks,
Takafumi Sakai

Pankaj Kumar

unread,
Jun 30, 2015, 12:47:39 AM6/30/15
to suppor...@runmyprocess.com, Takafumi Sakai
Hi Takafumi,

We are able to replicate this issue in local environment, by invoking a CAPI from a simple html page using jquery. We have escalated your request within the team, and will update you soon on this.

Thank you,
Pankaj Kumar
Fujitsu RunMyProcess Support

Reply all
Reply to author
Forward
0 new messages