You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@royale.apache.org by Fréderic Cox <co...@gmail.com> on 2018/02/15 11:04:36 UTC

Re: RemoteObject

For me it is still not working in latest release 0.9.1. I based my example
on the example in the SDK.

<?xml version="1.0" encoding="utf-8"?>
<js:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:js="library://ns.apache.org/royale/basic" applicationComplete=
"applicationCompleteHandler(event);">

    <fx:Script>
        <![CDATA[
            import org.apache.royale.net.RemoteObject;
            import org.apache.royale.net.events.FaultEvent;
            import org.apache.royale.net.events.ResultEvent;

            private function applicationCompleteHandler(evt:Event):void{
                testLabel.text = "Requesting from AMF";
                service.send("getPackages", null);
            }

            private function amfFaultHandler(evt:FaultEvent):void{
                testLabel.text = "Fault in calling AMF";
            }

            private function amfResultHandler(evt:ResultEvent):void{
                testLabel.text = "Result received from AMF";
            }
        ]]>
    </fx:Script>

<js:valuesImpl>
<js:SimpleCSSValuesImpl />
</js:valuesImpl>

   <js:beads>
<js:ClassAliasBead />
<js:RemoteObject id="service" result="amfResultHandler(event)" fault=
"amfFaultHandler(event)"
endPoint = "https://winkelbeheer.cityfashion.be/amfphp/gateway.php"
destination = "Meta"
source = "Meta"/>
</js:beads>

<js:initialView>
<js:View>
<js:Label id="testLabel" />
</js:View>
</js:initialView>
</js:Application>


It is not working and showing the following error in the browser:

Failed to load https://winkelbeheer.cityfashion.be/amfphp/gateway.php:
Response to preflight request doesn't pass access control check: No
'Access-Control-Allow-Origin' header is present on the requested resource.
Origin 'http://localhost' is therefore not allowed access.
Language.js:238 destination fault handler

   1. {code: -1004, message: "Invalid response type.", detail: "Invalid
   XMLHttpRequest response status or type.", data: null}
      1. code:-1004
      2. data:null
      3. detail:"Invalid XMLHttpRequest response status or type."
      4. message:"Invalid response type."
      5. __proto__:Object




It is able to compile and run regardless of the errors in compile log:

Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
println
SEVERE: /Users/frederic/Desktop/Personal/Web
Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apache/royale/reflection/AccessorDefinition.js:12:
ERROR - required "org.apache.royale.reflection.TypeDefinition" namespace
not provided yet
goog.require('org.apache.royale.reflection.TypeDefinition');
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
println
SEVERE: /Users/frederic/Desktop/Personal/Web
Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apache/royale/reflection/AccessorDefinition.js:13:
ERROR - required "org.apache.royale.reflection.VariableDefinition"
namespace not provided yet
goog.require('org.apache.royale.reflection.VariableDefinition');
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
println
SEVERE: /Users/frederic/Desktop/Personal/Web
Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apache/royale/reflection/MethodDefinition.js:14:
ERROR - required "org.apache.royale.reflection.TypeDefinition" namespace
not provided yet
goog.require('org.apache.royale.reflection.TypeDefinition');
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
println
SEVERE: /Users/frederic/Desktop/Personal/Web
Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apache/royale/reflection/ParameterDefinition.js:13:
ERROR- required "org.apache.royale.reflection.TypeDefinition" namespace not
provided yet
goog.require('org.apache.royale.reflection.TypeDefinition');
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
println
SEVERE: /Users/frederic/Desktop/Personal/Web
Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apache/royale/reflection/TypeDefinition.js:15:
ERROR - required "org.apache.royale.reflection.VariableDefinition"
namespace not provided yet
goog.require('org.apache.royale.reflection.VariableDefinition');
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
printSummary
WARNING: 5 error(s), 0 warning(s)
The project 'HelloRoyale' has been successfully compiled and optimized.
4.566387 seconds


On Mon, Jan 15, 2018 at 7:38 PM, Piotr Zarzycki <pi...@gmail.com>
wrote:

> Carlos,
>
> No problem. I have also couple of huge things related to Royale to do
> before my hand gets dirty with AMF! :) Unless someone urgently will needed.
> :)
>
> Thanks, Piotr
>
> 2018-01-15 19:27 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>
>> Hi Piotr,
>> I'll put this on my to do list, but have to do some things first.
>> thanks
>>
>> 2018-01-15 9:26 GMT+01:00 Piotr Zarzycki <pi...@gmail.com>:
>>
>>> Hi Carlos,
>>>
>>> Can you describe more how to setup those examples ? Could you add to
>>> RemoteObjectAMFTest README.md file where you describe steps. I would like
>>> to have AMF on my list for tests and improvements. Whenever I look into
>>> that I don't know how to proceed with it.
>>>
>>> Thanks, Piotr
>>>
>>> 2018-01-15 9:21 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>>>
>>>> Hi,
>>>>
>>>> there's an example that we get it working nicely at:
>>>>
>>>> https://github.com/apache/royale-asjs/tree/develop/examples/
>>>> royale/RemoteObjectAMFTest
>>>>
>>>> you can use that as a starting point for your test
>>>>
>>>> As well a java web app that is used along that royale client example is
>>>> at:
>>>>
>>>> https://github.com/apache/royale-asjs/tree/develop/examples/amf
>>>>
>>>> thanks
>>>>
>>>>
>>>> 2018-01-15 3:56 GMT+01:00 Carlos Cruz <ca...@nbtbizcapital.com>:
>>>>
>>>>> I have a lot of experience with Flex remoting and BlazeDS with Java,
>>>>> but with FlexJS and Royale I have none, but extrapolating from some JS
>>>>> tests I've done with AMF at this line: amfTestService.send("get
>>>>> ShippingMethods", []); you have to call a class in gateway.php and a
>>>>> method. Your request needs at least 3 properties.
>>>>>
>>>>>
>>>>>
>>>>> I'm also assuming your JS file and gateway.php are in the same domain
>>>>> and same port (this gave me problems).
>>>>>
>>>>>
>>>>>
>>>>> Take what I said regarding my experience with FlexJS and Royale into
>>>>> account.
>>>>>
>>>>>
>>>>>
>>>>> Carlos
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> *From:* Fréderic Cox [mailto:coxfrederic@gmail.com]
>>>>> *Sent:* Sunday, January 14, 2018 4:01 PM
>>>>>
>>>>> *To:* users@royale.apache.org
>>>>> *Subject:* Re: RemoteObject
>>>>>
>>>>>
>>>>>
>>>>> Script tag was stripped from the post:
>>>>>
>>>>>
>>>>>
>>>>> import org.apache.royale.events.MouseEvent;
>>>>>
>>>>>                      import org.apache.royale.net.events.FaultEvent;
>>>>>
>>>>>                      import org.apache.royale.net.events.ResultEvent;
>>>>>
>>>>>
>>>>>
>>>>>                      protected function textbutton_clickHandler(event:
>>>>> org.apache.royale.events.MouseEvent):void
>>>>>
>>>>>                      {
>>>>>
>>>>>                            statusLabel.text = "calling.......";
>>>>>
>>>>>                            amfTestService.addEventListener("fault",
>>>>> amfTestService_faultHandler);
>>>>>
>>>>>                            amfTestService.addEventListener("result",
>>>>> amfTestService_resultHandler);
>>>>>
>>>>>                            amfTestService.send("getShippingMethods",
>>>>> []);
>>>>>
>>>>>                      }
>>>>>
>>>>>
>>>>>
>>>>>                      protected function amfTestService_faultHandler(ev
>>>>> ent:FaultEvent):void
>>>>>
>>>>>                      {
>>>>>
>>>>>                            statusLabel.text = "error!";
>>>>>
>>>>>                      }
>>>>>
>>>>>
>>>>>
>>>>>                      protected function amfTestService_resultHandler(e
>>>>> vent:ResultEvent):void
>>>>>
>>>>>                      {
>>>>>
>>>>>                            statusLabel.text = "result!";
>>>>>
>>>>>                      }
>>>>>
>>>>>
>>>>>
>>>>> none of the events are triggered ..URL is http://winkelbeheer.cityfas
>>>>> hion.be/amfphp/gateway.php
>>>>>
>>>>>
>>>>>
>>>>> On Fri, Jan 12, 2018 at 4:55 AM, Carlos Cruz <ca...@nbtbizcapital.com>
>>>>> wrote:
>>>>>
>>>>> I may be blind (and or ignorant as I'm more familiar with Flex) but
>>>>> where
>>>>> are you sending an AMF request? I don't see any code that sends a
>>>>> request to
>>>>> a service and invokes method.
>>>>>
>>>>>
>>>>> -----Original Message-----
>>>>> From: coxfrederic [mailto:coxfrederic@gmail.com]
>>>>> Sent: Thursday, January 11, 2018 9:09 PM
>>>>> To: users@royale.apache.org
>>>>> Subject: Re: RemoteObject
>>>>>
>>>>> <?xml version="1.0" encoding="utf-8"?>
>>>>>
>>>>> <js:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
>>>>>                    xmlns:js="library://ns.apache.org/royale/basic" >
>>>>>         <fx:Script>
>>>>>
>>>>>         </fx:Script>
>>>>>     <js:valuesImpl>
>>>>>         <js:SimpleCSSValuesImpl />
>>>>>     </js:valuesImpl>
>>>>>
>>>>>         <js:beads>
>>>>>                 <js:ClassAliasBead />
>>>>>                 <js:RemoteObject id="amfTestService"
>>>>>
>>>>> endPoint="http://winkelbeheer.cityfashion.be/amfphp/gateway.php"
>>>>>                                                  destination="Meta"
>>>>> source="Meta" />
>>>>>         </js:beads>
>>>>>
>>>>>     <js:initialView>
>>>>>         <js:View>
>>>>>                         <js:VGroup>
>>>>>                                 <js:Label id="statusLabel" text="Hello
>>>>> World!" />
>>>>>                                 <js:TextButton text="Get AMF data"
>>>>> click="textbutton_clickHandler(event)" />
>>>>>                         </js:VGroup>
>>>>>         </js:View>
>>>>>     </js:initialView>
>>>>> </js:Application>
>>>>>
>>>>>
>>>>> Any idea why I'm not getting a fault nor success event on this?
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Sent from: http://apache-royale-users.20374.n8.nabble.com/
>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> Carlos Rovira
>>>> http://about.me/carlosrovira
>>>>
>>>>
>>>
>>>
>>> --
>>>
>>> Piotr Zarzycki
>>>
>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>> <https://www.patreon.com/piotrzarzycki>*
>>>
>>
>>
>>
>> --
>> Carlos Rovira
>> http://about.me/carlosrovira
>>
>>
>
>
> --
>
> Piotr Zarzycki
>
> Patreon: *https://www.patreon.com/piotrzarzycki
> <https://www.patreon.com/piotrzarzycki>*
>

Re: RemoteObject

Posted by Carlos Rovira <ca...@apache.org>.
Hi Piotr,
right I only tested with java bakcend. But in theory backend should be
agnostic. AMF should work with whatever implementation out there (java,
php, .net, python, ...)
Maybe Frederick should start trying to make work the example we have in our
repo (java part and royale part). Maybe even something broke when we did
migration from flexjs to royale
don't know.
I must to revisit it at some time, but I'm very busy right now with lots of
fronts to reach that point.
I invite Frederic to get more involved in Royale, I think he can be a great
mate here! I assume there's more work to be done in AMF realms and he could
help with that :)

thanks



2018-02-15 17:15 GMT+01:00 Piotr Zarzycki <pi...@gmail.com>:

> Carlos,
>
> If I remember correctly there wasn't any test with AMFPHP, but rather with
> some JAVA sources yes ?
>
> Thanks,
> Piotr
>
>
> 2018-02-15 14:09 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>
>> Hi Piotr,
>>
>> Thanks, I installed the extension and now I'm not getting the CORS error
>> anymore.
>> I'm not getting any fault or result event triggered either....
>>
>> The endPoint set is
>> https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php
>>
>> This is correct, right? (I use this endpoint in Flex and that works fine)
>>
>>
>>    1. Request URL:
>>       https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php
>>       2. Request Method:
>>       OPTIONS
>>       3. Status Code:
>>       200 OK
>>       4. Remote Address:
>>       188.93.153.101:443
>>       5. Referrer Policy:
>>       no-referrer-when-downgrade
>>       1. Response Headersview source
>>       1. Connection:
>>       keep-alive
>>       2. Content-Encoding:
>>       gzip
>>       3. Content-Length:
>>       286
>>       4. Content-Type:
>>       text/html; charset=UTF-8
>>       5. Date:
>>       Thu, 15 Feb 2018 13:08:17 GMT
>>       6. Server:
>>       nginx
>>       7. Vary:
>>       Accept-Encoding
>>       2. Request Headersview source
>>       1. Accept:
>>       */*
>>       2. Accept-Encoding:
>>       gzip, deflate, br
>>       3. Accept-Language:
>>       en-GB,en-US;q=0.9,en;q=0.8
>>       4. Access-Control-Request-Headers:
>>       content-type
>>       5. Access-Control-Request-Method:
>>       POST
>>       6. Connection:
>>       keep-alive
>>       7. Host:
>>       clients.cityfashion.dev.exuvis.com
>>       8. Origin:
>>       null
>>       9. User-Agent:
>>       Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_3) AppleWebKit/537.36
>>       (KHTML, like Gecko) Chrome/64.0.3282.167 Safari/537.36
>>
>> Response is:
>>
>> <p>amfphp and this gateway are installed correctly. You may now connect
>> to this gateway from Flash.</p><p>Note: If you're reading an old tutorial,
>> it will tell you that you should see a download window instead of this
>> message. This confused people so this is the new behaviour starting from
>> amfphp 1.2.</p><p><a href='http://www.amfphp.org/docs'>View the amfphp
>> documentation</p><p><a href='browser'>Load the service browser</a></p><pre>
>>
>> Should I target a specific file with the JS version? Should the endPoint
>> be different?
>>
>> On Thu, Feb 15, 2018 at 12:07 PM, Piotr Zarzycki <
>> piotrzarzycki21@gmail.com> wrote:
>>
>>> Frederic,
>>>
>>> It looks like it is not problem with framework, but rather CORS issue.
>>> Maybe try to install this plugin [1] and add to the list your url.
>>>
>>> [1] https://chrome.google.com/webstore/detail/allow-control-
>>> allow-origi/nlfbmbojpeacfghkpbjhddihlkkiljbi?hl=en
>>>
>>> Piotr
>>>
>>> 2018-02-15 12:04 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>>>
>>>> For me it is still not working in latest release 0.9.1. I based my
>>>> example on the example in the SDK.
>>>>
>>>> <?xml version="1.0" encoding="utf-8"?>
>>>> <js:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
>>>> xmlns:js="library://ns.apache.org/royale/basic" applicationComplete=
>>>> "applicationCompleteHandler(event);">
>>>>
>>>>     <fx:Script>
>>>>         <![CDATA[
>>>>             import org.apache.royale.net.RemoteObject;
>>>>             import org.apache.royale.net.events.FaultEvent;
>>>>             import org.apache.royale.net.events.ResultEvent;
>>>>
>>>>             private function applicationCompleteHandler(evt:Event):void
>>>> {
>>>>                 testLabel.text = "Requesting from AMF";
>>>>                 service.send("getPackages", null);
>>>>             }
>>>>
>>>>             private function amfFaultHandler(evt:FaultEvent):void{
>>>>                 testLabel.text = "Fault in calling AMF";
>>>>             }
>>>>
>>>>             private function amfResultHandler(evt:ResultEvent):void{
>>>>                 testLabel.text = "Result received from AMF";
>>>>             }
>>>>         ]]>
>>>>     </fx:Script>
>>>>
>>>> <js:valuesImpl>
>>>> <js:SimpleCSSValuesImpl />
>>>> </js:valuesImpl>
>>>>
>>>>    <js:beads>
>>>> <js:ClassAliasBead />
>>>> <js:RemoteObject id="service" result="amfResultHandler(event)" fault=
>>>> "amfFaultHandler(event)"
>>>> endPoint = "https://winkelbeheer.cityfashion.be/amfphp/gateway.php"
>>>> destination = "Meta"
>>>> source = "Meta"/>
>>>> </js:beads>
>>>>
>>>> <js:initialView>
>>>> <js:View>
>>>> <js:Label id="testLabel" />
>>>> </js:View>
>>>> </js:initialView>
>>>> </js:Application>
>>>>
>>>>
>>>> It is not working and showing the following error in the browser:
>>>>
>>>> Failed to load https://winkelbeheer.cityfashion.be/amfphp/gateway.php:
>>>> Response to preflight request doesn't pass access control check: No
>>>> 'Access-Control-Allow-Origin' header is present on the requested resource.
>>>> Origin 'http://localhost' is therefore not allowed access.
>>>> Language.js:238 destination fault handler
>>>>
>>>>    1. {code: -1004, message: "Invalid response type.", detail: "Invalid
>>>>    XMLHttpRequest response status or type.", data: null}
>>>>       1. code:-1004
>>>>       2. data:null
>>>>       3. detail:"Invalid XMLHttpRequest response status or type."
>>>>       4. message:"Invalid response type."
>>>>       5. __proto__:Object
>>>>
>>>>
>>>>
>>>>
>>>> It is able to compile and run regardless of the errors in compile log:
>>>>
>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>> println
>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>> he/royale/reflection/AccessorDefinition.js:12: ERROR - required
>>>> "org.apache.royale.reflection.TypeDefinition" namespace not provided
>>>> yet
>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>
>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>> println
>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>> he/royale/reflection/AccessorDefinition.js:13: ERROR - required
>>>> "org.apache.royale.reflection.VariableDefinition" namespace not
>>>> provided yet
>>>> goog.require('org.apache.royale.reflection.VariableDefinition');
>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>
>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>> println
>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>> he/royale/reflection/MethodDefinition.js:14: ERROR - required
>>>> "org.apache.royale.reflection.TypeDefinition" namespace not provided
>>>> yet
>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>
>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>> println
>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>> he/royale/reflection/ParameterDefinition.js:13: ERROR- required
>>>> "org.apache.royale.reflection.TypeDefinition" namespace not provided
>>>> yet
>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>
>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>> println
>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>> he/royale/reflection/TypeDefinition.js:15: ERROR - required
>>>> "org.apache.royale.reflection.VariableDefinition" namespace not
>>>> provided yet
>>>> goog.require('org.apache.royale.reflection.VariableDefinition');
>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>
>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>> printSummary
>>>> WARNING: 5 error(s), 0 warning(s)
>>>> The project 'HelloRoyale' has been successfully compiled and optimized.
>>>> 4.566387 seconds
>>>>
>>>>
>>>> On Mon, Jan 15, 2018 at 7:38 PM, Piotr Zarzycki <
>>>> piotrzarzycki21@gmail.com> wrote:
>>>>
>>>>> Carlos,
>>>>>
>>>>> No problem. I have also couple of huge things related to Royale to do
>>>>> before my hand gets dirty with AMF! :) Unless someone urgently will needed.
>>>>> :)
>>>>>
>>>>> Thanks, Piotr
>>>>>
>>>>> 2018-01-15 19:27 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>>>>>
>>>>>> Hi Piotr,
>>>>>> I'll put this on my to do list, but have to do some things first.
>>>>>> thanks
>>>>>>
>>>>>> 2018-01-15 9:26 GMT+01:00 Piotr Zarzycki <pi...@gmail.com>:
>>>>>>
>>>>>>> Hi Carlos,
>>>>>>>
>>>>>>> Can you describe more how to setup those examples ? Could you add to
>>>>>>> RemoteObjectAMFTest README.md file where you describe steps. I would like
>>>>>>> to have AMF on my list for tests and improvements. Whenever I look into
>>>>>>> that I don't know how to proceed with it.
>>>>>>>
>>>>>>> Thanks, Piotr
>>>>>>>
>>>>>>> 2018-01-15 9:21 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>>>>>>>
>>>>>>>> Hi,
>>>>>>>>
>>>>>>>> there's an example that we get it working nicely at:
>>>>>>>>
>>>>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/
>>>>>>>> royale/RemoteObjectAMFTest
>>>>>>>>
>>>>>>>> you can use that as a starting point for your test
>>>>>>>>
>>>>>>>> As well a java web app that is used along that royale client
>>>>>>>> example is at:
>>>>>>>>
>>>>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/amf
>>>>>>>>
>>>>>>>> thanks
>>>>>>>>
>>>>>>>>
>>>>>>>> 2018-01-15 3:56 GMT+01:00 Carlos Cruz <ca...@nbtbizcapital.com>:
>>>>>>>>
>>>>>>>>> I have a lot of experience with Flex remoting and BlazeDS with
>>>>>>>>> Java, but with FlexJS and Royale I have none, but extrapolating from some
>>>>>>>>> JS tests I've done with AMF at this line: amfTestService.send("get
>>>>>>>>> ShippingMethods", []); you have to call a class in gateway.php
>>>>>>>>> and a method. Your request needs at least 3 properties.
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> I'm also assuming your JS file and gateway.php are in the same
>>>>>>>>> domain and same port (this gave me problems).
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Take what I said regarding my experience with FlexJS and Royale
>>>>>>>>> into account.
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Carlos
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> *From:* Fréderic Cox [mailto:coxfrederic@gmail.com]
>>>>>>>>> *Sent:* Sunday, January 14, 2018 4:01 PM
>>>>>>>>>
>>>>>>>>> *To:* users@royale.apache.org
>>>>>>>>> *Subject:* Re: RemoteObject
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Script tag was stripped from the post:
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> import org.apache.royale.events.MouseEvent;
>>>>>>>>>
>>>>>>>>>                      import org.apache.royale.net.events.F
>>>>>>>>> aultEvent;
>>>>>>>>>
>>>>>>>>>                      import org.apache.royale.net.events.R
>>>>>>>>> esultEvent;
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>                      protected function
>>>>>>>>> textbutton_clickHandler(event:org.apache.royale.events.Mouse
>>>>>>>>> Event):void
>>>>>>>>>
>>>>>>>>>                      {
>>>>>>>>>
>>>>>>>>>                            statusLabel.text = "calling.......";
>>>>>>>>>
>>>>>>>>>                            amfTestService.addEventListener("fault",
>>>>>>>>> amfTestService_faultHandler);
>>>>>>>>>
>>>>>>>>>                            amfTestService.addEventListener(
>>>>>>>>> "result", amfTestService_resultHandler);
>>>>>>>>>
>>>>>>>>>                            amfTestService.send("getShippi
>>>>>>>>> ngMethods", []);
>>>>>>>>>
>>>>>>>>>                      }
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>                      protected function
>>>>>>>>> amfTestService_faultHandler(event:FaultEvent):void
>>>>>>>>>
>>>>>>>>>                      {
>>>>>>>>>
>>>>>>>>>                            statusLabel.text = "error!";
>>>>>>>>>
>>>>>>>>>                      }
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>                      protected function
>>>>>>>>> amfTestService_resultHandler(event:ResultEvent):void
>>>>>>>>>
>>>>>>>>>                      {
>>>>>>>>>
>>>>>>>>>                            statusLabel.text = "result!";
>>>>>>>>>
>>>>>>>>>                      }
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> none of the events are triggered ..URL is
>>>>>>>>> http://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On Fri, Jan 12, 2018 at 4:55 AM, Carlos Cruz <
>>>>>>>>> carlos@nbtbizcapital.com> wrote:
>>>>>>>>>
>>>>>>>>> I may be blind (and or ignorant as I'm more familiar with Flex)
>>>>>>>>> but where
>>>>>>>>> are you sending an AMF request? I don't see any code that sends a
>>>>>>>>> request to
>>>>>>>>> a service and invokes method.
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> -----Original Message-----
>>>>>>>>> From: coxfrederic [mailto:coxfrederic@gmail.com]
>>>>>>>>> Sent: Thursday, January 11, 2018 9:09 PM
>>>>>>>>> To: users@royale.apache.org
>>>>>>>>> Subject: Re: RemoteObject
>>>>>>>>>
>>>>>>>>> <?xml version="1.0" encoding="utf-8"?>
>>>>>>>>>
>>>>>>>>> <js:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
>>>>>>>>>                    xmlns:js="library://ns.apache.org/royale/basic"
>>>>>>>>> >
>>>>>>>>>         <fx:Script>
>>>>>>>>>
>>>>>>>>>         </fx:Script>
>>>>>>>>>     <js:valuesImpl>
>>>>>>>>>         <js:SimpleCSSValuesImpl />
>>>>>>>>>     </js:valuesImpl>
>>>>>>>>>
>>>>>>>>>         <js:beads>
>>>>>>>>>                 <js:ClassAliasBead />
>>>>>>>>>                 <js:RemoteObject id="amfTestService"
>>>>>>>>>
>>>>>>>>> endPoint="http://winkelbeheer.cityfashion.be/amfphp/gateway.php"
>>>>>>>>>                                                  destination="Meta"
>>>>>>>>> source="Meta" />
>>>>>>>>>         </js:beads>
>>>>>>>>>
>>>>>>>>>     <js:initialView>
>>>>>>>>>         <js:View>
>>>>>>>>>                         <js:VGroup>
>>>>>>>>>                                 <js:Label id="statusLabel"
>>>>>>>>> text="Hello
>>>>>>>>> World!" />
>>>>>>>>>                                 <js:TextButton text="Get AMF data"
>>>>>>>>> click="textbutton_clickHandler(event)" />
>>>>>>>>>                         </js:VGroup>
>>>>>>>>>         </js:View>
>>>>>>>>>     </js:initialView>
>>>>>>>>> </js:Application>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Any idea why I'm not getting a fault nor success event on this?
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> Sent from: http://apache-royale-users.20374.n8.nabble.com/
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> --
>>>>>>>> Carlos Rovira
>>>>>>>> http://about.me/carlosrovira
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>>
>>>>>>> Piotr Zarzycki
>>>>>>>
>>>>>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>>>>>> <https://www.patreon.com/piotrzarzycki>*
>>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> Carlos Rovira
>>>>>> http://about.me/carlosrovira
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>> --
>>>>>
>>>>> Piotr Zarzycki
>>>>>
>>>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>>>> <https://www.patreon.com/piotrzarzycki>*
>>>>>
>>>>
>>>>
>>>
>>>
>>> --
>>>
>>> Piotr Zarzycki
>>>
>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>> <https://www.patreon.com/piotrzarzycki>*
>>>
>>
>>
>
>
> --
>
> Piotr Zarzycki
>
> Patreon: *https://www.patreon.com/piotrzarzycki
> <https://www.patreon.com/piotrzarzycki>*
>



-- 
Carlos Rovira
http://about.me/carlosrovira

Re: RemoteObject

Posted by Piotr Zarzycki <pi...@gmail.com>.
Carlos,

If I remember correctly there wasn't any test with AMFPHP, but rather with
some JAVA sources yes ?

Thanks,
Piotr


2018-02-15 14:09 GMT+01:00 Fréderic Cox <co...@gmail.com>:

> Hi Piotr,
>
> Thanks, I installed the extension and now I'm not getting the CORS error
> anymore.
> I'm not getting any fault or result event triggered either....
>
> The endPoint set is
> https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php
>
> This is correct, right? (I use this endpoint in Flex and that works fine)
>
>
>    1. Request URL:
>       https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php
>       2. Request Method:
>       OPTIONS
>       3. Status Code:
>       200 OK
>       4. Remote Address:
>       188.93.153.101:443
>       5. Referrer Policy:
>       no-referrer-when-downgrade
>       1. Response Headersview source
>       1. Connection:
>       keep-alive
>       2. Content-Encoding:
>       gzip
>       3. Content-Length:
>       286
>       4. Content-Type:
>       text/html; charset=UTF-8
>       5. Date:
>       Thu, 15 Feb 2018 13:08:17 GMT
>       6. Server:
>       nginx
>       7. Vary:
>       Accept-Encoding
>       2. Request Headersview source
>       1. Accept:
>       */*
>       2. Accept-Encoding:
>       gzip, deflate, br
>       3. Accept-Language:
>       en-GB,en-US;q=0.9,en;q=0.8
>       4. Access-Control-Request-Headers:
>       content-type
>       5. Access-Control-Request-Method:
>       POST
>       6. Connection:
>       keep-alive
>       7. Host:
>       clients.cityfashion.dev.exuvis.com
>       8. Origin:
>       null
>       9. User-Agent:
>       Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_3) AppleWebKit/537.36
>       (KHTML, like Gecko) Chrome/64.0.3282.167 Safari/537.36
>
> Response is:
>
> <p>amfphp and this gateway are installed correctly. You may now connect to
> this gateway from Flash.</p><p>Note: If you're reading an old tutorial, it
> will tell you that you should see a download window instead of this
> message. This confused people so this is the new behaviour starting from
> amfphp 1.2.</p><p><a href='http://www.amfphp.org/docs'>View the amfphp
> documentation</p><p><a href='browser'>Load the service browser</a></p><pre>
>
> Should I target a specific file with the JS version? Should the endPoint
> be different?
>
> On Thu, Feb 15, 2018 at 12:07 PM, Piotr Zarzycki <
> piotrzarzycki21@gmail.com> wrote:
>
>> Frederic,
>>
>> It looks like it is not problem with framework, but rather CORS issue.
>> Maybe try to install this plugin [1] and add to the list your url.
>>
>> [1] https://chrome.google.com/webstore/detail/allow-control-
>> allow-origi/nlfbmbojpeacfghkpbjhddihlkkiljbi?hl=en
>>
>> Piotr
>>
>> 2018-02-15 12:04 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>>
>>> For me it is still not working in latest release 0.9.1. I based my
>>> example on the example in the SDK.
>>>
>>> <?xml version="1.0" encoding="utf-8"?>
>>> <js:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
>>> xmlns:js="library://ns.apache.org/royale/basic" applicationComplete=
>>> "applicationCompleteHandler(event);">
>>>
>>>     <fx:Script>
>>>         <![CDATA[
>>>             import org.apache.royale.net.RemoteObject;
>>>             import org.apache.royale.net.events.FaultEvent;
>>>             import org.apache.royale.net.events.ResultEvent;
>>>
>>>             private function applicationCompleteHandler(evt:Event):void{
>>>                 testLabel.text = "Requesting from AMF";
>>>                 service.send("getPackages", null);
>>>             }
>>>
>>>             private function amfFaultHandler(evt:FaultEvent):void{
>>>                 testLabel.text = "Fault in calling AMF";
>>>             }
>>>
>>>             private function amfResultHandler(evt:ResultEvent):void{
>>>                 testLabel.text = "Result received from AMF";
>>>             }
>>>         ]]>
>>>     </fx:Script>
>>>
>>> <js:valuesImpl>
>>> <js:SimpleCSSValuesImpl />
>>> </js:valuesImpl>
>>>
>>>    <js:beads>
>>> <js:ClassAliasBead />
>>> <js:RemoteObject id="service" result="amfResultHandler(event)" fault=
>>> "amfFaultHandler(event)"
>>> endPoint = "https://winkelbeheer.cityfashion.be/amfphp/gateway.php"
>>> destination = "Meta"
>>> source = "Meta"/>
>>> </js:beads>
>>>
>>> <js:initialView>
>>> <js:View>
>>> <js:Label id="testLabel" />
>>> </js:View>
>>> </js:initialView>
>>> </js:Application>
>>>
>>>
>>> It is not working and showing the following error in the browser:
>>>
>>> Failed to load https://winkelbeheer.cityfashion.be/amfphp/gateway.php:
>>> Response to preflight request doesn't pass access control check: No
>>> 'Access-Control-Allow-Origin' header is present on the requested resource.
>>> Origin 'http://localhost' is therefore not allowed access.
>>> Language.js:238 destination fault handler
>>>
>>>    1. {code: -1004, message: "Invalid response type.", detail: "Invalid
>>>    XMLHttpRequest response status or type.", data: null}
>>>       1. code:-1004
>>>       2. data:null
>>>       3. detail:"Invalid XMLHttpRequest response status or type."
>>>       4. message:"Invalid response type."
>>>       5. __proto__:Object
>>>
>>>
>>>
>>>
>>> It is able to compile and run regardless of the errors in compile log:
>>>
>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>> println
>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>> he/royale/reflection/AccessorDefinition.js:12: ERROR - required
>>> "org.apache.royale.reflection.TypeDefinition" namespace not provided yet
>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>
>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>> println
>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>> he/royale/reflection/AccessorDefinition.js:13: ERROR - required
>>> "org.apache.royale.reflection.VariableDefinition" namespace not
>>> provided yet
>>> goog.require('org.apache.royale.reflection.VariableDefinition');
>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>
>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>> println
>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>> he/royale/reflection/MethodDefinition.js:14: ERROR - required
>>> "org.apache.royale.reflection.TypeDefinition" namespace not provided yet
>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>
>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>> println
>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>> he/royale/reflection/ParameterDefinition.js:13: ERROR- required
>>> "org.apache.royale.reflection.TypeDefinition" namespace not provided yet
>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>
>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>> println
>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>> he/royale/reflection/TypeDefinition.js:15: ERROR - required
>>> "org.apache.royale.reflection.VariableDefinition" namespace not
>>> provided yet
>>> goog.require('org.apache.royale.reflection.VariableDefinition');
>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>
>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>> printSummary
>>> WARNING: 5 error(s), 0 warning(s)
>>> The project 'HelloRoyale' has been successfully compiled and optimized.
>>> 4.566387 seconds
>>>
>>>
>>> On Mon, Jan 15, 2018 at 7:38 PM, Piotr Zarzycki <
>>> piotrzarzycki21@gmail.com> wrote:
>>>
>>>> Carlos,
>>>>
>>>> No problem. I have also couple of huge things related to Royale to do
>>>> before my hand gets dirty with AMF! :) Unless someone urgently will needed.
>>>> :)
>>>>
>>>> Thanks, Piotr
>>>>
>>>> 2018-01-15 19:27 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>>>>
>>>>> Hi Piotr,
>>>>> I'll put this on my to do list, but have to do some things first.
>>>>> thanks
>>>>>
>>>>> 2018-01-15 9:26 GMT+01:00 Piotr Zarzycki <pi...@gmail.com>:
>>>>>
>>>>>> Hi Carlos,
>>>>>>
>>>>>> Can you describe more how to setup those examples ? Could you add to
>>>>>> RemoteObjectAMFTest README.md file where you describe steps. I would like
>>>>>> to have AMF on my list for tests and improvements. Whenever I look into
>>>>>> that I don't know how to proceed with it.
>>>>>>
>>>>>> Thanks, Piotr
>>>>>>
>>>>>> 2018-01-15 9:21 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>>>>>>
>>>>>>> Hi,
>>>>>>>
>>>>>>> there's an example that we get it working nicely at:
>>>>>>>
>>>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/
>>>>>>> royale/RemoteObjectAMFTest
>>>>>>>
>>>>>>> you can use that as a starting point for your test
>>>>>>>
>>>>>>> As well a java web app that is used along that royale client example
>>>>>>> is at:
>>>>>>>
>>>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/amf
>>>>>>>
>>>>>>> thanks
>>>>>>>
>>>>>>>
>>>>>>> 2018-01-15 3:56 GMT+01:00 Carlos Cruz <ca...@nbtbizcapital.com>:
>>>>>>>
>>>>>>>> I have a lot of experience with Flex remoting and BlazeDS with
>>>>>>>> Java, but with FlexJS and Royale I have none, but extrapolating from some
>>>>>>>> JS tests I've done with AMF at this line: amfTestService.send("get
>>>>>>>> ShippingMethods", []); you have to call a class in gateway.php and
>>>>>>>> a method. Your request needs at least 3 properties.
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> I'm also assuming your JS file and gateway.php are in the same
>>>>>>>> domain and same port (this gave me problems).
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> Take what I said regarding my experience with FlexJS and Royale
>>>>>>>> into account.
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> Carlos
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> *From:* Fréderic Cox [mailto:coxfrederic@gmail.com]
>>>>>>>> *Sent:* Sunday, January 14, 2018 4:01 PM
>>>>>>>>
>>>>>>>> *To:* users@royale.apache.org
>>>>>>>> *Subject:* Re: RemoteObject
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> Script tag was stripped from the post:
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> import org.apache.royale.events.MouseEvent;
>>>>>>>>
>>>>>>>>                      import org.apache.royale.net.events.F
>>>>>>>> aultEvent;
>>>>>>>>
>>>>>>>>                      import org.apache.royale.net.events.R
>>>>>>>> esultEvent;
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>                      protected function
>>>>>>>> textbutton_clickHandler(event:org.apache.royale.events.MouseEvent):
>>>>>>>> void
>>>>>>>>
>>>>>>>>                      {
>>>>>>>>
>>>>>>>>                            statusLabel.text = "calling.......";
>>>>>>>>
>>>>>>>>                            amfTestService.addEventListener("fault",
>>>>>>>> amfTestService_faultHandler);
>>>>>>>>
>>>>>>>>                            amfTestService.addEventListener("result",
>>>>>>>> amfTestService_resultHandler);
>>>>>>>>
>>>>>>>>                            amfTestService.send("getShippingMethods",
>>>>>>>> []);
>>>>>>>>
>>>>>>>>                      }
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>                      protected function
>>>>>>>> amfTestService_faultHandler(event:FaultEvent):void
>>>>>>>>
>>>>>>>>                      {
>>>>>>>>
>>>>>>>>                            statusLabel.text = "error!";
>>>>>>>>
>>>>>>>>                      }
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>                      protected function
>>>>>>>> amfTestService_resultHandler(event:ResultEvent):void
>>>>>>>>
>>>>>>>>                      {
>>>>>>>>
>>>>>>>>                            statusLabel.text = "result!";
>>>>>>>>
>>>>>>>>                      }
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> none of the events are triggered ..URL is
>>>>>>>> http://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> On Fri, Jan 12, 2018 at 4:55 AM, Carlos Cruz <
>>>>>>>> carlos@nbtbizcapital.com> wrote:
>>>>>>>>
>>>>>>>> I may be blind (and or ignorant as I'm more familiar with Flex) but
>>>>>>>> where
>>>>>>>> are you sending an AMF request? I don't see any code that sends a
>>>>>>>> request to
>>>>>>>> a service and invokes method.
>>>>>>>>
>>>>>>>>
>>>>>>>> -----Original Message-----
>>>>>>>> From: coxfrederic [mailto:coxfrederic@gmail.com]
>>>>>>>> Sent: Thursday, January 11, 2018 9:09 PM
>>>>>>>> To: users@royale.apache.org
>>>>>>>> Subject: Re: RemoteObject
>>>>>>>>
>>>>>>>> <?xml version="1.0" encoding="utf-8"?>
>>>>>>>>
>>>>>>>> <js:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
>>>>>>>>                    xmlns:js="library://ns.apache.org/royale/basic"
>>>>>>>> >
>>>>>>>>         <fx:Script>
>>>>>>>>
>>>>>>>>         </fx:Script>
>>>>>>>>     <js:valuesImpl>
>>>>>>>>         <js:SimpleCSSValuesImpl />
>>>>>>>>     </js:valuesImpl>
>>>>>>>>
>>>>>>>>         <js:beads>
>>>>>>>>                 <js:ClassAliasBead />
>>>>>>>>                 <js:RemoteObject id="amfTestService"
>>>>>>>>
>>>>>>>> endPoint="http://winkelbeheer.cityfashion.be/amfphp/gateway.php"
>>>>>>>>                                                  destination="Meta"
>>>>>>>> source="Meta" />
>>>>>>>>         </js:beads>
>>>>>>>>
>>>>>>>>     <js:initialView>
>>>>>>>>         <js:View>
>>>>>>>>                         <js:VGroup>
>>>>>>>>                                 <js:Label id="statusLabel"
>>>>>>>> text="Hello
>>>>>>>> World!" />
>>>>>>>>                                 <js:TextButton text="Get AMF data"
>>>>>>>> click="textbutton_clickHandler(event)" />
>>>>>>>>                         </js:VGroup>
>>>>>>>>         </js:View>
>>>>>>>>     </js:initialView>
>>>>>>>> </js:Application>
>>>>>>>>
>>>>>>>>
>>>>>>>> Any idea why I'm not getting a fault nor success event on this?
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> --
>>>>>>>> Sent from: http://apache-royale-users.20374.n8.nabble.com/
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> Carlos Rovira
>>>>>>> http://about.me/carlosrovira
>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>>
>>>>>> Piotr Zarzycki
>>>>>>
>>>>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>>>>> <https://www.patreon.com/piotrzarzycki>*
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Carlos Rovira
>>>>> http://about.me/carlosrovira
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>>
>>>> Piotr Zarzycki
>>>>
>>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>>> <https://www.patreon.com/piotrzarzycki>*
>>>>
>>>
>>>
>>
>>
>> --
>>
>> Piotr Zarzycki
>>
>> Patreon: *https://www.patreon.com/piotrzarzycki
>> <https://www.patreon.com/piotrzarzycki>*
>>
>
>


-- 

Piotr Zarzycki

Patreon: *https://www.patreon.com/piotrzarzycki
<https://www.patreon.com/piotrzarzycki>*

Re: RemoteObject

Posted by Piotr Zarzycki <pi...@gmail.com>.
Frederic,

Cool! That is very helpful! :)

Thanks, Piotr

2018-02-16 20:13 GMT+01:00 Fréderic Cox <co...@gmail.com>:

> Hi Piotr, I updated https://github.com/apache/royale-asjs/issues/119
> which now includes sample code which is working in Flex 4.16 AIR 27. The
> code should be almost identical to the royale sample.
>
> Please let me know if there is anything else I can do
>
> On Fri, Feb 16, 2018 at 3:59 PM, Piotr Zarzycki <piotrzarzycki21@gmail.com
> > wrote:
>
>> Frederic,
>>
>> Could you share some hello world implementation of AMFPHP along with
>> Hello World app in Flex ? I may also look into that and compare the
>> results. Just don't want to waste time on setup things to prepare AMFPHP
>> stuff. Do you have such things ?
>>
>> Thanks, Piotr
>>
>>
>> 2018-02-16 15:57 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>>
>>> Hi Carlos,
>>>
>>> Sure I’ll see what I can do. Feel I have lots to leatn about Royale and
>>> AMF (it just works with Flash/AIR so not up to date about the inner
>>> workings).
>>>
>>> I’ll try to test the examples over the weekend. Do you think the AMFPHP
>>> version could be an issue or is it assumed to work in Royale if it works in
>>> Flex?
>>>
>>> Verstuurd vanaf mijn iPhone
>>>
>>> Op 16 feb. 2018 om 12:28 heeft Carlos Rovira <ca...@apache.org>
>>> het volgende geschreven:
>>>
>>> Hi Frederic,
>>> thanks for filling this and take a look into AMF!
>>> Hope you could help us a bit with this.
>>>
>>> 2018-02-16 0:21 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>>>
>>>> Hi Alex,
>>>>
>>>> I created https://github.com/apache/royale-asjs/issues/119, hope that
>>>> is in the correct place and with more readable mark-up.
>>>>
>>>> Regards,
>>>>
>>>> Fréderic
>>>>
>>>> On Thu, Feb 15, 2018 at 8:57 PM, Alex Harui <ah...@adobe.com> wrote:
>>>>
>>>>> Hi Frederic,
>>>>>
>>>>> Where is this output you posted coming from, a network monitor?  It
>>>>> was too hard to read, so please create a bug report on GitHub and post it
>>>>> there.
>>>>>
>>>>> You might be able to use a network monitor to compare what Flex sent
>>>>> vs what Royale is sending.  What does your Flex usage of RemoteObject look
>>>>> like?
>>>>>
>>>>> HTH,
>>>>> -Alex
>>>>>
>>>>> From: Fréderic Cox <co...@gmail.com>
>>>>> Reply-To: "users@royale.apache.org" <us...@royale.apache.org>
>>>>> Date: Thursday, February 15, 2018 at 5:09 AM
>>>>> To: "users@royale.apache.org" <us...@royale.apache.org>
>>>>> Subject: Re: RemoteObject
>>>>>
>>>>> Hi Piotr,
>>>>>
>>>>> Thanks, I installed the extension and now I'm not getting the CORS
>>>>> error anymore.
>>>>> I'm not getting any fault or result event triggered either....
>>>>>
>>>>> The endPoint set is
>>>>> https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php
>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fclients.cityfashion.dev.exuvis.com%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=67VMfKVGZo%2BarMstlt%2BZbX5OdTomYDQNSgM07ycK%2Bvc%3D&reserved=0>
>>>>>
>>>>> This is correct, right? (I use this endpoint in Flex and that works
>>>>> fine)
>>>>>
>>>>>
>>>>>    1. Request URL:
>>>>>       https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php
>>>>>       <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fclients.cityfashion.dev.exuvis.com%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=67VMfKVGZo%2BarMstlt%2BZbX5OdTomYDQNSgM07ycK%2Bvc%3D&reserved=0>
>>>>>       2. Request Method:
>>>>>       OPTIONS
>>>>>       3. Status Code:
>>>>>       200 OK
>>>>>       4. Remote Address:
>>>>>       188.93.153.101:443
>>>>>       <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2F188.93.153.101%3A443&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=UWqG%2BqQTcL1fTnck9i5BPXmrn3ZlgRf8XCPpQ8EcJrE%3D&reserved=0>
>>>>>       5. Referrer Policy:
>>>>>       no-referrer-when-downgrade
>>>>>       1. Response Headersview source
>>>>>       1. Connection:
>>>>>       keep-alive
>>>>>       2. Content-Encoding:
>>>>>       gzip
>>>>>       3. Content-Length:
>>>>>       286
>>>>>       4. Content-Type:
>>>>>       text/html; charset=UTF-8
>>>>>       5. Date:
>>>>>       Thu, 15 Feb 2018 13:08:17 GMT
>>>>>       6. Server:
>>>>>       nginx
>>>>>       7. Vary:
>>>>>       Accept-Encoding
>>>>>       2. Request Headersview source
>>>>>       1. Accept:
>>>>>       */*
>>>>>       2. Accept-Encoding:
>>>>>       gzip, deflate, br
>>>>>       3. Accept-Language:
>>>>>       en-GB,en-US;q=0.9,en;q=0.8
>>>>>       4. Access-Control-Request-Headers:
>>>>>       content-type
>>>>>       5. Access-Control-Request-Method:
>>>>>       POST
>>>>>       6. Connection:
>>>>>       keep-alive
>>>>>       7. Host:
>>>>>       clients.cityfashion.dev.exuvis.com
>>>>>       <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fclients.cityfashion.dev.exuvis.com&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=%2BiTohXW1uaTpydtAlGWa0leTvEQKK2Wg6XtN%2FqQ73%2F0%3D&reserved=0>
>>>>>       8. Origin:
>>>>>       null
>>>>>       9. User-Agent:
>>>>>       Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_3)
>>>>>       AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.167 Safari/537.36
>>>>>
>>>>> Response is:
>>>>>
>>>>> <p>amfphp and this gateway are installed correctly. You may now
>>>>> connect to this gateway from Flash.</p><p>Note: If you're reading an old
>>>>> tutorial, it will tell you that you should see a download window instead of
>>>>> this message. This confused people so this is the new behaviour starting
>>>>> from amfphp 1.2.</p><p><a href='http://www.amfphp.org/docs
>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.amfphp.org%2Fdocs&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=%2FGtfS6iuQCrcoifQ5pUOXPJ0JJZcOQaMyYsscjKzA9I%3D&reserved=0>'>View
>>>>> the amfphp documentation</p><p><a href='browser'>Load the service
>>>>> browser</a></p><pre>
>>>>>
>>>>> Should I target a specific file with the JS version? Should the
>>>>> endPoint be different?
>>>>>
>>>>> On Thu, Feb 15, 2018 at 12:07 PM, Piotr Zarzycki <
>>>>> piotrzarzycki21@gmail.com> wrote:
>>>>>
>>>>>> Frederic,
>>>>>>
>>>>>> It looks like it is not problem with framework, but rather CORS
>>>>>> issue. Maybe try to install this plugin [1] and add to the list your url.
>>>>>>
>>>>>> [1] https://chrome.google.com/webstore/detail/allow-control-
>>>>>> allow-origi/nlfbmbojpeacfghkpbjhddihlkkiljbi?hl=en
>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fchrome.google.com%2Fwebstore%2Fdetail%2Fallow-control-allow-origi%2Fnlfbmbojpeacfghkpbjhddihlkkiljbi%3Fhl%3Den&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=CbZH3KQcH0oGU%2FbnBtyVp%2B9zeqDEUcK9Y6UFd0BIESM%3D&reserved=0>
>>>>>>
>>>>>> Piotr
>>>>>>
>>>>>> 2018-02-15 12:04 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>>>>>>
>>>>>>> For me it is still not working in latest release 0.9.1. I based my
>>>>>>> example on the example in the SDK.
>>>>>>>
>>>>>>> <?xml version="1.0" encoding="utf-8"?>
>>>>>>> <js:Applicationxmlns:fx="http://ns.adobe.com/mxml/2009
>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.adobe.com%2Fmxml%2F2009&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7cSxKCospCIpbkKY4F%2Fp5lsHBH%2BPFp5Vny2ftXWmL5A%3D&reserved=0>
>>>>>>> "
>>>>>>> xmlns:js="library://ns.apache.org/royale/basic
>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.apache.org%2Froyale%2Fbasic&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=D%2FBslvPtV9pNNjpoS4KCQlYHB8ArUYEIXCXuAVoNgYM%3D&reserved=0>
>>>>>>> "applicationComplete="applicationCompleteHandler(event);">
>>>>>>>
>>>>>>>     <fx:Script>
>>>>>>>         <![CDATA[
>>>>>>>             import org.apache.royale.net
>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Forg.apache.royale.net&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=ATrXbo2PLqz1dNeyvxVu89zy3yaKPxwIwQm9tSG7ybs%3D&reserved=0>
>>>>>>> .RemoteObject;
>>>>>>>             import org.apache.royale.net.events.FaultEvent;
>>>>>>>             import org.apache.royale.net.events.ResultEvent;
>>>>>>>
>>>>>>>             privatefunctionapplicationCompleteHandler(evt:Event):
>>>>>>> void{
>>>>>>>                 testLabel.text = "Requesting from AMF";
>>>>>>>                 service.send("getPackages", null);
>>>>>>>             }
>>>>>>>
>>>>>>>             privatefunctionamfFaultHandler(evt:FaultEvent):void{
>>>>>>>                 testLabel.text = "Fault in calling AMF";
>>>>>>>             }
>>>>>>>
>>>>>>>             privatefunctionamfResultHandler(evt:ResultEvent):void{
>>>>>>>                 testLabel.text = "Result received from AMF";
>>>>>>>             }
>>>>>>>         ]]>
>>>>>>>     </fx:Script>
>>>>>>>
>>>>>>> <js:valuesImpl>
>>>>>>> <js:SimpleCSSValuesImpl />
>>>>>>> </js:valuesImpl>
>>>>>>>
>>>>>>>    <js:beads>
>>>>>>> <js:ClassAliasBead />
>>>>>>> <js:RemoteObjectid="service"result="amfResultHandler(event)"fault=
>>>>>>> "amfFaultHandler(event)"
>>>>>>> endPoint = "https://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=mARoGAlKZYBWmNOBwqTpTRYkqG%2Fk0cvrHwR5kgbfNFY%3D&reserved=0>
>>>>>>> "
>>>>>>> destination = "Meta"
>>>>>>> source = "Meta"/>
>>>>>>> </js:beads>
>>>>>>>
>>>>>>> <js:initialView>
>>>>>>> <js:View>
>>>>>>> <js:Labelid="testLabel" />
>>>>>>> </js:View>
>>>>>>> </js:initialView>
>>>>>>> </js:Application>
>>>>>>>
>>>>>>>
>>>>>>> It is not working and showing the following error in the browser:
>>>>>>>
>>>>>>> Failed to load https://winkelbeheer.cityfashi
>>>>>>> on.be/amfphp/gateway.php
>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=mARoGAlKZYBWmNOBwqTpTRYkqG%2Fk0cvrHwR5kgbfNFY%3D&reserved=0>:
>>>>>>> Response to preflight request doesn't pass access control check: No
>>>>>>> 'Access-Control-Allow-Origin' header is present on the requested resource.
>>>>>>> Origin 'http://localhost' is therefore not allowed access.
>>>>>>> Language.js:238destination fault handler
>>>>>>>
>>>>>>>    1. {code: -1004, message: "Invalid response type.", detail: "Invalid
>>>>>>>    XMLHttpRequest response status or type.", data: null}
>>>>>>>       1. code:-1004
>>>>>>>       2. data:null
>>>>>>>       3. detail:"Invalid XMLHttpRequest response status or type."
>>>>>>>       4. message:"Invalid response type."
>>>>>>>       5. __proto__:Object
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> It is able to compile and run regardless of the errors in compile
>>>>>>> log:
>>>>>>>
>>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>>> println
>>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>>> he/royale/reflection/AccessorDefinition.js:12: ERROR - required
>>>>>>> "org.apache.royale.reflection.TypeDefinition" namespace not
>>>>>>> provided yet
>>>>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>>
>>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>>> println
>>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>>> he/royale/reflection/AccessorDefinition.js:13: ERROR - required
>>>>>>> "org.apache.royale.reflection.VariableDefinition" namespace not
>>>>>>> provided yet
>>>>>>> goog.require('org.apache.royale.reflection.VariableDefinition');
>>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>>
>>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>>> println
>>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>>> he/royale/reflection/MethodDefinition.js:14: ERROR - required
>>>>>>> "org.apache.royale.reflection.TypeDefinition" namespace not
>>>>>>> provided yet
>>>>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>>
>>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>>> println
>>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>>> he/royale/reflection/ParameterDefinition.js:13: ERROR- required
>>>>>>> "org.apache.royale.reflection.TypeDefinition" namespace not
>>>>>>> provided yet
>>>>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>>
>>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>>> println
>>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>>> he/royale/reflection/TypeDefinition.js:15: ERROR - required
>>>>>>> "org.apache.royale.reflection.VariableDefinition" namespace not
>>>>>>> provided yet
>>>>>>> goog.require('org.apache.royale.reflection.VariableDefinition');
>>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>>
>>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>>> printSummary
>>>>>>> WARNING: 5 error(s), 0 warning(s)
>>>>>>> The project 'HelloRoyale' has been successfully compiled and
>>>>>>> optimized.
>>>>>>> 4.566387 seconds
>>>>>>>
>>>>>>>
>>>>>>> On Mon, Jan 15, 2018 at 7:38 PM, Piotr Zarzycki <
>>>>>>> piotrzarzycki21@gmail.com> wrote:
>>>>>>>
>>>>>>>> Carlos,
>>>>>>>>
>>>>>>>> No problem. I have also couple of huge things related to Royale to
>>>>>>>> do before my hand gets dirty with AMF! :) Unless someone urgently will
>>>>>>>> needed. :)
>>>>>>>>
>>>>>>>> Thanks, Piotr
>>>>>>>>
>>>>>>>> 2018-01-15 19:27 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>>>>>>>>
>>>>>>>>> Hi Piotr,
>>>>>>>>> I'll put this on my to do list, but have to do some things first.
>>>>>>>>> thanks
>>>>>>>>>
>>>>>>>>> 2018-01-15 9:26 GMT+01:00 Piotr Zarzycki <
>>>>>>>>> piotrzarzycki21@gmail.com>:
>>>>>>>>>
>>>>>>>>>> Hi Carlos,
>>>>>>>>>>
>>>>>>>>>> Can you describe more how to setup those examples ? Could you add
>>>>>>>>>> to RemoteObjectAMFTest README.md file where you describe steps. I would
>>>>>>>>>> like to have AMF on my list for tests and improvements. Whenever I look
>>>>>>>>>> into that I don't know how to proceed with it.
>>>>>>>>>>
>>>>>>>>>> Thanks, Piotr
>>>>>>>>>>
>>>>>>>>>> 2018-01-15 9:21 GMT+01:00 Carlos Rovira <ca...@apache.org>
>>>>>>>>>> :
>>>>>>>>>>
>>>>>>>>>>> Hi,
>>>>>>>>>>>
>>>>>>>>>>> there's an example that we get it working nicely at:
>>>>>>>>>>>
>>>>>>>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/
>>>>>>>>>>> royale/RemoteObjectAMFTest
>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Ftree%2Fdevelop%2Fexamples%2Froyale%2FRemoteObjectAMFTest&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7kdc48rEQiaI4Qp%2BBdfBcGPxddZIYrTUXrQ%2BN2u4tto%3D&reserved=0>
>>>>>>>>>>>
>>>>>>>>>>> you can use that as a starting point for your test
>>>>>>>>>>>
>>>>>>>>>>> As well a java web app that is used along that royale client
>>>>>>>>>>> example is at:
>>>>>>>>>>>
>>>>>>>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/amf
>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Ftree%2Fdevelop%2Fexamples%2Famf&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=PW4DYIeW4PetVe6BdFYjxFeAjCrqofPYtdbRTnJ4xjk%3D&reserved=0>
>>>>>>>>>>>
>>>>>>>>>>> thanks
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> 2018-01-15 3:56 GMT+01:00 Carlos Cruz <ca...@nbtbizcapital.com>
>>>>>>>>>>> :
>>>>>>>>>>>
>>>>>>>>>>>> I have a lot of experience with Flex remoting and BlazeDS with
>>>>>>>>>>>> Java, but with FlexJS and Royale I have none, but extrapolating from some
>>>>>>>>>>>> JS tests I've done with AMF at this line: amfTestService.send(
>>>>>>>>>>>> "getShippingMethods", []); you have to call a class in
>>>>>>>>>>>> gateway.php and a method. Your request needs at least 3 properties.
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> I'm also assuming your JS file and gateway.php are in the same
>>>>>>>>>>>> domain and same port (this gave me problems).
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Take what I said regarding my experience with FlexJS and Royale
>>>>>>>>>>>> into account.
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Carlos
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> *From:* Fréderic Cox [mailto:coxfrederic@gmail.com]
>>>>>>>>>>>> *Sent:* Sunday, January 14, 2018 4:01 PM
>>>>>>>>>>>>
>>>>>>>>>>>> *To:* users@royale.apache.org
>>>>>>>>>>>> *Subject:* Re: RemoteObject
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Script tag was stripped from the post:
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> import org.apache.royale.events.MouseEvent;
>>>>>>>>>>>>
>>>>>>>>>>>>                      import org.apache.royale.net.events.F
>>>>>>>>>>>> aultEvent;
>>>>>>>>>>>>
>>>>>>>>>>>>                      import org.apache.royale.net.events.R
>>>>>>>>>>>> esultEvent;
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>                      protectedfunction
>>>>>>>>>>>> textbutton_clickHandler(event:org.apache.royale.events.Mouse
>>>>>>>>>>>> Event):void
>>>>>>>>>>>>
>>>>>>>>>>>>                      {
>>>>>>>>>>>>
>>>>>>>>>>>>                            statusLabel.text = "calling.......";
>>>>>>>>>>>>
>>>>>>>>>>>>                            amfTestService.addEventListener(
>>>>>>>>>>>> "fault", amfTestService_faultHandler);
>>>>>>>>>>>>
>>>>>>>>>>>>                            amfTestService.addEventListener(
>>>>>>>>>>>> "result", amfTestService_resultHandler);
>>>>>>>>>>>>
>>>>>>>>>>>>                            amfTestService.send("getShippi
>>>>>>>>>>>> ngMethods", []);
>>>>>>>>>>>>
>>>>>>>>>>>>                      }
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>                      protectedfunction
>>>>>>>>>>>> amfTestService_faultHandler(event:FaultEvent):void
>>>>>>>>>>>>
>>>>>>>>>>>>                      {
>>>>>>>>>>>>
>>>>>>>>>>>>                            statusLabel.text = "error!";
>>>>>>>>>>>>
>>>>>>>>>>>>                      }
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>                      protectedfunction
>>>>>>>>>>>> amfTestService_resultHandler(event:ResultEvent):void
>>>>>>>>>>>>
>>>>>>>>>>>>                      {
>>>>>>>>>>>>
>>>>>>>>>>>>                            statusLabel.text = "result!";
>>>>>>>>>>>>
>>>>>>>>>>>>                      }
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> none of the events are triggered ..URL is
>>>>>>>>>>>> http://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=EJDBQBL83yBhDn%2BWWgCCVyw0N3tnakhZ7UdEt4JFNaY%3D&reserved=0>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> On Fri, Jan 12, 2018 at 4:55 AM, Carlos Cruz <
>>>>>>>>>>>> carlos@nbtbizcapital.com> wrote:
>>>>>>>>>>>>
>>>>>>>>>>>> I may be blind (and or ignorant as I'm more familiar with Flex)
>>>>>>>>>>>> but where
>>>>>>>>>>>> are you sending an AMF request? I don't see any code that sends
>>>>>>>>>>>> a request to
>>>>>>>>>>>> a service and invokes method.
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> -----Original Message-----
>>>>>>>>>>>> From: coxfrederic [mailto:coxfrederic@gmail.com]
>>>>>>>>>>>> Sent: Thursday, January 11, 2018 9:09 PM
>>>>>>>>>>>> To: users@royale.apache.org
>>>>>>>>>>>> Subject: Re: RemoteObject
>>>>>>>>>>>>
>>>>>>>>>>>> <?xml version="1.0" encoding="utf-8"?>
>>>>>>>>>>>>
>>>>>>>>>>>> <js:Application xmlns:fx="http://ns.adobe.com/mxml/2009
>>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.adobe.com%2Fmxml%2F2009&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7cSxKCospCIpbkKY4F%2Fp5lsHBH%2BPFp5Vny2ftXWmL5A%3D&reserved=0>
>>>>>>>>>>>> "
>>>>>>>>>>>>                    xmlns:js="library://ns.apache
>>>>>>>>>>>> .org/royale/basic
>>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.apache.org%2Froyale%2Fbasic&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=D%2FBslvPtV9pNNjpoS4KCQlYHB8ArUYEIXCXuAVoNgYM%3D&reserved=0>"
>>>>>>>>>>>> >
>>>>>>>>>>>>         <fx:Script>
>>>>>>>>>>>>
>>>>>>>>>>>>         </fx:Script>
>>>>>>>>>>>>     <js:valuesImpl>
>>>>>>>>>>>>         <js:SimpleCSSValuesImpl />
>>>>>>>>>>>>     </js:valuesImpl>
>>>>>>>>>>>>
>>>>>>>>>>>>         <js:beads>
>>>>>>>>>>>>                 <js:ClassAliasBead />
>>>>>>>>>>>>                 <js:RemoteObject id="amfTestService"
>>>>>>>>>>>>
>>>>>>>>>>>> endPoint="http://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=EJDBQBL83yBhDn%2BWWgCCVyw0N3tnakhZ7UdEt4JFNaY%3D&reserved=0>
>>>>>>>>>>>> "
>>>>>>>>>>>>
>>>>>>>>>>>>  destination="Meta"
>>>>>>>>>>>> source="Meta" />
>>>>>>>>>>>>         </js:beads>
>>>>>>>>>>>>
>>>>>>>>>>>>     <js:initialView>
>>>>>>>>>>>>         <js:View>
>>>>>>>>>>>>                         <js:VGroup>
>>>>>>>>>>>>                                 <js:Label id="statusLabel"
>>>>>>>>>>>> text="Hello
>>>>>>>>>>>> World!" />
>>>>>>>>>>>>                                 <js:TextButton text="Get AMF
>>>>>>>>>>>> data"
>>>>>>>>>>>> click="textbutton_clickHandler(event)" />
>>>>>>>>>>>>                         </js:VGroup>
>>>>>>>>>>>>         </js:View>
>>>>>>>>>>>>     </js:initialView>
>>>>>>>>>>>> </js:Application>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Any idea why I'm not getting a fault nor success event on this?
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> --
>>>>>>>>>>>> Sent from: http://apache-royale-users.20374.n8.nabble.com/
>>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fapache-royale-users.20374.n8.nabble.com%2F&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=xvY8nK1QKlWduh6p5x8y19jm%2Br60PSFVlNdi6TRsPmw%3D&reserved=0>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> --
>>>>>>>>>>> Carlos Rovira
>>>>>>>>>>> http://about.me/carlosrovira
>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fabout.me%2Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=55MSUXBM2zE5U0csgV1harcuXvKyZ2gd%2BO%2FmD7hjJ50%3D&reserved=0>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> --
>>>>>>>>>>
>>>>>>>>>> Piotr Zarzycki
>>>>>>>>>>
>>>>>>>>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=NG2rkkxhfc7MTSVRqHzEmHL8HuUpvXI72B9nkW2QfdU%3D&reserved=0>*
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> Carlos Rovira
>>>>>>>>> http://about.me/carlosrovira
>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fabout.me%2Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=55MSUXBM2zE5U0csgV1harcuXvKyZ2gd%2BO%2FmD7hjJ50%3D&reserved=0>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> --
>>>>>>>>
>>>>>>>> Piotr Zarzycki
>>>>>>>>
>>>>>>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=NG2rkkxhfc7MTSVRqHzEmHL8HuUpvXI72B9nkW2QfdU%3D&reserved=0>*
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>>
>>>>>> Piotr Zarzycki
>>>>>>
>>>>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=NG2rkkxhfc7MTSVRqHzEmHL8HuUpvXI72B9nkW2QfdU%3D&reserved=0>*
>>>>>>
>>>>>
>>>>>
>>>>
>>>
>>>
>>> --
>>> Carlos Rovira
>>> http://about.me/carlosrovira
>>>
>>>
>>
>>
>> --
>>
>> Piotr Zarzycki
>>
>> Patreon: *https://www.patreon.com/piotrzarzycki
>> <https://www.patreon.com/piotrzarzycki>*
>>
>
>


-- 

Piotr Zarzycki

Patreon: *https://www.patreon.com/piotrzarzycki
<https://www.patreon.com/piotrzarzycki>*

Re: RemoteObject

Posted by Carlos Rovira <ca...@apache.org>.
Hi Radu,

I recommend you to check blog examples where you can find very easy
examples to get started. Of course you'll need latest development code or
at least nightly build

https://royale.apache.org/category/royale-examples/



2018-07-27 17:09 GMT+02:00 radu <ra...@gmail.com>:

> Need one one one trayining with Apache Royale JS:
>
> I need to prort this code:
>
> <?xml version="1.0" encoding="utf-8"?>
> <mx:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
>                                 xmlns:mx="library://ns.adobe.com/flex/mx"
> layout="absolute"
> minWidth="50" minHeight="550" creationComplete="main()"
> backgroundAlpha="0">
>
>         <fx:Script>
>
>         </fx:Script>
>
>         <fx:Declarations>
>
>         </fx:Declarations>
>         <mx:Button label="t" id="but" width="100"
> click="button1_clickHandler(event)" />
> </mx:Application>
>
>
>
>
> --
> Sent from: http://apache-royale-users.20374.n8.nabble.com/
>



-- 
Carlos Rovira
http://about.me/carlosrovira

Re: RemoteObject

Posted by radu <ra...@gmail.com>.
Need one one one trayining with Apache Royale JS:

I need to prort this code:

<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:fx="http://ns.adobe.com/mxml/2009" 
				xmlns:mx="library://ns.adobe.com/flex/mx" layout="absolute"
minWidth="50" minHeight="550" creationComplete="main()" backgroundAlpha="0">
	
	<fx:Script>
		
	</fx:Script>
	
	<fx:Declarations>
		
	</fx:Declarations>
	<mx:Button label="t" id="but" width="100"
click="button1_clickHandler(event)" />
</mx:Application>




--
Sent from: http://apache-royale-users.20374.n8.nabble.com/

Re: RemoteObject

Posted by Fréderic Cox <co...@gmail.com>.
Thanks Piotr, I'll check it further also. We have the same version as you I
believe but we also have the C extension installed to speed things up.
Things get compressed (gzip) so maybe the issue can be there. I'm checking
with our server team tomorrow and hope to run some tests in the coming days

On Mon, Feb 19, 2018 at 12:11 AM, Piotr Zarzycki <pi...@gmail.com>
wrote:

> Frederic ,
>
> I did play with AMFPHP a bit with success. I have downloaded AMFPHP from
> here [1].
>
> There where following example service [2]. I was able to receive data from
> following methods without the problem. My test Royale application was
> placed in localhost.
>
> *returnOneParam*(1) - *OK*
> *returnSum*(1, 2) - *OK*
> *returnNull*() - *OK*
> *returnBla() - OK*
> *throwException('My Exception') - I did get exception here, but without
> sent string.*
> *returnTestHeader() - Failed*
> *returnArray() - OK*
> *returnOpposite() - OK*
> *returnBitwiseAnd() - OK*
> *staticReturnOneParam() - OK*
> *returnLargeTypedDataSet() - OK!! *I did create DummyVO - the was on
> server. Code ->
> https://paste.apache.org/W3E3
>
> *testArrayCollection - *This fail always and I believe even if we will
> have our own ArrayCollection. AMF won't understand it either.
>
> Prashant,
> In your example you have to use simple Array and it should work.
> I did change code of this service as you can see [1] and it was working
> for me without the problem!
>
> If method doesn't have any parameter It is important to send the second
> params as empty array service.send("returnNull", []) -> this won't work service.send("returnNull",
> null)
>
> Alex,
> what do you think to add to send empty array as default ?
>
> [1]  https://www.silexlabs.org/amfphp/
> [2] https://paste.apache.org/L24z
>
> Thanks,
> Piotr
>
>
> 2018-02-18 13:50 GMT+01:00 Prashant Kumar <pr...@gmail.com>:
>
>> Following cases not working:
>>
>> service.send("passArrayList",[new ArrayList(["Test1","Test2"])]);
>>
>> var v1:Vehicle = new Vehicle();
>> v1.name = "Nexon";
>> v1.brand = "TATA";
>> v1.dom = new Date();
>> service.send("addVehicle",[v1]);
>>
>>
>> On Sat, Feb 17, 2018 at 4:15 PM, Carlos Rovira <ca...@apache.org>
>> wrote:
>>
>>> Hi, I tested some months ago some scenarios with collections sharing
>>> some VOs, and worked, but I think we should try more scenarios since
>>> complex object graphs could be problematic.
>>>
>>> Thanks Prashant for looking into this. If you can help trying to evolve
>>> the code I can support you with your pull request to include your changes
>>> in Royale.
>>>
>>>
>>> 2018-02-17 5:37 GMT+01:00 Prashant Kumar <pr...@gmail.com>:
>>>
>>>> Carlos,
>>>>
>>>> If I sends only primary type as int , number , date etc then  all works
>>>> fine but if I sends custom types as a Arraylist , VOs, and other inherited
>>>> types does not work properly.
>>>>
>>>> Regards,
>>>> Prashant
>>>>
>>>> On 17-Feb-2018 2:50 AM, "Fréderic Cox" <co...@gmail.com> wrote:
>>>>
>>>> Updated https://github.com/apache/royale-asjs/issues/119, think I am
>>>> getting closer :-)
>>>>
>>>> On Fri, Feb 16, 2018 at 9:51 PM, Fréderic Cox <co...@gmail.com>
>>>> wrote:
>>>>
>>>>> Updated https://github.com/apache/royale-asjs/issues/119, can't get
>>>>> the JAVA part to work but changing the AMF endpoint to AMFPHP I get an
>>>>> error code when calling, so maybe that can help further research
>>>>>
>>>>> On Fri, Feb 16, 2018 at 9:21 PM, Fréderic Cox <co...@gmail.com>
>>>>> wrote:
>>>>>
>>>>>> Any instructions on how to build the example? This is kind of
>>>>>> complicated for me as I have 0 experience with JAVA and even less with
>>>>>> Maven ;-)
>>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>
>>>
>>> --
>>> Carlos Rovira
>>> http://about.me/carlosrovira
>>>
>>>
>>
>>
>> --
>> *Regards,*
>> Prashant Kumar* | *Mob.: +91 8408811225 <+91%2084088%2011225>
>>
>
>
>
> --
>
> Piotr Zarzycki
>
> Patreon: *https://www.patreon.com/piotrzarzycki
> <https://www.patreon.com/piotrzarzycki>*
>

Re: RemoteObject

Posted by Piotr Zarzycki <pi...@gmail.com>.
Frederic ,

I did play with AMFPHP a bit with success. I have downloaded AMFPHP from
here [1].

There where following example service [2]. I was able to receive data from
following methods without the problem. My test Royale application was
placed in localhost.

*returnOneParam*(1) - *OK*
*returnSum*(1, 2) - *OK*
*returnNull*() - *OK*
*returnBla() - OK*
*throwException('My Exception') - I did get exception here, but without
sent string.*
*returnTestHeader() - Failed*
*returnArray() - OK*
*returnOpposite() - OK*
*returnBitwiseAnd() - OK*
*staticReturnOneParam() - OK*
*returnLargeTypedDataSet() - OK!! *I did create DummyVO - the was on
server. Code ->
https://paste.apache.org/W3E3

*testArrayCollection - *This fail always and I believe even if we will have
our own ArrayCollection. AMF won't understand it either.

Prashant,
In your example you have to use simple Array and it should work.
I did change code of this service as you can see [1] and it was working for
me without the problem!

If method doesn't have any parameter It is important to send the second
params as empty array service.send("returnNull", []) -> this won't
work service.send("returnNull",
null)

Alex,
what do you think to add to send empty array as default ?

[1]  https://www.silexlabs.org/amfphp/
[2] https://paste.apache.org/L24z

Thanks,
Piotr


2018-02-18 13:50 GMT+01:00 Prashant Kumar <pr...@gmail.com>:

> Following cases not working:
>
> service.send("passArrayList",[new ArrayList(["Test1","Test2"])]);
>
> var v1:Vehicle = new Vehicle();
> v1.name = "Nexon";
> v1.brand = "TATA";
> v1.dom = new Date();
> service.send("addVehicle",[v1]);
>
>
> On Sat, Feb 17, 2018 at 4:15 PM, Carlos Rovira <ca...@apache.org>
> wrote:
>
>> Hi, I tested some months ago some scenarios with collections sharing some
>> VOs, and worked, but I think we should try more scenarios since complex
>> object graphs could be problematic.
>>
>> Thanks Prashant for looking into this. If you can help trying to evolve
>> the code I can support you with your pull request to include your changes
>> in Royale.
>>
>>
>> 2018-02-17 5:37 GMT+01:00 Prashant Kumar <pr...@gmail.com>:
>>
>>> Carlos,
>>>
>>> If I sends only primary type as int , number , date etc then  all works
>>> fine but if I sends custom types as a Arraylist , VOs, and other inherited
>>> types does not work properly.
>>>
>>> Regards,
>>> Prashant
>>>
>>> On 17-Feb-2018 2:50 AM, "Fréderic Cox" <co...@gmail.com> wrote:
>>>
>>> Updated https://github.com/apache/royale-asjs/issues/119, think I am
>>> getting closer :-)
>>>
>>> On Fri, Feb 16, 2018 at 9:51 PM, Fréderic Cox <co...@gmail.com>
>>> wrote:
>>>
>>>> Updated https://github.com/apache/royale-asjs/issues/119, can't get
>>>> the JAVA part to work but changing the AMF endpoint to AMFPHP I get an
>>>> error code when calling, so maybe that can help further research
>>>>
>>>> On Fri, Feb 16, 2018 at 9:21 PM, Fréderic Cox <co...@gmail.com>
>>>> wrote:
>>>>
>>>>> Any instructions on how to build the example? This is kind of
>>>>> complicated for me as I have 0 experience with JAVA and even less with
>>>>> Maven ;-)
>>>>>
>>>>
>>>>
>>>
>>>
>>
>>
>> --
>> Carlos Rovira
>> http://about.me/carlosrovira
>>
>>
>
>
> --
> *Regards,*
> Prashant Kumar* | *Mob.: +91 8408811225 <+91%2084088%2011225>
>



-- 

Piotr Zarzycki

Patreon: *https://www.patreon.com/piotrzarzycki
<https://www.patreon.com/piotrzarzycki>*

Re: RemoteObject

Posted by Alex Harui <ah...@adobe.com>.
Yes, the emulation of ArrayList and ArrayCollection will have to have the same [RemoteClass] metadata.

-Alex

From: <ca...@gmail.com>> on behalf of Carlos Rovira <ca...@apache.org>>
Reply-To: "users@royale.apache.org<ma...@royale.apache.org>" <us...@royale.apache.org>>
Date: Tuesday, April 17, 2018 at 2:24 PM
To: "users@royale.apache.org<ma...@royale.apache.org>" <us...@royale.apache.org>>
Subject: Re: RemoteObject

Hi Piotr, great to see you get that working. I suppose the problem is with ArrayList vs ArrayCollection?

@Alex, you say that will start working cause we'll have ArrayCollection in emulation components?

thanks!

2018-04-17 22:29 GMT+02:00 Alex Harui <ah...@adobe.com>>:
The emulation components are a valid component set.  They are not 100% compatible with Flex and aren't going to be as fast and small as Basic or Express, but they should be operational and may allow the migration of a production app.  We won't know for sure until we get further.  But as of today, the Flex SDK checkintest runs tests on 6 components without modification.  It isn't perfect, but will get better over time.

If it turns out there are performance issues, then folks migrating will have to find the hot spots and try to optimize them by replacing the emulation components with Basic or Express components.  It will be interesting to see how many folks can run an app entirely on the emulation components.

HTH,
-Alex

From: Piotr Zarzycki <pi...@gmail.com>>
Reply-To: "users@royale.apache.org<ma...@royale.apache.org>" <us...@royale.apache.org>>
Date: Tuesday, April 17, 2018 at 1:21 PM

To: "users@royale.apache.org<ma...@royale.apache.org>" <us...@royale.apache.org>>
Subject: Re: RemoteObject

Alex,

I understand Emulations as something temporary. In the end all of that would be replaced in the real app when someone start write UI or do I understand it wrong?

I thought it's only for run App and then step by step rewrite to Royale components.

Thanks,
Piotr

On Tue, Apr 17, 2018, 10:00 PM Alex Harui <ah...@adobe.com>> wrote:
Hi Piotr,

I have not looked into the detail, but I would hope that it would start working once we get more of the emulation components up and running.  So volunteers to help with emulation components are always welcome.

-Alex

From: Piotr Zarzycki <pi...@gmail.com>>
Reply-To: "users@royale.apache.org<ma...@royale.apache.org>" <us...@royale.apache.org>>
Date: Tuesday, April 17, 2018 at 12:50 PM

To: "users@royale.apache.org<ma...@royale.apache.org>" <us...@royale.apache.org>>
Subject: Re: RemoteObject
Hi Prashant,

I just tried your two examples. The first one not going to work cause AMF doesn't recognize ArrayList, but you can always send simple Array - That's an workaround.

The second one is working pretty well. I'm using AMFPHP. I've created method which simply get's VO and returns it. - What happened in your case when you did test that ?

Thanks,
Piotr

2018-02-18 13:50 GMT+01:00 Prashant Kumar <pr...@gmail.com>>:
Following cases not working:

service.send("passArrayList",[newArrayList(["Test1","Test2"])]);

var v1:Vehicle=newVehicle();
v1.name ="Nexon";
v1.brand ="TATA";
v1.dom =newDate();
service.send("addVehicle",[v1]);


On Sat, Feb 17, 2018 at 4:15 PM, Carlos Rovira <ca...@apache.org>> wrote:
Hi, I tested some months ago some scenarios with collections sharing some VOs, and worked, but I think we should try more scenarios since complex object graphs could be problematic.

Thanks Prashant for looking into this. If you can help trying to evolve the code I can support you with your pull request to include your changes in Royale.


2018-02-17 5:37 GMT+01:00 Prashant Kumar <pr...@gmail.com>>:
Carlos,

If I sends only primary type as int , number , date etc then  all works fine but if I sends custom types as a Arraylist , VOs, and other inherited types does not work properly.

Regards,
Prashant

On 17-Feb-2018 2:50 AM, "Fréderic Cox" <co...@gmail.com>> wrote:
Updated https://github.com/apache/royale-asjs/issues/119<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Fissues%2F119&data=02%7C01%7Caharui%40adobe.com%7Caf7310016b214b09117f08d5a49c82d9%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636595914499233466&sdata=ekkR98TmfKiGCLDl7jxaJ%2BhJ7ZJFV6uh1f58hyFqmLA%3D&reserved=0>, think I am getting closer :-)

On Fri, Feb 16, 2018 at 9:51 PM, Fréderic Cox <co...@gmail.com>> wrote:
Updated https://github.com/apache/royale-asjs/issues/119<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Fissues%2F119&data=02%7C01%7Caharui%40adobe.com%7Caf7310016b214b09117f08d5a49c82d9%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636595914499233466&sdata=ekkR98TmfKiGCLDl7jxaJ%2BhJ7ZJFV6uh1f58hyFqmLA%3D&reserved=0>, can't get the JAVA part to work but changing the AMF endpoint to AMFPHP I get an error code when calling, so maybe that can help further research

On Fri, Feb 16, 2018 at 9:21 PM, Fréderic Cox <co...@gmail.com>> wrote:
Any instructions on how to build the example? This is kind of complicated for me as I have 0 experience with JAVA and even less with Maven ;-)






--
Carlos Rovira
http://about.me/carlosrovira<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fabout.me%2Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com%7Caf7310016b214b09117f08d5a49c82d9%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636595914499233466&sdata=rMkJHjgVoPBk7gRrAC5vjQX%2BM%2FppBIqdHxZOCkfQPlo%3D&reserved=0>




--
Regards,
Prashant Kumar | Mob.: +91 8408811225



--

Piotr Zarzycki

Patreon: https://www.patreon.com/piotrzarzycki<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7Caf7310016b214b09117f08d5a49c82d9%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636595914499233466&sdata=QSUVPPigUtohm5A9IZQpDZeoNiFjpSDpjqWwBdokkTY%3D&reserved=0>



--
Carlos Rovira
http://about.me/carlosrovira<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fabout.me%2Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com%7C4fbc16de1e6d4a3280d608d5a4a9a284%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636595970894301484&sdata=EP%2BsA41HjOreGP5oArgydTQYCAHI1fXzQChOSX78BXQ%3D&reserved=0>


Re: RemoteObject

Posted by Carlos Rovira <ca...@apache.org>.
Hi Piotr, great to see you get that working. I suppose the problem is with
ArrayList vs ArrayCollection?

@Alex, you say that will start working cause we'll have ArrayCollection in
emulation components?

thanks!

2018-04-17 22:29 GMT+02:00 Alex Harui <ah...@adobe.com>:

> The emulation components are a valid component set.  They are not 100%
> compatible with Flex and aren't going to be as fast and small as Basic or
> Express, but they should be operational and may allow the migration of a
> production app.  We won't know for sure until we get further.  But as of
> today, the Flex SDK checkintest runs tests on 6 components without
> modification.  It isn't perfect, but will get better over time.
>
> If it turns out there are performance issues, then folks migrating will
> have to find the hot spots and try to optimize them by replacing the
> emulation components with Basic or Express components.  It will be
> interesting to see how many folks can run an app entirely on the emulation
> components.
>
> HTH,
> -Alex
>
> From: Piotr Zarzycki <pi...@gmail.com>
> Reply-To: "users@royale.apache.org" <us...@royale.apache.org>
> Date: Tuesday, April 17, 2018 at 1:21 PM
>
> To: "users@royale.apache.org" <us...@royale.apache.org>
> Subject: Re: RemoteObject
>
> Alex,
>
> I understand Emulations as something temporary. In the end all of that
> would be replaced in the real app when someone start write UI or do I
> understand it wrong?
>
> I thought it's only for run App and then step by step rewrite to Royale
> components.
>
> Thanks,
> Piotr
>
> On Tue, Apr 17, 2018, 10:00 PM Alex Harui <ah...@adobe.com> wrote:
>
>> Hi Piotr,
>>
>> I have not looked into the detail, but I would hope that it would start
>> working once we get more of the emulation components up and running.  So
>> volunteers to help with emulation components are always welcome.
>>
>> -Alex
>>
>> From: Piotr Zarzycki <pi...@gmail.com>
>> Reply-To: "users@royale.apache.org" <us...@royale.apache.org>
>> Date: Tuesday, April 17, 2018 at 12:50 PM
>>
>> To: "users@royale.apache.org" <us...@royale.apache.org>
>> Subject: Re: RemoteObject
>> Hi Prashant,
>>
>> I just tried your two examples. The first one not going to work cause AMF
>> doesn't recognize ArrayList, but you can always send simple Array - That's
>> an workaround.
>>
>> The second one is working pretty well. I'm using AMFPHP. I've created
>> method which simply get's VO and returns it. - What happened in your case
>> when you did test that ?
>>
>> Thanks,
>> Piotr
>>
>> 2018-02-18 13:50 GMT+01:00 Prashant Kumar <pr...@gmail.com>:
>>
>>> Following cases not working:
>>>
>>> service.send("passArrayList",[newArrayList(["Test1","Test2"])]);
>>>
>>> var v1:Vehicle=newVehicle();
>>> v1.name ="Nexon";
>>> v1.brand ="TATA";
>>> v1.dom =newDate();
>>> service.send("addVehicle",[v1]);
>>>
>>>
>>> On Sat, Feb 17, 2018 at 4:15 PM, Carlos Rovira <ca...@apache.org>
>>> wrote:
>>>
>>>> Hi, I tested some months ago some scenarios with collections sharing
>>>> some VOs, and worked, but I think we should try more scenarios since
>>>> complex object graphs could be problematic.
>>>>
>>>> Thanks Prashant for looking into this. If you can help trying to evolve
>>>> the code I can support you with your pull request to include your changes
>>>> in Royale.
>>>>
>>>>
>>>> 2018-02-17 5:37 GMT+01:00 Prashant Kumar <pr...@gmail.com>:
>>>>
>>>>> Carlos,
>>>>>
>>>>> If I sends only primary type as int , number , date etc then  all
>>>>> works fine but if I sends custom types as a Arraylist , VOs, and other
>>>>> inherited types does not work properly.
>>>>>
>>>>> Regards,
>>>>> Prashant
>>>>>
>>>>> On 17-Feb-2018 2:50 AM, "Fréderic Cox" <co...@gmail.com> wrote:
>>>>>
>>>>> Updated https://github.com/apache/royale-asjs/issues/119
>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Fissues%2F119&data=02%7C01%7Caharui%40adobe.com%7Caf7310016b214b09117f08d5a49c82d9%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636595914499233466&sdata=ekkR98TmfKiGCLDl7jxaJ%2BhJ7ZJFV6uh1f58hyFqmLA%3D&reserved=0>,
>>>>> think I am getting closer :-)
>>>>>
>>>>> On Fri, Feb 16, 2018 at 9:51 PM, Fréderic Cox <co...@gmail.com>
>>>>> wrote:
>>>>>
>>>>>> Updated https://github.com/apache/royale-asjs/issues/119
>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Fissues%2F119&data=02%7C01%7Caharui%40adobe.com%7Caf7310016b214b09117f08d5a49c82d9%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636595914499233466&sdata=ekkR98TmfKiGCLDl7jxaJ%2BhJ7ZJFV6uh1f58hyFqmLA%3D&reserved=0>,
>>>>>> can't get the JAVA part to work but changing the AMF endpoint to AMFPHP I
>>>>>> get an error code when calling, so maybe that can help further research
>>>>>>
>>>>>> On Fri, Feb 16, 2018 at 9:21 PM, Fréderic Cox <co...@gmail.com>
>>>>>> wrote:
>>>>>>
>>>>>>> Any instructions on how to build the example? This is kind of
>>>>>>> complicated for me as I have 0 experience with JAVA and even less with
>>>>>>> Maven ;-)
>>>>>>>
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>> Carlos Rovira
>>>> http://about.me/carlosrovira
>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fabout.me%2Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com%7Caf7310016b214b09117f08d5a49c82d9%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636595914499233466&sdata=rMkJHjgVoPBk7gRrAC5vjQX%2BM%2FppBIqdHxZOCkfQPlo%3D&reserved=0>
>>>>
>>>>
>>>
>>>
>>> --
>>> *Regards,*
>>> Prashant Kumar* | *Mob.: +91 8408811225
>>>
>>
>>
>>
>> --
>>
>> Piotr Zarzycki
>>
>> Patreon: *https://www.patreon.com/piotrzarzycki
>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7Caf7310016b214b09117f08d5a49c82d9%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636595914499233466&sdata=QSUVPPigUtohm5A9IZQpDZeoNiFjpSDpjqWwBdokkTY%3D&reserved=0>*
>>
>


-- 
Carlos Rovira
http://about.me/carlosrovira

Re: RemoteObject

Posted by Alex Harui <ah...@adobe.com>.
The emulation components are a valid component set.  They are not 100% compatible with Flex and aren't going to be as fast and small as Basic or Express, but they should be operational and may allow the migration of a production app.  We won't know for sure until we get further.  But as of today, the Flex SDK checkintest runs tests on 6 components without modification.  It isn't perfect, but will get better over time.

If it turns out there are performance issues, then folks migrating will have to find the hot spots and try to optimize them by replacing the emulation components with Basic or Express components.  It will be interesting to see how many folks can run an app entirely on the emulation components.

HTH,
-Alex

From: Piotr Zarzycki <pi...@gmail.com>>
Reply-To: "users@royale.apache.org<ma...@royale.apache.org>" <us...@royale.apache.org>>
Date: Tuesday, April 17, 2018 at 1:21 PM
To: "users@royale.apache.org<ma...@royale.apache.org>" <us...@royale.apache.org>>
Subject: Re: RemoteObject

Alex,

I understand Emulations as something temporary. In the end all of that would be replaced in the real app when someone start write UI or do I understand it wrong?

I thought it's only for run App and then step by step rewrite to Royale components.

Thanks,
Piotr

On Tue, Apr 17, 2018, 10:00 PM Alex Harui <ah...@adobe.com>> wrote:
Hi Piotr,

I have not looked into the detail, but I would hope that it would start working once we get more of the emulation components up and running.  So volunteers to help with emulation components are always welcome.

-Alex

From: Piotr Zarzycki <pi...@gmail.com>>
Reply-To: "users@royale.apache.org<ma...@royale.apache.org>" <us...@royale.apache.org>>
Date: Tuesday, April 17, 2018 at 12:50 PM

To: "users@royale.apache.org<ma...@royale.apache.org>" <us...@royale.apache.org>>
Subject: Re: RemoteObject
Hi Prashant,

I just tried your two examples. The first one not going to work cause AMF doesn't recognize ArrayList, but you can always send simple Array - That's an workaround.

The second one is working pretty well. I'm using AMFPHP. I've created method which simply get's VO and returns it. - What happened in your case when you did test that ?

Thanks,
Piotr

2018-02-18 13:50 GMT+01:00 Prashant Kumar <pr...@gmail.com>>:
Following cases not working:

service.send("passArrayList",[newArrayList(["Test1","Test2"])]);

var v1:Vehicle=newVehicle();
v1.name ="Nexon";
v1.brand ="TATA";
v1.dom =newDate();
service.send("addVehicle",[v1]);


On Sat, Feb 17, 2018 at 4:15 PM, Carlos Rovira <ca...@apache.org>> wrote:
Hi, I tested some months ago some scenarios with collections sharing some VOs, and worked, but I think we should try more scenarios since complex object graphs could be problematic.

Thanks Prashant for looking into this. If you can help trying to evolve the code I can support you with your pull request to include your changes in Royale.


2018-02-17 5:37 GMT+01:00 Prashant Kumar <pr...@gmail.com>>:
Carlos,

If I sends only primary type as int , number , date etc then  all works fine but if I sends custom types as a Arraylist , VOs, and other inherited types does not work properly.

Regards,
Prashant

On 17-Feb-2018 2:50 AM, "Fréderic Cox" <co...@gmail.com>> wrote:
Updated https://github.com/apache/royale-asjs/issues/119<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Fissues%2F119&data=02%7C01%7Caharui%40adobe.com%7Caf7310016b214b09117f08d5a49c82d9%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636595914499233466&sdata=ekkR98TmfKiGCLDl7jxaJ%2BhJ7ZJFV6uh1f58hyFqmLA%3D&reserved=0>, think I am getting closer :-)

On Fri, Feb 16, 2018 at 9:51 PM, Fréderic Cox <co...@gmail.com>> wrote:
Updated https://github.com/apache/royale-asjs/issues/119<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Fissues%2F119&data=02%7C01%7Caharui%40adobe.com%7Caf7310016b214b09117f08d5a49c82d9%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636595914499233466&sdata=ekkR98TmfKiGCLDl7jxaJ%2BhJ7ZJFV6uh1f58hyFqmLA%3D&reserved=0>, can't get the JAVA part to work but changing the AMF endpoint to AMFPHP I get an error code when calling, so maybe that can help further research

On Fri, Feb 16, 2018 at 9:21 PM, Fréderic Cox <co...@gmail.com>> wrote:
Any instructions on how to build the example? This is kind of complicated for me as I have 0 experience with JAVA and even less with Maven ;-)






--
Carlos Rovira
http://about.me/carlosrovira<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fabout.me%2Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com%7Caf7310016b214b09117f08d5a49c82d9%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636595914499233466&sdata=rMkJHjgVoPBk7gRrAC5vjQX%2BM%2FppBIqdHxZOCkfQPlo%3D&reserved=0>




--
Regards,
Prashant Kumar | Mob.: +91 8408811225



--

Piotr Zarzycki

Patreon: https://www.patreon.com/piotrzarzycki<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7Caf7310016b214b09117f08d5a49c82d9%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636595914499233466&sdata=QSUVPPigUtohm5A9IZQpDZeoNiFjpSDpjqWwBdokkTY%3D&reserved=0>

Re: RemoteObject

Posted by Piotr Zarzycki <pi...@gmail.com>.
Alex,

I understand Emulations as something temporary. In the end all of that
would be replaced in the real app when someone start write UI or do I
understand it wrong?

I thought it's only for run App and then step by step rewrite to Royale
components.

Thanks,
Piotr

On Tue, Apr 17, 2018, 10:00 PM Alex Harui <ah...@adobe.com> wrote:

> Hi Piotr,
>
> I have not looked into the detail, but I would hope that it would start
> working once we get more of the emulation components up and running.  So
> volunteers to help with emulation components are always welcome.
>
> -Alex
>
> From: Piotr Zarzycki <pi...@gmail.com>
> Reply-To: "users@royale.apache.org" <us...@royale.apache.org>
> Date: Tuesday, April 17, 2018 at 12:50 PM
>
> To: "users@royale.apache.org" <us...@royale.apache.org>
> Subject: Re: RemoteObject
> Hi Prashant,
>
> I just tried your two examples. The first one not going to work cause AMF
> doesn't recognize ArrayList, but you can always send simple Array - That's
> an workaround.
>
> The second one is working pretty well. I'm using AMFPHP. I've created
> method which simply get's VO and returns it. - What happened in your case
> when you did test that ?
>
> Thanks,
> Piotr
>
> 2018-02-18 13:50 GMT+01:00 Prashant Kumar <pr...@gmail.com>:
>
>> Following cases not working:
>>
>> service.send("passArrayList",[newArrayList(["Test1","Test2"])]);
>>
>> var v1:Vehicle=newVehicle();
>> v1.name ="Nexon";
>> v1.brand ="TATA";
>> v1.dom =newDate();
>> service.send("addVehicle",[v1]);
>>
>>
>> On Sat, Feb 17, 2018 at 4:15 PM, Carlos Rovira <ca...@apache.org>
>> wrote:
>>
>>> Hi, I tested some months ago some scenarios with collections sharing
>>> some VOs, and worked, but I think we should try more scenarios since
>>> complex object graphs could be problematic.
>>>
>>> Thanks Prashant for looking into this. If you can help trying to evolve
>>> the code I can support you with your pull request to include your changes
>>> in Royale.
>>>
>>>
>>> 2018-02-17 5:37 GMT+01:00 Prashant Kumar <pr...@gmail.com>:
>>>
>>>> Carlos,
>>>>
>>>> If I sends only primary type as int , number , date etc then  all works
>>>> fine but if I sends custom types as a Arraylist , VOs, and other inherited
>>>> types does not work properly.
>>>>
>>>> Regards,
>>>> Prashant
>>>>
>>>> On 17-Feb-2018 2:50 AM, "Fréderic Cox" <co...@gmail.com> wrote:
>>>>
>>>> Updated https://github.com/apache/royale-asjs/issues/119
>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Fissues%2F119&data=02%7C01%7Caharui%40adobe.com%7Caf7310016b214b09117f08d5a49c82d9%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636595914499233466&sdata=ekkR98TmfKiGCLDl7jxaJ%2BhJ7ZJFV6uh1f58hyFqmLA%3D&reserved=0>,
>>>> think I am getting closer :-)
>>>>
>>>> On Fri, Feb 16, 2018 at 9:51 PM, Fréderic Cox <co...@gmail.com>
>>>> wrote:
>>>>
>>>>> Updated https://github.com/apache/royale-asjs/issues/119
>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Fissues%2F119&data=02%7C01%7Caharui%40adobe.com%7Caf7310016b214b09117f08d5a49c82d9%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636595914499233466&sdata=ekkR98TmfKiGCLDl7jxaJ%2BhJ7ZJFV6uh1f58hyFqmLA%3D&reserved=0>,
>>>>> can't get the JAVA part to work but changing the AMF endpoint to AMFPHP I
>>>>> get an error code when calling, so maybe that can help further research
>>>>>
>>>>> On Fri, Feb 16, 2018 at 9:21 PM, Fréderic Cox <co...@gmail.com>
>>>>> wrote:
>>>>>
>>>>>> Any instructions on how to build the example? This is kind of
>>>>>> complicated for me as I have 0 experience with JAVA and even less with
>>>>>> Maven ;-)
>>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>
>>>
>>> --
>>> Carlos Rovira
>>> http://about.me/carlosrovira
>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fabout.me%2Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com%7Caf7310016b214b09117f08d5a49c82d9%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636595914499233466&sdata=rMkJHjgVoPBk7gRrAC5vjQX%2BM%2FppBIqdHxZOCkfQPlo%3D&reserved=0>
>>>
>>>
>>
>>
>> --
>> *Regards,*
>> Prashant Kumar* | *Mob.: +91 8408811225
>>
>
>
>
> --
>
> Piotr Zarzycki
>
> Patreon: *https://www.patreon.com/piotrzarzycki
> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7Caf7310016b214b09117f08d5a49c82d9%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636595914499233466&sdata=QSUVPPigUtohm5A9IZQpDZeoNiFjpSDpjqWwBdokkTY%3D&reserved=0>*
>

Re: RemoteObject

Posted by Alex Harui <ah...@adobe.com>.
Hi Piotr,

I have not looked into the detail, but I would hope that it would start working once we get more of the emulation components up and running.  So volunteers to help with emulation components are always welcome.

-Alex

From: Piotr Zarzycki <pi...@gmail.com>>
Reply-To: "users@royale.apache.org<ma...@royale.apache.org>" <us...@royale.apache.org>>
Date: Tuesday, April 17, 2018 at 12:50 PM
To: "users@royale.apache.org<ma...@royale.apache.org>" <us...@royale.apache.org>>
Subject: Re: RemoteObject

Hi Prashant,

I just tried your two examples. The first one not going to work cause AMF doesn't recognize ArrayList, but you can always send simple Array - That's an workaround.

The second one is working pretty well. I'm using AMFPHP. I've created method which simply get's VO and returns it. - What happened in your case when you did test that ?

Thanks,
Piotr


2018-02-18 13:50 GMT+01:00 Prashant Kumar <pr...@gmail.com>>:
Following cases not working:

service.send("passArrayList",[newArrayList(["Test1","Test2"])]);

var v1:Vehicle=newVehicle();
v1.name ="Nexon";
v1.brand ="TATA";
v1.dom =newDate();
service.send("addVehicle",[v1]);


On Sat, Feb 17, 2018 at 4:15 PM, Carlos Rovira <ca...@apache.org>> wrote:
Hi, I tested some months ago some scenarios with collections sharing some VOs, and worked, but I think we should try more scenarios since complex object graphs could be problematic.

Thanks Prashant for looking into this. If you can help trying to evolve the code I can support you with your pull request to include your changes in Royale.


2018-02-17 5:37 GMT+01:00 Prashant Kumar <pr...@gmail.com>>:
Carlos,

If I sends only primary type as int , number , date etc then  all works fine but if I sends custom types as a Arraylist , VOs, and other inherited types does not work properly.

Regards,
Prashant

On 17-Feb-2018 2:50 AM, "Fréderic Cox" <co...@gmail.com>> wrote:
Updated https://github.com/apache/royale-asjs/issues/119<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Fissues%2F119&data=02%7C01%7Caharui%40adobe.com%7Caf7310016b214b09117f08d5a49c82d9%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636595914499233466&sdata=ekkR98TmfKiGCLDl7jxaJ%2BhJ7ZJFV6uh1f58hyFqmLA%3D&reserved=0>, think I am getting closer :-)

On Fri, Feb 16, 2018 at 9:51 PM, Fréderic Cox <co...@gmail.com>> wrote:
Updated https://github.com/apache/royale-asjs/issues/119<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Fissues%2F119&data=02%7C01%7Caharui%40adobe.com%7Caf7310016b214b09117f08d5a49c82d9%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636595914499233466&sdata=ekkR98TmfKiGCLDl7jxaJ%2BhJ7ZJFV6uh1f58hyFqmLA%3D&reserved=0>, can't get the JAVA part to work but changing the AMF endpoint to AMFPHP I get an error code when calling, so maybe that can help further research

On Fri, Feb 16, 2018 at 9:21 PM, Fréderic Cox <co...@gmail.com>> wrote:
Any instructions on how to build the example? This is kind of complicated for me as I have 0 experience with JAVA and even less with Maven ;-)






--
Carlos Rovira
http://about.me/carlosrovira<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fabout.me%2Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com%7Caf7310016b214b09117f08d5a49c82d9%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636595914499233466&sdata=rMkJHjgVoPBk7gRrAC5vjQX%2BM%2FppBIqdHxZOCkfQPlo%3D&reserved=0>




--
Regards,
Prashant Kumar | Mob.: +91 8408811225



--

Piotr Zarzycki

Patreon: https://www.patreon.com/piotrzarzycki<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7Caf7310016b214b09117f08d5a49c82d9%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636595914499233466&sdata=QSUVPPigUtohm5A9IZQpDZeoNiFjpSDpjqWwBdokkTY%3D&reserved=0>

Re: RemoteObject

Posted by Piotr Zarzycki <pi...@gmail.com>.
Hi Prashant,

I just tried your two examples. The first one not going to work cause AMF
doesn't recognize ArrayList, but you can always send simple Array - That's
an workaround.

The second one is working pretty well. I'm using AMFPHP. I've created
method which simply get's VO and returns it. - What happened in your case
when you did test that ?

Thanks,
Piotr


2018-02-18 13:50 GMT+01:00 Prashant Kumar <pr...@gmail.com>:

> Following cases not working:
>
> service.send("passArrayList",[new ArrayList(["Test1","Test2"])]);
>
> var v1:Vehicle = new Vehicle();
> v1.name = "Nexon";
> v1.brand = "TATA";
> v1.dom = new Date();
> service.send("addVehicle",[v1]);
>
>
> On Sat, Feb 17, 2018 at 4:15 PM, Carlos Rovira <ca...@apache.org>
> wrote:
>
>> Hi, I tested some months ago some scenarios with collections sharing some
>> VOs, and worked, but I think we should try more scenarios since complex
>> object graphs could be problematic.
>>
>> Thanks Prashant for looking into this. If you can help trying to evolve
>> the code I can support you with your pull request to include your changes
>> in Royale.
>>
>>
>> 2018-02-17 5:37 GMT+01:00 Prashant Kumar <pr...@gmail.com>:
>>
>>> Carlos,
>>>
>>> If I sends only primary type as int , number , date etc then  all works
>>> fine but if I sends custom types as a Arraylist , VOs, and other inherited
>>> types does not work properly.
>>>
>>> Regards,
>>> Prashant
>>>
>>> On 17-Feb-2018 2:50 AM, "Fréderic Cox" <co...@gmail.com> wrote:
>>>
>>> Updated https://github.com/apache/royale-asjs/issues/119, think I am
>>> getting closer :-)
>>>
>>> On Fri, Feb 16, 2018 at 9:51 PM, Fréderic Cox <co...@gmail.com>
>>> wrote:
>>>
>>>> Updated https://github.com/apache/royale-asjs/issues/119, can't get
>>>> the JAVA part to work but changing the AMF endpoint to AMFPHP I get an
>>>> error code when calling, so maybe that can help further research
>>>>
>>>> On Fri, Feb 16, 2018 at 9:21 PM, Fréderic Cox <co...@gmail.com>
>>>> wrote:
>>>>
>>>>> Any instructions on how to build the example? This is kind of
>>>>> complicated for me as I have 0 experience with JAVA and even less with
>>>>> Maven ;-)
>>>>>
>>>>
>>>>
>>>
>>>
>>
>>
>> --
>> Carlos Rovira
>> http://about.me/carlosrovira
>>
>>
>
>
> --
> *Regards,*
> Prashant Kumar* | *Mob.: +91 8408811225
>



-- 

Piotr Zarzycki

Patreon: *https://www.patreon.com/piotrzarzycki
<https://www.patreon.com/piotrzarzycki>*

Re: RemoteObject

Posted by Carlos Rovira <ca...@apache.org>.
Many thanks Prashant for your support!

waiting to know about your progress :)

Carlos

2018-02-21 7:27 GMT+01:00 Prashant Kumar <pr...@gmail.com>:

> Fine, I will investigate this today and update you on the root cause.
>
>
> On 20-Feb-2018 1:53 PM, "Carlos Rovira" <ca...@apache.org> wrote:
>
> Hi Prashant,
>
> curious. I think we passed an array of typed VOs, and for example Vehicle
> has only 2 strings and a Date. My VO doesn't have a date property, but I
> assume that should work. Anyway, could you investigate why that not work?
> As I said I can support you with pull request if you want. I'm right now
> focused on new Vivid UI Set that can support themes and visual
> customization.
>
> thanks!
>
>
> 2018-02-18 13:50 GMT+01:00 Prashant Kumar <pr...@gmail.com>:
>
>> Following cases not working:
>>
>> service.send("passArrayList",[new ArrayList(["Test1","Test2"])]);
>>
>> var v1:Vehicle = new Vehicle();
>> v1.name = "Nexon";
>> v1.brand = "TATA";
>> v1.dom = new Date();
>> service.send("addVehicle",[v1]);
>>
>>
>> On Sat, Feb 17, 2018 at 4:15 PM, Carlos Rovira <ca...@apache.org>
>> wrote:
>>
>>> Hi, I tested some months ago some scenarios with collections sharing
>>> some VOs, and worked, but I think we should try more scenarios since
>>> complex object graphs could be problematic.
>>>
>>> Thanks Prashant for looking into this. If you can help trying to evolve
>>> the code I can support you with your pull request to include your changes
>>> in Royale.
>>>
>>>
>>> 2018-02-17 5:37 GMT+01:00 Prashant Kumar <pr...@gmail.com>:
>>>
>>>> Carlos,
>>>>
>>>> If I sends only primary type as int , number , date etc then  all works
>>>> fine but if I sends custom types as a Arraylist , VOs, and other inherited
>>>> types does not work properly.
>>>>
>>>> Regards,
>>>> Prashant
>>>>
>>>> On 17-Feb-2018 2:50 AM, "Fréderic Cox" <co...@gmail.com> wrote:
>>>>
>>>> Updated https://github.com/apache/royale-asjs/issues/119, think I am
>>>> getting closer :-)
>>>>
>>>> On Fri, Feb 16, 2018 at 9:51 PM, Fréderic Cox <co...@gmail.com>
>>>> wrote:
>>>>
>>>>> Updated https://github.com/apache/royale-asjs/issues/119, can't get
>>>>> the JAVA part to work but changing the AMF endpoint to AMFPHP I get an
>>>>> error code when calling, so maybe that can help further research
>>>>>
>>>>> On Fri, Feb 16, 2018 at 9:21 PM, Fréderic Cox <co...@gmail.com>
>>>>> wrote:
>>>>>
>>>>>> Any instructions on how to build the example? This is kind of
>>>>>> complicated for me as I have 0 experience with JAVA and even less with
>>>>>> Maven ;-)
>>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>
>>>
>>> --
>>> Carlos Rovira
>>> http://about.me/carlosrovira
>>>
>>>
>>
>>
>> --
>> *Regards,*
>> Prashant Kumar* | *Mob.: +91 8408811225 <+91%2084088%2011225>
>>
>
>
>
> --
> Carlos Rovira
> http://about.me/carlosrovira
>
>
>


-- 
Carlos Rovira
http://about.me/carlosrovira

Re: RemoteObject

Posted by Fréderic Cox <co...@gmail.com>.
Thanks Piotr, I am *still* waiting on our server team to set up the AMFPHP test case

Verstuurd vanaf mijn iPhone

> Op 2 apr. 2018 om 08:32 heeft Prashant Kumar <pr...@gmail.com> het volgende geschreven:
> 
> I could not get chance to look into this. Please go ahead and check this. If you require any my support, do let me know.
> 
>> On Sun 1 Apr, 2018, 10:57 PM Piotr Zarzycki, <pi...@gmail.com> wrote:
>> Hi Prashant,
>> 
>> Did you have a chance to look into that case ? If not I'm going in the next week look closer to AMF.
>> 
>> Let me know.
>> 
>> Thanks,
>> Piotr
>> 
>> 2018-02-21 7:27 GMT+01:00 Prashant Kumar <pr...@gmail.com>:
>>> Fine, I will investigate this today and update you on the root cause.
>>> 
>>> 
>>> On 20-Feb-2018 1:53 PM, "Carlos Rovira" <ca...@apache.org> wrote:
>>> Hi Prashant,
>>> 
>>> curious. I think we passed an array of typed VOs, and for example Vehicle has only 2 strings and a Date. My VO doesn't have a date property, but I assume that should work. Anyway, could you investigate why that not work? As I said I can support you with pull request if you want. I'm right now focused on new Vivid UI Set that can support themes and visual customization.
>>> 
>>> thanks!
>>> 
>>> 
>>> 2018-02-18 13:50 GMT+01:00 Prashant Kumar <pr...@gmail.com>:
>>>> Following cases not working:
>>>> 
>>>> service.send("passArrayList",[new ArrayList(["Test1","Test2"])]);
>>>> 
>>>> var v1:Vehicle = new Vehicle();
>>>>                 v1.name = "Nexon";
>>>>                 v1.brand = "TATA";
>>>>                 v1.dom =  new Date();
>>>>                 service.send("addVehicle",[v1]);
>>>> 
>>>> 
>>>>> On Sat, Feb 17, 2018 at 4:15 PM, Carlos Rovira <ca...@apache.org> wrote:
>>>>> Hi, I tested some months ago some scenarios with collections sharing some VOs, and worked, but I think we should try more scenarios since complex object graphs could be problematic.
>>>>> 
>>>>> Thanks Prashant for looking into this. If you can help trying to evolve the code I can support you with your pull request to include your changes in Royale.
>>>>> 
>>>>> 
>>>>> 2018-02-17 5:37 GMT+01:00 Prashant Kumar <pr...@gmail.com>:
>>>>>> Carlos,
>>>>>> 
>>>>>> If I sends only primary type as int , number , date etc then  all works fine but if I sends custom types as a Arraylist , VOs, and other inherited types does not work properly. 
>>>>>> 
>>>>>> Regards,
>>>>>> Prashant
>>>>>> 
>>>>>> On 17-Feb-2018 2:50 AM, "Fréderic Cox" <co...@gmail.com> wrote:
>>>>>> Updated https://github.com/apache/royale-asjs/issues/119, think I am getting closer :-)
>>>>>> 
>>>>>> On Fri, Feb 16, 2018 at 9:51 PM, Fréderic Cox <co...@gmail.com> wrote:
>>>>>>> Updated https://github.com/apache/royale-asjs/issues/119, can't get the JAVA part to work but changing the AMF endpoint to AMFPHP I get an error code when calling, so maybe that can help further research
>>>>>>> 
>>>>>>>> On Fri, Feb 16, 2018 at 9:21 PM, Fréderic Cox <co...@gmail.com> wrote:
>>>>>>>> Any instructions on how to build the example? This is kind of complicated for me as I have 0 experience with JAVA and even less with Maven ;-)
>>>>>>> 
>>>>>> 
>>>>>> 
>>>>> 
>>>>> 
>>>>> 
>>>>> -- 
>>>>> Carlos Rovira
>>>>> http://about.me/carlosrovira
>>>>> 
>>>> 
>>>> 
>>>> 
>>>> -- 
>>>> Regards,
>>>> Prashant Kumar | Mob.: +91 8408811225
>>> 
>>> 
>>> 
>>> -- 
>>> Carlos Rovira
>>> http://about.me/carlosrovira
>>> 
>>> 
>> 
>> 
>> 
>> -- 
>> Piotr Zarzycki 
>> 
>> Patreon: https://www.patreon.com/piotrzarzycki

Re: RemoteObject

Posted by Prashant Kumar <pr...@gmail.com>.
I could not get chance to look into this. Please go ahead and check this.
If you require any my support, do let me know.

On Sun 1 Apr, 2018, 10:57 PM Piotr Zarzycki, <pi...@gmail.com>
wrote:

> Hi Prashant,
>
> Did you have a chance to look into that case ? If not I'm going in the
> next week look closer to AMF.
>
> Let me know.
>
> Thanks,
> Piotr
>
> 2018-02-21 7:27 GMT+01:00 Prashant Kumar <pr...@gmail.com>:
>
>> Fine, I will investigate this today and update you on the root cause.
>>
>>
>> On 20-Feb-2018 1:53 PM, "Carlos Rovira" <ca...@apache.org> wrote:
>>
>> Hi Prashant,
>>
>> curious. I think we passed an array of typed VOs, and for example Vehicle
>> has only 2 strings and a Date. My VO doesn't have a date property, but I
>> assume that should work. Anyway, could you investigate why that not work?
>> As I said I can support you with pull request if you want. I'm right now
>> focused on new Vivid UI Set that can support themes and visual
>> customization.
>>
>> thanks!
>>
>>
>> 2018-02-18 13:50 GMT+01:00 Prashant Kumar <pr...@gmail.com>:
>>
>>> Following cases not working:
>>>
>>> service.send("passArrayList",[new ArrayList(["Test1","Test2"])]);
>>>
>>> var v1:Vehicle = new Vehicle();
>>> v1.name = "Nexon";
>>> v1.brand = "TATA";
>>> v1.dom = new Date();
>>> service.send("addVehicle",[v1]);
>>>
>>>
>>> On Sat, Feb 17, 2018 at 4:15 PM, Carlos Rovira <ca...@apache.org>
>>> wrote:
>>>
>>>> Hi, I tested some months ago some scenarios with collections sharing
>>>> some VOs, and worked, but I think we should try more scenarios since
>>>> complex object graphs could be problematic.
>>>>
>>>> Thanks Prashant for looking into this. If you can help trying to evolve
>>>> the code I can support you with your pull request to include your changes
>>>> in Royale.
>>>>
>>>>
>>>> 2018-02-17 5:37 GMT+01:00 Prashant Kumar <pr...@gmail.com>:
>>>>
>>>>> Carlos,
>>>>>
>>>>> If I sends only primary type as int , number , date etc then  all
>>>>> works fine but if I sends custom types as a Arraylist , VOs, and other
>>>>> inherited types does not work properly.
>>>>>
>>>>> Regards,
>>>>> Prashant
>>>>>
>>>>> On 17-Feb-2018 2:50 AM, "Fréderic Cox" <co...@gmail.com> wrote:
>>>>>
>>>>> Updated https://github.com/apache/royale-asjs/issues/119, think I am
>>>>> getting closer :-)
>>>>>
>>>>> On Fri, Feb 16, 2018 at 9:51 PM, Fréderic Cox <co...@gmail.com>
>>>>> wrote:
>>>>>
>>>>>> Updated https://github.com/apache/royale-asjs/issues/119, can't get
>>>>>> the JAVA part to work but changing the AMF endpoint to AMFPHP I get an
>>>>>> error code when calling, so maybe that can help further research
>>>>>>
>>>>>> On Fri, Feb 16, 2018 at 9:21 PM, Fréderic Cox <co...@gmail.com>
>>>>>> wrote:
>>>>>>
>>>>>>> Any instructions on how to build the example? This is kind of
>>>>>>> complicated for me as I have 0 experience with JAVA and even less with
>>>>>>> Maven ;-)
>>>>>>>
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>> Carlos Rovira
>>>> http://about.me/carlosrovira
>>>>
>>>>
>>>
>>>
>>> --
>>> *Regards,*
>>> Prashant Kumar* | *Mob.: +91 8408811225 <+91%2084088%2011225>
>>>
>>
>>
>>
>> --
>> Carlos Rovira
>> http://about.me/carlosrovira
>>
>>
>>
>
>
> --
>
> Piotr Zarzycki
>
> Patreon: *https://www.patreon.com/piotrzarzycki
> <https://www.patreon.com/piotrzarzycki>*
>

Re: RemoteObject

Posted by Piotr Zarzycki <pi...@gmail.com>.
Hi Prashant,

Did you have a chance to look into that case ? If not I'm going in the next
week look closer to AMF.

Let me know.

Thanks,
Piotr

2018-02-21 7:27 GMT+01:00 Prashant Kumar <pr...@gmail.com>:

> Fine, I will investigate this today and update you on the root cause.
>
>
> On 20-Feb-2018 1:53 PM, "Carlos Rovira" <ca...@apache.org> wrote:
>
> Hi Prashant,
>
> curious. I think we passed an array of typed VOs, and for example Vehicle
> has only 2 strings and a Date. My VO doesn't have a date property, but I
> assume that should work. Anyway, could you investigate why that not work?
> As I said I can support you with pull request if you want. I'm right now
> focused on new Vivid UI Set that can support themes and visual
> customization.
>
> thanks!
>
>
> 2018-02-18 13:50 GMT+01:00 Prashant Kumar <pr...@gmail.com>:
>
>> Following cases not working:
>>
>> service.send("passArrayList",[new ArrayList(["Test1","Test2"])]);
>>
>> var v1:Vehicle = new Vehicle();
>> v1.name = "Nexon";
>> v1.brand = "TATA";
>> v1.dom = new Date();
>> service.send("addVehicle",[v1]);
>>
>>
>> On Sat, Feb 17, 2018 at 4:15 PM, Carlos Rovira <ca...@apache.org>
>> wrote:
>>
>>> Hi, I tested some months ago some scenarios with collections sharing
>>> some VOs, and worked, but I think we should try more scenarios since
>>> complex object graphs could be problematic.
>>>
>>> Thanks Prashant for looking into this. If you can help trying to evolve
>>> the code I can support you with your pull request to include your changes
>>> in Royale.
>>>
>>>
>>> 2018-02-17 5:37 GMT+01:00 Prashant Kumar <pr...@gmail.com>:
>>>
>>>> Carlos,
>>>>
>>>> If I sends only primary type as int , number , date etc then  all works
>>>> fine but if I sends custom types as a Arraylist , VOs, and other inherited
>>>> types does not work properly.
>>>>
>>>> Regards,
>>>> Prashant
>>>>
>>>> On 17-Feb-2018 2:50 AM, "Fréderic Cox" <co...@gmail.com> wrote:
>>>>
>>>> Updated https://github.com/apache/royale-asjs/issues/119, think I am
>>>> getting closer :-)
>>>>
>>>> On Fri, Feb 16, 2018 at 9:51 PM, Fréderic Cox <co...@gmail.com>
>>>> wrote:
>>>>
>>>>> Updated https://github.com/apache/royale-asjs/issues/119, can't get
>>>>> the JAVA part to work but changing the AMF endpoint to AMFPHP I get an
>>>>> error code when calling, so maybe that can help further research
>>>>>
>>>>> On Fri, Feb 16, 2018 at 9:21 PM, Fréderic Cox <co...@gmail.com>
>>>>> wrote:
>>>>>
>>>>>> Any instructions on how to build the example? This is kind of
>>>>>> complicated for me as I have 0 experience with JAVA and even less with
>>>>>> Maven ;-)
>>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>
>>>
>>> --
>>> Carlos Rovira
>>> http://about.me/carlosrovira
>>>
>>>
>>
>>
>> --
>> *Regards,*
>> Prashant Kumar* | *Mob.: +91 8408811225 <+91%2084088%2011225>
>>
>
>
>
> --
> Carlos Rovira
> http://about.me/carlosrovira
>
>
>


-- 

Piotr Zarzycki

Patreon: *https://www.patreon.com/piotrzarzycki
<https://www.patreon.com/piotrzarzycki>*

Re: RemoteObject

Posted by Prashant Kumar <pr...@gmail.com>.
Fine, I will investigate this today and update you on the root cause.

On 20-Feb-2018 1:53 PM, "Carlos Rovira" <ca...@apache.org> wrote:

Hi Prashant,

curious. I think we passed an array of typed VOs, and for example Vehicle
has only 2 strings and a Date. My VO doesn't have a date property, but I
assume that should work. Anyway, could you investigate why that not work?
As I said I can support you with pull request if you want. I'm right now
focused on new Vivid UI Set that can support themes and visual
customization.

thanks!


2018-02-18 13:50 GMT+01:00 Prashant Kumar <pr...@gmail.com>:

> Following cases not working:
>
> service.send("passArrayList",[new ArrayList(["Test1","Test2"])]);
>
> var v1:Vehicle = new Vehicle();
> v1.name = "Nexon";
> v1.brand = "TATA";
> v1.dom = new Date();
> service.send("addVehicle",[v1]);
>
>
> On Sat, Feb 17, 2018 at 4:15 PM, Carlos Rovira <ca...@apache.org>
> wrote:
>
>> Hi, I tested some months ago some scenarios with collections sharing some
>> VOs, and worked, but I think we should try more scenarios since complex
>> object graphs could be problematic.
>>
>> Thanks Prashant for looking into this. If you can help trying to evolve
>> the code I can support you with your pull request to include your changes
>> in Royale.
>>
>>
>> 2018-02-17 5:37 GMT+01:00 Prashant Kumar <pr...@gmail.com>:
>>
>>> Carlos,
>>>
>>> If I sends only primary type as int , number , date etc then  all works
>>> fine but if I sends custom types as a Arraylist , VOs, and other inherited
>>> types does not work properly.
>>>
>>> Regards,
>>> Prashant
>>>
>>> On 17-Feb-2018 2:50 AM, "Fréderic Cox" <co...@gmail.com> wrote:
>>>
>>> Updated https://github.com/apache/royale-asjs/issues/119, think I am
>>> getting closer :-)
>>>
>>> On Fri, Feb 16, 2018 at 9:51 PM, Fréderic Cox <co...@gmail.com>
>>> wrote:
>>>
>>>> Updated https://github.com/apache/royale-asjs/issues/119, can't get
>>>> the JAVA part to work but changing the AMF endpoint to AMFPHP I get an
>>>> error code when calling, so maybe that can help further research
>>>>
>>>> On Fri, Feb 16, 2018 at 9:21 PM, Fréderic Cox <co...@gmail.com>
>>>> wrote:
>>>>
>>>>> Any instructions on how to build the example? This is kind of
>>>>> complicated for me as I have 0 experience with JAVA and even less with
>>>>> Maven ;-)
>>>>>
>>>>
>>>>
>>>
>>>
>>
>>
>> --
>> Carlos Rovira
>> http://about.me/carlosrovira
>>
>>
>
>
> --
> *Regards,*
> Prashant Kumar* | *Mob.: +91 8408811225 <+91%2084088%2011225>
>



-- 
Carlos Rovira
http://about.me/carlosrovira

Re: RemoteObject

Posted by Carlos Rovira <ca...@apache.org>.
Hi Prashant,

curious. I think we passed an array of typed VOs, and for example Vehicle
has only 2 strings and a Date. My VO doesn't have a date property, but I
assume that should work. Anyway, could you investigate why that not work?
As I said I can support you with pull request if you want. I'm right now
focused on new Vivid UI Set that can support themes and visual
customization.

thanks!


2018-02-18 13:50 GMT+01:00 Prashant Kumar <pr...@gmail.com>:

> Following cases not working:
>
> service.send("passArrayList",[new ArrayList(["Test1","Test2"])]);
>
> var v1:Vehicle = new Vehicle();
> v1.name = "Nexon";
> v1.brand = "TATA";
> v1.dom = new Date();
> service.send("addVehicle",[v1]);
>
>
> On Sat, Feb 17, 2018 at 4:15 PM, Carlos Rovira <ca...@apache.org>
> wrote:
>
>> Hi, I tested some months ago some scenarios with collections sharing some
>> VOs, and worked, but I think we should try more scenarios since complex
>> object graphs could be problematic.
>>
>> Thanks Prashant for looking into this. If you can help trying to evolve
>> the code I can support you with your pull request to include your changes
>> in Royale.
>>
>>
>> 2018-02-17 5:37 GMT+01:00 Prashant Kumar <pr...@gmail.com>:
>>
>>> Carlos,
>>>
>>> If I sends only primary type as int , number , date etc then  all works
>>> fine but if I sends custom types as a Arraylist , VOs, and other inherited
>>> types does not work properly.
>>>
>>> Regards,
>>> Prashant
>>>
>>> On 17-Feb-2018 2:50 AM, "Fréderic Cox" <co...@gmail.com> wrote:
>>>
>>> Updated https://github.com/apache/royale-asjs/issues/119, think I am
>>> getting closer :-)
>>>
>>> On Fri, Feb 16, 2018 at 9:51 PM, Fréderic Cox <co...@gmail.com>
>>> wrote:
>>>
>>>> Updated https://github.com/apache/royale-asjs/issues/119, can't get
>>>> the JAVA part to work but changing the AMF endpoint to AMFPHP I get an
>>>> error code when calling, so maybe that can help further research
>>>>
>>>> On Fri, Feb 16, 2018 at 9:21 PM, Fréderic Cox <co...@gmail.com>
>>>> wrote:
>>>>
>>>>> Any instructions on how to build the example? This is kind of
>>>>> complicated for me as I have 0 experience with JAVA and even less with
>>>>> Maven ;-)
>>>>>
>>>>
>>>>
>>>
>>>
>>
>>
>> --
>> Carlos Rovira
>> http://about.me/carlosrovira
>>
>>
>
>
> --
> *Regards,*
> Prashant Kumar* | *Mob.: +91 8408811225 <+91%2084088%2011225>
>



-- 
Carlos Rovira
http://about.me/carlosrovira

Re: RemoteObject

Posted by Prashant Kumar <pr...@gmail.com>.
Following cases not working:

service.send("passArrayList",[new ArrayList(["Test1","Test2"])]);

var v1:Vehicle = new Vehicle();
v1.name = "Nexon";
v1.brand = "TATA";
v1.dom = new Date();
service.send("addVehicle",[v1]);


On Sat, Feb 17, 2018 at 4:15 PM, Carlos Rovira <ca...@apache.org>
wrote:

> Hi, I tested some months ago some scenarios with collections sharing some
> VOs, and worked, but I think we should try more scenarios since complex
> object graphs could be problematic.
>
> Thanks Prashant for looking into this. If you can help trying to evolve
> the code I can support you with your pull request to include your changes
> in Royale.
>
>
> 2018-02-17 5:37 GMT+01:00 Prashant Kumar <pr...@gmail.com>:
>
>> Carlos,
>>
>> If I sends only primary type as int , number , date etc then  all works
>> fine but if I sends custom types as a Arraylist , VOs, and other inherited
>> types does not work properly.
>>
>> Regards,
>> Prashant
>>
>> On 17-Feb-2018 2:50 AM, "Fréderic Cox" <co...@gmail.com> wrote:
>>
>> Updated https://github.com/apache/royale-asjs/issues/119, think I am
>> getting closer :-)
>>
>> On Fri, Feb 16, 2018 at 9:51 PM, Fréderic Cox <co...@gmail.com>
>> wrote:
>>
>>> Updated https://github.com/apache/royale-asjs/issues/119, can't get the
>>> JAVA part to work but changing the AMF endpoint to AMFPHP I get an error
>>> code when calling, so maybe that can help further research
>>>
>>> On Fri, Feb 16, 2018 at 9:21 PM, Fréderic Cox <co...@gmail.com>
>>> wrote:
>>>
>>>> Any instructions on how to build the example? This is kind of
>>>> complicated for me as I have 0 experience with JAVA and even less with
>>>> Maven ;-)
>>>>
>>>
>>>
>>
>>
>
>
> --
> Carlos Rovira
> http://about.me/carlosrovira
>
>


-- 
*Regards,*
Prashant Kumar* | *Mob.: +91 8408811225

Re: RemoteObject

Posted by Carlos Rovira <ca...@apache.org>.
Hi, I tested some months ago some scenarios with collections sharing some
VOs, and worked, but I think we should try more scenarios since complex
object graphs could be problematic.

Thanks Prashant for looking into this. If you can help trying to evolve the
code I can support you with your pull request to include your changes in
Royale.


2018-02-17 5:37 GMT+01:00 Prashant Kumar <pr...@gmail.com>:

> Carlos,
>
> If I sends only primary type as int , number , date etc then  all works
> fine but if I sends custom types as a Arraylist , VOs, and other inherited
> types does not work properly.
>
> Regards,
> Prashant
>
> On 17-Feb-2018 2:50 AM, "Fréderic Cox" <co...@gmail.com> wrote:
>
> Updated https://github.com/apache/royale-asjs/issues/119, think I am
> getting closer :-)
>
> On Fri, Feb 16, 2018 at 9:51 PM, Fréderic Cox <co...@gmail.com>
> wrote:
>
>> Updated https://github.com/apache/royale-asjs/issues/119, can't get the
>> JAVA part to work but changing the AMF endpoint to AMFPHP I get an error
>> code when calling, so maybe that can help further research
>>
>> On Fri, Feb 16, 2018 at 9:21 PM, Fréderic Cox <co...@gmail.com>
>> wrote:
>>
>>> Any instructions on how to build the example? This is kind of
>>> complicated for me as I have 0 experience with JAVA and even less with
>>> Maven ;-)
>>>
>>
>>
>
>


-- 
Carlos Rovira
http://about.me/carlosrovira

Re: RemoteObject

Posted by Prashant Kumar <pr...@gmail.com>.
Yes, I will share my code.

On 17-Feb-2018 11:12 AM, "Alex Harui" <ah...@adobe.com> wrote:

> Do your VO's have [RemoteClass] metadata?   We did test custom types.
>
> -Alex
>
> From: Prashant Kumar <pr...@gmail.com>
> Reply-To: "users@royale.apache.org" <us...@royale.apache.org>
> Date: Friday, February 16, 2018 at 8:37 PM
> To: "users@royale.apache.org" <us...@royale.apache.org>
> Subject: Re: RemoteObject
>
> Carlos,
>
> If I sends only primary type as int , number , date etc then  all works
> fine but if I sends custom types as a Arraylist , VOs, and other inherited
> types does not work properly.
>
> Regards,
> Prashant
>
> On 17-Feb-2018 2:50 AM, "Fréderic Cox" <co...@gmail.com> wrote:
>
> Updated https://github.com/apache/royale-asjs/issues/119
> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Fissues%2F119&data=02%7C01%7Caharui%40adobe.com%7C9696bb17d3b9460f2ad108d575c029df%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636544390565803206&sdata=yOViePKLHIl9xN8KVA6vW%2BwfX%2BRKww7QFs8X23F7p7E%3D&reserved=0>,
> think I am getting closer :-)
>
> On Fri, Feb 16, 2018 at 9:51 PM, Fréderic Cox <co...@gmail.com>
> wrote:
>
>> Updated https://github.com/apache/royale-asjs/issues/119
>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Fissues%2F119&data=02%7C01%7Caharui%40adobe.com%7C9696bb17d3b9460f2ad108d575c029df%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636544390565803206&sdata=yOViePKLHIl9xN8KVA6vW%2BwfX%2BRKww7QFs8X23F7p7E%3D&reserved=0>,
>> can't get the JAVA part to work but changing the AMF endpoint to AMFPHP I
>> get an error code when calling, so maybe that can help further research
>>
>> On Fri, Feb 16, 2018 at 9:21 PM, Fréderic Cox <co...@gmail.com>
>> wrote:
>>
>>> Any instructions on how to build the example? This is kind of
>>> complicated for me as I have 0 experience with JAVA and even less with
>>> Maven ;-)
>>>
>>
>>
>
>

Re: RemoteObject

Posted by Alex Harui <ah...@adobe.com>.
Do your VO's have [RemoteClass] metadata?   We did test custom types.

-Alex

From: Prashant Kumar <pr...@gmail.com>>
Reply-To: "users@royale.apache.org<ma...@royale.apache.org>" <us...@royale.apache.org>>
Date: Friday, February 16, 2018 at 8:37 PM
To: "users@royale.apache.org<ma...@royale.apache.org>" <us...@royale.apache.org>>
Subject: Re: RemoteObject

Carlos,

If I sends only primary type as int , number , date etc then  all works fine but if I sends custom types as a Arraylist , VOs, and other inherited types does not work properly.

Regards,
Prashant

On 17-Feb-2018 2:50 AM, "Fréderic Cox" <co...@gmail.com>> wrote:
Updated https://github.com/apache/royale-asjs/issues/119<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Fissues%2F119&data=02%7C01%7Caharui%40adobe.com%7C9696bb17d3b9460f2ad108d575c029df%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636544390565803206&sdata=yOViePKLHIl9xN8KVA6vW%2BwfX%2BRKww7QFs8X23F7p7E%3D&reserved=0>, think I am getting closer :-)

On Fri, Feb 16, 2018 at 9:51 PM, Fréderic Cox <co...@gmail.com>> wrote:
Updated https://github.com/apache/royale-asjs/issues/119<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Fissues%2F119&data=02%7C01%7Caharui%40adobe.com%7C9696bb17d3b9460f2ad108d575c029df%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636544390565803206&sdata=yOViePKLHIl9xN8KVA6vW%2BwfX%2BRKww7QFs8X23F7p7E%3D&reserved=0>, can't get the JAVA part to work but changing the AMF endpoint to AMFPHP I get an error code when calling, so maybe that can help further research

On Fri, Feb 16, 2018 at 9:21 PM, Fréderic Cox <co...@gmail.com>> wrote:
Any instructions on how to build the example? This is kind of complicated for me as I have 0 experience with JAVA and even less with Maven ;-)




Re: RemoteObject

Posted by Prashant Kumar <pr...@gmail.com>.
Carlos,

If I sends only primary type as int , number , date etc then  all works
fine but if I sends custom types as a Arraylist , VOs, and other inherited
types does not work properly.

Regards,
Prashant

On 17-Feb-2018 2:50 AM, "Fréderic Cox" <co...@gmail.com> wrote:

Updated https://github.com/apache/royale-asjs/issues/119, think I am
getting closer :-)

On Fri, Feb 16, 2018 at 9:51 PM, Fréderic Cox <co...@gmail.com> wrote:

> Updated https://github.com/apache/royale-asjs/issues/119, can't get the
> JAVA part to work but changing the AMF endpoint to AMFPHP I get an error
> code when calling, so maybe that can help further research
>
> On Fri, Feb 16, 2018 at 9:21 PM, Fréderic Cox <co...@gmail.com>
> wrote:
>
>> Any instructions on how to build the example? This is kind of complicated
>> for me as I have 0 experience with JAVA and even less with Maven ;-)
>>
>
>

Re: RemoteObject

Posted by Fréderic Cox <co...@gmail.com>.
Updated https://github.com/apache/royale-asjs/issues/119, think I am
getting closer :-)

On Fri, Feb 16, 2018 at 9:51 PM, Fréderic Cox <co...@gmail.com> wrote:

> Updated https://github.com/apache/royale-asjs/issues/119, can't get the
> JAVA part to work but changing the AMF endpoint to AMFPHP I get an error
> code when calling, so maybe that can help further research
>
> On Fri, Feb 16, 2018 at 9:21 PM, Fréderic Cox <co...@gmail.com>
> wrote:
>
>> Any instructions on how to build the example? This is kind of complicated
>> for me as I have 0 experience with JAVA and even less with Maven ;-)
>>
>
>

Re: RemoteObject

Posted by Fréderic Cox <co...@gmail.com>.
Updated https://github.com/apache/royale-asjs/issues/119, can't get the
JAVA part to work but changing the AMF endpoint to AMFPHP I get an error
code when calling, so maybe that can help further research

On Fri, Feb 16, 2018 at 9:21 PM, Fréderic Cox <co...@gmail.com> wrote:

> Any instructions on how to build the example? This is kind of complicated
> for me as I have 0 experience with JAVA and even less with Maven ;-)
>

Re: RemoteObject

Posted by Fréderic Cox <co...@gmail.com>.
Any instructions on how to build the example? This is kind of complicated
for me as I have 0 experience with JAVA and even less with Maven ;-)

Re: RemoteObject

Posted by Alex Harui <ah...@adobe.com>.
Hi Fréderic,

You can also try to see if the example in Royale works as-is against Java and then try to get it to work against your PHP backend.

Thanks,
-Alex

From: Fréderic Cox <co...@gmail.com>>
Reply-To: "users@royale.apache.org<ma...@royale.apache.org>" <us...@royale.apache.org>>
Date: Friday, February 16, 2018 at 11:13 AM
To: "users@royale.apache.org<ma...@royale.apache.org>" <us...@royale.apache.org>>
Subject: Re: RemoteObject

Hi Piotr, I updated https://github.com/apache/royale-asjs/issues/119<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Fissues%2F119&data=02%7C01%7Caharui%40adobe.com%7C00c73ff8a6d3456da7d508d575716a67%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636544052344235618&sdata=wf9QWj10HzotEoA%2Bm9hqOZjtRiQ1yZE9c4mFX7XwEH4%3D&reserved=0> which now includes sample code which is working in Flex 4.16 AIR 27. The code should be almost identical to the royale sample.

Please let me know if there is anything else I can do

On Fri, Feb 16, 2018 at 3:59 PM, Piotr Zarzycki <pi...@gmail.com>> wrote:
Frederic,

Could you share some hello world implementation of AMFPHP along with Hello World app in Flex ? I may also look into that and compare the results. Just don't want to waste time on setup things to prepare AMFPHP stuff. Do you have such things ?

Thanks, Piotr


2018-02-16 15:57 GMT+01:00 Fréderic Cox <co...@gmail.com>>:
Hi Carlos,

Sure I’ll see what I can do. Feel I have lots to leatn about Royale and AMF (it just works with Flash/AIR so not up to date about the inner workings).

I’ll try to test the examples over the weekend. Do you think the AMFPHP version could be an issue or is it assumed to work in Royale if it works in Flex?

Verstuurd vanaf mijn iPhone

Op 16 feb. 2018 om 12:28 heeft Carlos Rovira <ca...@apache.org>> het volgende geschreven:

Hi Frederic,
thanks for filling this and take a look into AMF!
Hope you could help us a bit with this.

2018-02-16 0:21 GMT+01:00 Fréderic Cox <co...@gmail.com>>:
Hi Alex,

I created https://github.com/apache/royale-asjs/issues/119<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Fissues%2F119&data=02%7C01%7Caharui%40adobe.com%7C00c73ff8a6d3456da7d508d575716a67%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636544052344235618&sdata=wf9QWj10HzotEoA%2Bm9hqOZjtRiQ1yZE9c4mFX7XwEH4%3D&reserved=0>, hope that is in the correct place and with more readable mark-up.

Regards,

Fréderic

On Thu, Feb 15, 2018 at 8:57 PM, Alex Harui <ah...@adobe.com>> wrote:
Hi Frederic,

Where is this output you posted coming from, a network monitor?  It was too hard to read, so please create a bug report on GitHub and post it there.

You might be able to use a network monitor to compare what Flex sent vs what Royale is sending.  What does your Flex usage of RemoteObject look like?

HTH,
-Alex

From: Fréderic Cox <co...@gmail.com>>
Reply-To: "users@royale.apache.org<ma...@royale.apache.org>" <us...@royale.apache.org>>
Date: Thursday, February 15, 2018 at 5:09 AM
To: "users@royale.apache.org<ma...@royale.apache.org>" <us...@royale.apache.org>>
Subject: Re: RemoteObject

Hi Piotr,

Thanks, I installed the extension and now I'm not getting the CORS error anymore.
I'm not getting any fault or result event triggered either....

The endPoint set is
https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fclients.cityfashion.dev.exuvis.com%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=67VMfKVGZo%2BarMstlt%2BZbX5OdTomYDQNSgM07ycK%2Bvc%3D&reserved=0>

This is correct, right? (I use this endpoint in Flex and that works fine)


     *
Request URL:
https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fclients.cityfashion.dev.exuvis.com%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=67VMfKVGZo%2BarMstlt%2BZbX5OdTomYDQNSgM07ycK%2Bvc%3D&reserved=0>
     *
Request Method:
OPTIONS
     *
Status Code:
200 OK
     *
Remote Address:
188.93.153.101:443<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2F188.93.153.101%3A443&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=UWqG%2BqQTcL1fTnck9i5BPXmrn3ZlgRf8XCPpQ8EcJrE%3D&reserved=0>
     *
Referrer Policy:
no-referrer-when-downgrade
  1.  Response Headersview source
     *
Connection:
keep-alive
     *
Content-Encoding:
gzip
     *
Content-Length:
286
     *
Content-Type:
text/html; charset=UTF-8
     *
Date:
Thu, 15 Feb 2018 13:08:17 GMT
     *
Server:
nginx
     *
Vary:
Accept-Encoding
  2.  Request Headersview source
     *
Accept:
*/*
     *
Accept-Encoding:
gzip, deflate, br
     *
Accept-Language:
en-GB,en-US;q=0.9,en;q=0.8
     *
Access-Control-Request-Headers:
content-type
     *
Access-Control-Request-Method:
POST
     *
Connection:
keep-alive
     *
Host:
clients.cityfashion.dev.exuvis.com<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fclients.cityfashion.dev.exuvis.com&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=%2BiTohXW1uaTpydtAlGWa0leTvEQKK2Wg6XtN%2FqQ73%2F0%3D&reserved=0>
     *
Origin:
null
     *
User-Agent:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_3) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.167 Safari/537.36

Response is:

<p>amfphp and this gateway are installed correctly. You may now connect to this gateway from Flash.</p><p>Note: If you're reading an old tutorial, it will tell you that you should see a download window instead of this message. This confused people so this is the new behaviour starting from amfphp 1.2.</p><p><a href='http://www.amfphp.org/docs<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.amfphp.org%2Fdocs&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=%2FGtfS6iuQCrcoifQ5pUOXPJ0JJZcOQaMyYsscjKzA9I%3D&reserved=0>'>View the amfphp documentation</p><p><a href='browser'>Load the service browser</a></p><pre>

Should I target a specific file with the JS version? Should the endPoint be different?

On Thu, Feb 15, 2018 at 12:07 PM, Piotr Zarzycki <pi...@gmail.com>> wrote:
Frederic,

It looks like it is not problem with framework, but rather CORS issue. Maybe try to install this plugin [1] and add to the list your url.

[1] https://chrome.google.com/webstore/detail/allow-control-allow-origi/nlfbmbojpeacfghkpbjhddihlkkiljbi?hl=en<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fchrome.google.com%2Fwebstore%2Fdetail%2Fallow-control-allow-origi%2Fnlfbmbojpeacfghkpbjhddihlkkiljbi%3Fhl%3Den&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=CbZH3KQcH0oGU%2FbnBtyVp%2B9zeqDEUcK9Y6UFd0BIESM%3D&reserved=0>

Piotr

2018-02-15 12:04 GMT+01:00 Fréderic Cox <co...@gmail.com>>:
For me it is still not working in latest release 0.9.1. I based my example on the example in the SDK.

<?xml version="1.0" encoding="utf-8"?>
<js:Applicationxmlns:fx="http://ns.adobe.com/mxml/2009<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.adobe.com%2Fmxml%2F2009&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7cSxKCospCIpbkKY4F%2Fp5lsHBH%2BPFp5Vny2ftXWmL5A%3D&reserved=0>"
xmlns:js="library://ns.apache.org/royale/basic<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.apache.org%2Froyale%2Fbasic&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=D%2FBslvPtV9pNNjpoS4KCQlYHB8ArUYEIXCXuAVoNgYM%3D&reserved=0>"applicationComplete="applicationCompleteHandler(event);">

    <fx:Script>
        <![CDATA[
            import org.apache.royale.net<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Forg.apache.royale.net&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=ATrXbo2PLqz1dNeyvxVu89zy3yaKPxwIwQm9tSG7ybs%3D&reserved=0>.RemoteObject;
            import org.apache.royale.net.events.FaultEvent;
            import org.apache.royale.net.events.ResultEvent;

            privatefunctionapplicationCompleteHandler(evt:Event):void{
                testLabel.text = "Requesting from AMF";
                service.send("getPackages", null);
            }

            privatefunctionamfFaultHandler(evt:FaultEvent):void{
                testLabel.text = "Fault in calling AMF";
            }

            privatefunctionamfResultHandler(evt:ResultEvent):void{
                testLabel.text = "Result received from AMF";
            }
        ]]>
    </fx:Script>

<js:valuesImpl>
<js:SimpleCSSValuesImpl />
</js:valuesImpl>

   <js:beads>
<js:ClassAliasBead />
<js:RemoteObjectid="service"result="amfResultHandler(event)"fault="amfFaultHandler(event)"
endPoint = "https://winkelbeheer.cityfashion.be/amfphp/gateway.php<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=mARoGAlKZYBWmNOBwqTpTRYkqG%2Fk0cvrHwR5kgbfNFY%3D&reserved=0>"
destination = "Meta"
source = "Meta"/>
</js:beads>

<js:initialView>
<js:View>
<js:Labelid="testLabel" />
</js:View>
</js:initialView>
</js:Application>


It is not working and showing the following error in the browser:

Failed to load https://winkelbeheer.cityfashion.be/amfphp/gateway.php<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=mARoGAlKZYBWmNOBwqTpTRYkqG%2Fk0cvrHwR5kgbfNFY%3D&reserved=0>: Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://localhost' is therefore not allowed access.
Language.js:238destination fault handler

  1.  {code: -1004, message: "Invalid response type.", detail: "Invalid XMLHttpRequest response status or type.", data: null}
     *   code:-1004
     *   data:null
     *   detail:"Invalid XMLHttpRequest response status or type."
     *   message:"Invalid response type."
     *   __proto__:Object



It is able to compile and run regardless of the errors in compile log:

Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager println
SEVERE: /Users/frederic/Desktop/Personal/Web Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apache/royale/reflection/AccessorDefinition.js:12: ERROR - required "org.apache.royale.reflection.TypeDefinition" namespace not provided yet
goog.require('org.apache.royale.reflection.TypeDefinition');
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager println
SEVERE: /Users/frederic/Desktop/Personal/Web Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apache/royale/reflection/AccessorDefinition.js:13: ERROR - required "org.apache.royale.reflection.VariableDefinition" namespace not provided yet
goog.require('org.apache.royale.reflection.VariableDefinition');
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager println
SEVERE: /Users/frederic/Desktop/Personal/Web Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apache/royale/reflection/MethodDefinition.js:14: ERROR - required "org.apache.royale.reflection.TypeDefinition" namespace not provided yet
goog.require('org.apache.royale.reflection.TypeDefinition');
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager println
SEVERE: /Users/frederic/Desktop/Personal/Web Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apache/royale/reflection/ParameterDefinition.js:13: ERROR- required "org.apache.royale.reflection.TypeDefinition" namespace not provided yet
goog.require('org.apache.royale.reflection.TypeDefinition');
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager println
SEVERE: /Users/frederic/Desktop/Personal/Web Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apache/royale/reflection/TypeDefinition.js:15: ERROR - required "org.apache.royale.reflection.VariableDefinition" namespace not provided yet
goog.require('org.apache.royale.reflection.VariableDefinition');
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager printSummary
WARNING: 5 error(s), 0 warning(s)
The project 'HelloRoyale' has been successfully compiled and optimized.
4.566387 seconds


On Mon, Jan 15, 2018 at 7:38 PM, Piotr Zarzycki <pi...@gmail.com>> wrote:
Carlos,

No problem. I have also couple of huge things related to Royale to do before my hand gets dirty with AMF! :) Unless someone urgently will needed. :)

Thanks, Piotr

2018-01-15 19:27 GMT+01:00 Carlos Rovira <ca...@apache.org>>:
Hi Piotr,
I'll put this on my to do list, but have to do some things first.
thanks

2018-01-15 9:26 GMT+01:00 Piotr Zarzycki <pi...@gmail.com>>:
Hi Carlos,

Can you describe more how to setup those examples ? Could you add to RemoteObjectAMFTest README.md file where you describe steps. I would like to have AMF on my list for tests and improvements. Whenever I look into that I don't know how to proceed with it.

Thanks, Piotr

2018-01-15 9:21 GMT+01:00 Carlos Rovira <ca...@apache.org>>:
Hi,

there's an example that we get it working nicely at:

https://github.com/apache/royale-asjs/tree/develop/examples/royale/RemoteObjectAMFTest<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Ftree%2Fdevelop%2Fexamples%2Froyale%2FRemoteObjectAMFTest&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7kdc48rEQiaI4Qp%2BBdfBcGPxddZIYrTUXrQ%2BN2u4tto%3D&reserved=0>

you can use that as a starting point for your test

As well a java web app that is used along that royale client example is at:

https://github.com/apache/royale-asjs/tree/develop/examples/amf<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Ftree%2Fdevelop%2Fexamples%2Famf&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=PW4DYIeW4PetVe6BdFYjxFeAjCrqofPYtdbRTnJ4xjk%3D&reserved=0>

thanks


2018-01-15 3:56 GMT+01:00 Carlos Cruz <ca...@nbtbizcapital.com>>:
I have a lot of experience with Flex remoting and BlazeDS with Java, but with FlexJS and Royale I have none, but extrapolating from some JS tests I've done with AMF at this line: amfTestService.send("getShippingMethods", []); you have to call a class in gateway.php and a method. Your request needs at least 3 properties.

I'm also assuming your JS file and gateway.php are in the same domain and same port (this gave me problems).

Take what I said regarding my experience with FlexJS and Royale into account.

Carlos


From: Fréderic Cox [mailto:coxfrederic@gmail.com<ma...@gmail.com>]
Sent: Sunday, January 14, 2018 4:01 PM

To: users@royale.apache.org<ma...@royale.apache.org>
Subject: Re: RemoteObject

Script tag was stripped from the post:


import org.apache.royale.events.MouseEvent;

                     import org.apache.royale.net.events.FaultEvent;

                     import org.apache.royale.net.events.ResultEvent;



                     protectedfunction textbutton_clickHandler(event:org.apache.royale.events.MouseEvent):void

                     {

                           statusLabel.text = "calling.......";

                           amfTestService.addEventListener("fault", amfTestService_faultHandler);

                           amfTestService.addEventListener("result", amfTestService_resultHandler);

                           amfTestService.send("getShippingMethods", []);

                     }



                     protectedfunction amfTestService_faultHandler(event:FaultEvent):void

                     {

                           statusLabel.text = "error!";

                     }



                     protectedfunction amfTestService_resultHandler(event:ResultEvent):void

                     {

                           statusLabel.text = "result!";

                     }



none of the events are triggered ..URL is http://winkelbeheer.cityfashion.be/amfphp/gateway.php<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=EJDBQBL83yBhDn%2BWWgCCVyw0N3tnakhZ7UdEt4JFNaY%3D&reserved=0>

On Fri, Jan 12, 2018 at 4:55 AM, Carlos Cruz <ca...@nbtbizcapital.com>> wrote:
I may be blind (and or ignorant as I'm more familiar with Flex) but where
are you sending an AMF request? I don't see any code that sends a request to
a service and invokes method.

-----Original Message-----
From: coxfrederic [mailto:coxfrederic@gmail.com<ma...@gmail.com>]
Sent: Thursday, January 11, 2018 9:09 PM
To: users@royale.apache.org<ma...@royale.apache.org>
Subject: Re: RemoteObject

<?xml version="1.0" encoding="utf-8"?>

<js:Application xmlns:fx="http://ns.adobe.com/mxml/2009<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.adobe.com%2Fmxml%2F2009&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7cSxKCospCIpbkKY4F%2Fp5lsHBH%2BPFp5Vny2ftXWmL5A%3D&reserved=0>"
                   xmlns:js="library://ns.apache.org/royale/basic<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.apache.org%2Froyale%2Fbasic&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=D%2FBslvPtV9pNNjpoS4KCQlYHB8ArUYEIXCXuAVoNgYM%3D&reserved=0>" >
        <fx:Script>

        </fx:Script>
    <js:valuesImpl>
        <js:SimpleCSSValuesImpl />
    </js:valuesImpl>

        <js:beads>
                <js:ClassAliasBead />
                <js:RemoteObject id="amfTestService"

endPoint="http://winkelbeheer.cityfashion.be/amfphp/gateway.php<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=EJDBQBL83yBhDn%2BWWgCCVyw0N3tnakhZ7UdEt4JFNaY%3D&reserved=0>"
                                                 destination="Meta"
source="Meta" />
        </js:beads>

    <js:initialView>
        <js:View>
                        <js:VGroup>
                                <js:Label id="statusLabel" text="Hello
World!" />
                                <js:TextButton text="Get AMF data"
click="textbutton_clickHandler(event)" />
                        </js:VGroup>
        </js:View>
    </js:initialView>
</js:Application>


Any idea why I'm not getting a fault nor success event on this?



--
Sent from: http://apache-royale-users.20374.n8.nabble.com/<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fapache-royale-users.20374.n8.nabble.com%2F&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=xvY8nK1QKlWduh6p5x8y19jm%2Br60PSFVlNdi6TRsPmw%3D&reserved=0>




--
Carlos Rovira
http://about.me/carlosrovira<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fabout.me%2Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=55MSUXBM2zE5U0csgV1harcuXvKyZ2gd%2BO%2FmD7hjJ50%3D&reserved=0>




--

Piotr Zarzycki

Patreon: https://www.patreon.com/piotrzarzycki<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=NG2rkkxhfc7MTSVRqHzEmHL8HuUpvXI72B9nkW2QfdU%3D&reserved=0>



--
Carlos Rovira
http://about.me/carlosrovira<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fabout.me%2Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=55MSUXBM2zE5U0csgV1harcuXvKyZ2gd%2BO%2FmD7hjJ50%3D&reserved=0>




--

Piotr Zarzycki

Patreon: https://www.patreon.com/piotrzarzycki<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=NG2rkkxhfc7MTSVRqHzEmHL8HuUpvXI72B9nkW2QfdU%3D&reserved=0>




--

Piotr Zarzycki

Patreon: https://www.patreon.com/piotrzarzycki<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=NG2rkkxhfc7MTSVRqHzEmHL8HuUpvXI72B9nkW2QfdU%3D&reserved=0>





--
Carlos Rovira
http://about.me/carlosrovira<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fabout.me%2Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com%7C00c73ff8a6d3456da7d508d575716a67%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636544052344235618&sdata=lYlECtn4uCWqIxvFdlN%2B9kVs4137ytSYwGUEPhnsS7o%3D&reserved=0>




--

Piotr Zarzycki

Patreon: https://www.patreon.com/piotrzarzycki<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C00c73ff8a6d3456da7d508d575716a67%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636544052344235618&sdata=WkbwjTUl3cXjxHMfmvwq3MOFSIYr2f5cnh0%2FMH7M0Yg%3D&reserved=0>


Re: RemoteObject

Posted by Fréderic Cox <co...@gmail.com>.
Hi Piotr, I updated https://github.com/apache/royale-asjs/issues/119 which
now includes sample code which is working in Flex 4.16 AIR 27. The code
should be almost identical to the royale sample.

Please let me know if there is anything else I can do

On Fri, Feb 16, 2018 at 3:59 PM, Piotr Zarzycki <pi...@gmail.com>
wrote:

> Frederic,
>
> Could you share some hello world implementation of AMFPHP along with Hello
> World app in Flex ? I may also look into that and compare the results. Just
> don't want to waste time on setup things to prepare AMFPHP stuff. Do you
> have such things ?
>
> Thanks, Piotr
>
>
> 2018-02-16 15:57 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>
>> Hi Carlos,
>>
>> Sure I’ll see what I can do. Feel I have lots to leatn about Royale and
>> AMF (it just works with Flash/AIR so not up to date about the inner
>> workings).
>>
>> I’ll try to test the examples over the weekend. Do you think the AMFPHP
>> version could be an issue or is it assumed to work in Royale if it works in
>> Flex?
>>
>> Verstuurd vanaf mijn iPhone
>>
>> Op 16 feb. 2018 om 12:28 heeft Carlos Rovira <ca...@apache.org>
>> het volgende geschreven:
>>
>> Hi Frederic,
>> thanks for filling this and take a look into AMF!
>> Hope you could help us a bit with this.
>>
>> 2018-02-16 0:21 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>>
>>> Hi Alex,
>>>
>>> I created https://github.com/apache/royale-asjs/issues/119, hope that
>>> is in the correct place and with more readable mark-up.
>>>
>>> Regards,
>>>
>>> Fréderic
>>>
>>> On Thu, Feb 15, 2018 at 8:57 PM, Alex Harui <ah...@adobe.com> wrote:
>>>
>>>> Hi Frederic,
>>>>
>>>> Where is this output you posted coming from, a network monitor?  It was
>>>> too hard to read, so please create a bug report on GitHub and post it there.
>>>>
>>>> You might be able to use a network monitor to compare what Flex sent vs
>>>> what Royale is sending.  What does your Flex usage of RemoteObject look
>>>> like?
>>>>
>>>> HTH,
>>>> -Alex
>>>>
>>>> From: Fréderic Cox <co...@gmail.com>
>>>> Reply-To: "users@royale.apache.org" <us...@royale.apache.org>
>>>> Date: Thursday, February 15, 2018 at 5:09 AM
>>>> To: "users@royale.apache.org" <us...@royale.apache.org>
>>>> Subject: Re: RemoteObject
>>>>
>>>> Hi Piotr,
>>>>
>>>> Thanks, I installed the extension and now I'm not getting the CORS
>>>> error anymore.
>>>> I'm not getting any fault or result event triggered either....
>>>>
>>>> The endPoint set is
>>>> https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php
>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fclients.cityfashion.dev.exuvis.com%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=67VMfKVGZo%2BarMstlt%2BZbX5OdTomYDQNSgM07ycK%2Bvc%3D&reserved=0>
>>>>
>>>> This is correct, right? (I use this endpoint in Flex and that works
>>>> fine)
>>>>
>>>>
>>>>    1. Request URL:
>>>>       https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php
>>>>       <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fclients.cityfashion.dev.exuvis.com%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=67VMfKVGZo%2BarMstlt%2BZbX5OdTomYDQNSgM07ycK%2Bvc%3D&reserved=0>
>>>>       2. Request Method:
>>>>       OPTIONS
>>>>       3. Status Code:
>>>>       200 OK
>>>>       4. Remote Address:
>>>>       188.93.153.101:443
>>>>       <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2F188.93.153.101%3A443&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=UWqG%2BqQTcL1fTnck9i5BPXmrn3ZlgRf8XCPpQ8EcJrE%3D&reserved=0>
>>>>       5. Referrer Policy:
>>>>       no-referrer-when-downgrade
>>>>       1. Response Headersview source
>>>>       1. Connection:
>>>>       keep-alive
>>>>       2. Content-Encoding:
>>>>       gzip
>>>>       3. Content-Length:
>>>>       286
>>>>       4. Content-Type:
>>>>       text/html; charset=UTF-8
>>>>       5. Date:
>>>>       Thu, 15 Feb 2018 13:08:17 GMT
>>>>       6. Server:
>>>>       nginx
>>>>       7. Vary:
>>>>       Accept-Encoding
>>>>       2. Request Headersview source
>>>>       1. Accept:
>>>>       */*
>>>>       2. Accept-Encoding:
>>>>       gzip, deflate, br
>>>>       3. Accept-Language:
>>>>       en-GB,en-US;q=0.9,en;q=0.8
>>>>       4. Access-Control-Request-Headers:
>>>>       content-type
>>>>       5. Access-Control-Request-Method:
>>>>       POST
>>>>       6. Connection:
>>>>       keep-alive
>>>>       7. Host:
>>>>       clients.cityfashion.dev.exuvis.com
>>>>       <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fclients.cityfashion.dev.exuvis.com&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=%2BiTohXW1uaTpydtAlGWa0leTvEQKK2Wg6XtN%2FqQ73%2F0%3D&reserved=0>
>>>>       8. Origin:
>>>>       null
>>>>       9. User-Agent:
>>>>       Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_3)
>>>>       AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.167 Safari/537.36
>>>>
>>>> Response is:
>>>>
>>>> <p>amfphp and this gateway are installed correctly. You may now connect
>>>> to this gateway from Flash.</p><p>Note: If you're reading an old tutorial,
>>>> it will tell you that you should see a download window instead of this
>>>> message. This confused people so this is the new behaviour starting from
>>>> amfphp 1.2.</p><p><a href='http://www.amfphp.org/docs
>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.amfphp.org%2Fdocs&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=%2FGtfS6iuQCrcoifQ5pUOXPJ0JJZcOQaMyYsscjKzA9I%3D&reserved=0>'>View
>>>> the amfphp documentation</p><p><a href='browser'>Load the service
>>>> browser</a></p><pre>
>>>>
>>>> Should I target a specific file with the JS version? Should the
>>>> endPoint be different?
>>>>
>>>> On Thu, Feb 15, 2018 at 12:07 PM, Piotr Zarzycki <
>>>> piotrzarzycki21@gmail.com> wrote:
>>>>
>>>>> Frederic,
>>>>>
>>>>> It looks like it is not problem with framework, but rather CORS issue.
>>>>> Maybe try to install this plugin [1] and add to the list your url.
>>>>>
>>>>> [1] https://chrome.google.com/webstore/detail/allow-control-
>>>>> allow-origi/nlfbmbojpeacfghkpbjhddihlkkiljbi?hl=en
>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fchrome.google.com%2Fwebstore%2Fdetail%2Fallow-control-allow-origi%2Fnlfbmbojpeacfghkpbjhddihlkkiljbi%3Fhl%3Den&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=CbZH3KQcH0oGU%2FbnBtyVp%2B9zeqDEUcK9Y6UFd0BIESM%3D&reserved=0>
>>>>>
>>>>> Piotr
>>>>>
>>>>> 2018-02-15 12:04 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>>>>>
>>>>>> For me it is still not working in latest release 0.9.1. I based my
>>>>>> example on the example in the SDK.
>>>>>>
>>>>>> <?xml version="1.0" encoding="utf-8"?>
>>>>>> <js:Applicationxmlns:fx="http://ns.adobe.com/mxml/2009
>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.adobe.com%2Fmxml%2F2009&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7cSxKCospCIpbkKY4F%2Fp5lsHBH%2BPFp5Vny2ftXWmL5A%3D&reserved=0>
>>>>>> "
>>>>>> xmlns:js="library://ns.apache.org/royale/basic
>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.apache.org%2Froyale%2Fbasic&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=D%2FBslvPtV9pNNjpoS4KCQlYHB8ArUYEIXCXuAVoNgYM%3D&reserved=0>
>>>>>> "applicationComplete="applicationCompleteHandler(event);">
>>>>>>
>>>>>>     <fx:Script>
>>>>>>         <![CDATA[
>>>>>>             import org.apache.royale.net
>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Forg.apache.royale.net&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=ATrXbo2PLqz1dNeyvxVu89zy3yaKPxwIwQm9tSG7ybs%3D&reserved=0>
>>>>>> .RemoteObject;
>>>>>>             import org.apache.royale.net.events.FaultEvent;
>>>>>>             import org.apache.royale.net.events.ResultEvent;
>>>>>>
>>>>>>             privatefunctionapplicationCompleteHandler(evt:Event):void
>>>>>> {
>>>>>>                 testLabel.text = "Requesting from AMF";
>>>>>>                 service.send("getPackages", null);
>>>>>>             }
>>>>>>
>>>>>>             privatefunctionamfFaultHandler(evt:FaultEvent):void{
>>>>>>                 testLabel.text = "Fault in calling AMF";
>>>>>>             }
>>>>>>
>>>>>>             privatefunctionamfResultHandler(evt:ResultEvent):void{
>>>>>>                 testLabel.text = "Result received from AMF";
>>>>>>             }
>>>>>>         ]]>
>>>>>>     </fx:Script>
>>>>>>
>>>>>> <js:valuesImpl>
>>>>>> <js:SimpleCSSValuesImpl />
>>>>>> </js:valuesImpl>
>>>>>>
>>>>>>    <js:beads>
>>>>>> <js:ClassAliasBead />
>>>>>> <js:RemoteObjectid="service"result="amfResultHandler(event)"fault=
>>>>>> "amfFaultHandler(event)"
>>>>>> endPoint = "https://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=mARoGAlKZYBWmNOBwqTpTRYkqG%2Fk0cvrHwR5kgbfNFY%3D&reserved=0>
>>>>>> "
>>>>>> destination = "Meta"
>>>>>> source = "Meta"/>
>>>>>> </js:beads>
>>>>>>
>>>>>> <js:initialView>
>>>>>> <js:View>
>>>>>> <js:Labelid="testLabel" />
>>>>>> </js:View>
>>>>>> </js:initialView>
>>>>>> </js:Application>
>>>>>>
>>>>>>
>>>>>> It is not working and showing the following error in the browser:
>>>>>>
>>>>>> Failed to load https://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=mARoGAlKZYBWmNOBwqTpTRYkqG%2Fk0cvrHwR5kgbfNFY%3D&reserved=0>:
>>>>>> Response to preflight request doesn't pass access control check: No
>>>>>> 'Access-Control-Allow-Origin' header is present on the requested resource.
>>>>>> Origin 'http://localhost' is therefore not allowed access.
>>>>>> Language.js:238destination fault handler
>>>>>>
>>>>>>    1. {code: -1004, message: "Invalid response type.", detail: "Invalid
>>>>>>    XMLHttpRequest response status or type.", data: null}
>>>>>>       1. code:-1004
>>>>>>       2. data:null
>>>>>>       3. detail:"Invalid XMLHttpRequest response status or type."
>>>>>>       4. message:"Invalid response type."
>>>>>>       5. __proto__:Object
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> It is able to compile and run regardless of the errors in compile log:
>>>>>>
>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>> println
>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>> he/royale/reflection/AccessorDefinition.js:12: ERROR - required
>>>>>> "org.apache.royale.reflection.TypeDefinition" namespace not provided
>>>>>> yet
>>>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>
>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>> println
>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>> he/royale/reflection/AccessorDefinition.js:13: ERROR - required
>>>>>> "org.apache.royale.reflection.VariableDefinition" namespace not
>>>>>> provided yet
>>>>>> goog.require('org.apache.royale.reflection.VariableDefinition');
>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>
>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>> println
>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>> he/royale/reflection/MethodDefinition.js:14: ERROR - required
>>>>>> "org.apache.royale.reflection.TypeDefinition" namespace not provided
>>>>>> yet
>>>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>
>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>> println
>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>> he/royale/reflection/ParameterDefinition.js:13: ERROR- required
>>>>>> "org.apache.royale.reflection.TypeDefinition" namespace not provided
>>>>>> yet
>>>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>
>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>> println
>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>> he/royale/reflection/TypeDefinition.js:15: ERROR - required
>>>>>> "org.apache.royale.reflection.VariableDefinition" namespace not
>>>>>> provided yet
>>>>>> goog.require('org.apache.royale.reflection.VariableDefinition');
>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>
>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>> printSummary
>>>>>> WARNING: 5 error(s), 0 warning(s)
>>>>>> The project 'HelloRoyale' has been successfully compiled and
>>>>>> optimized.
>>>>>> 4.566387 seconds
>>>>>>
>>>>>>
>>>>>> On Mon, Jan 15, 2018 at 7:38 PM, Piotr Zarzycki <
>>>>>> piotrzarzycki21@gmail.com> wrote:
>>>>>>
>>>>>>> Carlos,
>>>>>>>
>>>>>>> No problem. I have also couple of huge things related to Royale to
>>>>>>> do before my hand gets dirty with AMF! :) Unless someone urgently will
>>>>>>> needed. :)
>>>>>>>
>>>>>>> Thanks, Piotr
>>>>>>>
>>>>>>> 2018-01-15 19:27 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>>>>>>>
>>>>>>>> Hi Piotr,
>>>>>>>> I'll put this on my to do list, but have to do some things first.
>>>>>>>> thanks
>>>>>>>>
>>>>>>>> 2018-01-15 9:26 GMT+01:00 Piotr Zarzycki <piotrzarzycki21@gmail.com
>>>>>>>> >:
>>>>>>>>
>>>>>>>>> Hi Carlos,
>>>>>>>>>
>>>>>>>>> Can you describe more how to setup those examples ? Could you add
>>>>>>>>> to RemoteObjectAMFTest README.md file where you describe steps. I would
>>>>>>>>> like to have AMF on my list for tests and improvements. Whenever I look
>>>>>>>>> into that I don't know how to proceed with it.
>>>>>>>>>
>>>>>>>>> Thanks, Piotr
>>>>>>>>>
>>>>>>>>> 2018-01-15 9:21 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>>>>>>>>>
>>>>>>>>>> Hi,
>>>>>>>>>>
>>>>>>>>>> there's an example that we get it working nicely at:
>>>>>>>>>>
>>>>>>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/
>>>>>>>>>> royale/RemoteObjectAMFTest
>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Ftree%2Fdevelop%2Fexamples%2Froyale%2FRemoteObjectAMFTest&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7kdc48rEQiaI4Qp%2BBdfBcGPxddZIYrTUXrQ%2BN2u4tto%3D&reserved=0>
>>>>>>>>>>
>>>>>>>>>> you can use that as a starting point for your test
>>>>>>>>>>
>>>>>>>>>> As well a java web app that is used along that royale client
>>>>>>>>>> example is at:
>>>>>>>>>>
>>>>>>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/amf
>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Ftree%2Fdevelop%2Fexamples%2Famf&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=PW4DYIeW4PetVe6BdFYjxFeAjCrqofPYtdbRTnJ4xjk%3D&reserved=0>
>>>>>>>>>>
>>>>>>>>>> thanks
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> 2018-01-15 3:56 GMT+01:00 Carlos Cruz <ca...@nbtbizcapital.com>:
>>>>>>>>>>
>>>>>>>>>>> I have a lot of experience with Flex remoting and BlazeDS with
>>>>>>>>>>> Java, but with FlexJS and Royale I have none, but extrapolating from some
>>>>>>>>>>> JS tests I've done with AMF at this line: amfTestService.send(
>>>>>>>>>>> "getShippingMethods", []); you have to call a class in
>>>>>>>>>>> gateway.php and a method. Your request needs at least 3 properties.
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> I'm also assuming your JS file and gateway.php are in the same
>>>>>>>>>>> domain and same port (this gave me problems).
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Take what I said regarding my experience with FlexJS and Royale
>>>>>>>>>>> into account.
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Carlos
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> *From:* Fréderic Cox [mailto:coxfrederic@gmail.com]
>>>>>>>>>>> *Sent:* Sunday, January 14, 2018 4:01 PM
>>>>>>>>>>>
>>>>>>>>>>> *To:* users@royale.apache.org
>>>>>>>>>>> *Subject:* Re: RemoteObject
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Script tag was stripped from the post:
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> import org.apache.royale.events.MouseEvent;
>>>>>>>>>>>
>>>>>>>>>>>                      import org.apache.royale.net.events.F
>>>>>>>>>>> aultEvent;
>>>>>>>>>>>
>>>>>>>>>>>                      import org.apache.royale.net.events.R
>>>>>>>>>>> esultEvent;
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>                      protectedfunction
>>>>>>>>>>> textbutton_clickHandler(event:org.apache.royale.events.Mouse
>>>>>>>>>>> Event):void
>>>>>>>>>>>
>>>>>>>>>>>                      {
>>>>>>>>>>>
>>>>>>>>>>>                            statusLabel.text = "calling.......";
>>>>>>>>>>>
>>>>>>>>>>>                            amfTestService.addEventListener(
>>>>>>>>>>> "fault", amfTestService_faultHandler);
>>>>>>>>>>>
>>>>>>>>>>>                            amfTestService.addEventListener(
>>>>>>>>>>> "result", amfTestService_resultHandler);
>>>>>>>>>>>
>>>>>>>>>>>                            amfTestService.send("getShippi
>>>>>>>>>>> ngMethods", []);
>>>>>>>>>>>
>>>>>>>>>>>                      }
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>                      protectedfunction
>>>>>>>>>>> amfTestService_faultHandler(event:FaultEvent):void
>>>>>>>>>>>
>>>>>>>>>>>                      {
>>>>>>>>>>>
>>>>>>>>>>>                            statusLabel.text = "error!";
>>>>>>>>>>>
>>>>>>>>>>>                      }
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>                      protectedfunction
>>>>>>>>>>> amfTestService_resultHandler(event:ResultEvent):void
>>>>>>>>>>>
>>>>>>>>>>>                      {
>>>>>>>>>>>
>>>>>>>>>>>                            statusLabel.text = "result!";
>>>>>>>>>>>
>>>>>>>>>>>                      }
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> none of the events are triggered ..URL is
>>>>>>>>>>> http://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=EJDBQBL83yBhDn%2BWWgCCVyw0N3tnakhZ7UdEt4JFNaY%3D&reserved=0>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> On Fri, Jan 12, 2018 at 4:55 AM, Carlos Cruz <
>>>>>>>>>>> carlos@nbtbizcapital.com> wrote:
>>>>>>>>>>>
>>>>>>>>>>> I may be blind (and or ignorant as I'm more familiar with Flex)
>>>>>>>>>>> but where
>>>>>>>>>>> are you sending an AMF request? I don't see any code that sends
>>>>>>>>>>> a request to
>>>>>>>>>>> a service and invokes method.
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> -----Original Message-----
>>>>>>>>>>> From: coxfrederic [mailto:coxfrederic@gmail.com]
>>>>>>>>>>> Sent: Thursday, January 11, 2018 9:09 PM
>>>>>>>>>>> To: users@royale.apache.org
>>>>>>>>>>> Subject: Re: RemoteObject
>>>>>>>>>>>
>>>>>>>>>>> <?xml version="1.0" encoding="utf-8"?>
>>>>>>>>>>>
>>>>>>>>>>> <js:Application xmlns:fx="http://ns.adobe.com/mxml/2009
>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.adobe.com%2Fmxml%2F2009&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7cSxKCospCIpbkKY4F%2Fp5lsHBH%2BPFp5Vny2ftXWmL5A%3D&reserved=0>
>>>>>>>>>>> "
>>>>>>>>>>>                    xmlns:js="library://ns.apache
>>>>>>>>>>> .org/royale/basic
>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.apache.org%2Froyale%2Fbasic&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=D%2FBslvPtV9pNNjpoS4KCQlYHB8ArUYEIXCXuAVoNgYM%3D&reserved=0>"
>>>>>>>>>>> >
>>>>>>>>>>>         <fx:Script>
>>>>>>>>>>>
>>>>>>>>>>>         </fx:Script>
>>>>>>>>>>>     <js:valuesImpl>
>>>>>>>>>>>         <js:SimpleCSSValuesImpl />
>>>>>>>>>>>     </js:valuesImpl>
>>>>>>>>>>>
>>>>>>>>>>>         <js:beads>
>>>>>>>>>>>                 <js:ClassAliasBead />
>>>>>>>>>>>                 <js:RemoteObject id="amfTestService"
>>>>>>>>>>>
>>>>>>>>>>> endPoint="http://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=EJDBQBL83yBhDn%2BWWgCCVyw0N3tnakhZ7UdEt4JFNaY%3D&reserved=0>
>>>>>>>>>>> "
>>>>>>>>>>>
>>>>>>>>>>>  destination="Meta"
>>>>>>>>>>> source="Meta" />
>>>>>>>>>>>         </js:beads>
>>>>>>>>>>>
>>>>>>>>>>>     <js:initialView>
>>>>>>>>>>>         <js:View>
>>>>>>>>>>>                         <js:VGroup>
>>>>>>>>>>>                                 <js:Label id="statusLabel"
>>>>>>>>>>> text="Hello
>>>>>>>>>>> World!" />
>>>>>>>>>>>                                 <js:TextButton text="Get AMF
>>>>>>>>>>> data"
>>>>>>>>>>> click="textbutton_clickHandler(event)" />
>>>>>>>>>>>                         </js:VGroup>
>>>>>>>>>>>         </js:View>
>>>>>>>>>>>     </js:initialView>
>>>>>>>>>>> </js:Application>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Any idea why I'm not getting a fault nor success event on this?
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> --
>>>>>>>>>>> Sent from: http://apache-royale-users.20374.n8.nabble.com/
>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fapache-royale-users.20374.n8.nabble.com%2F&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=xvY8nK1QKlWduh6p5x8y19jm%2Br60PSFVlNdi6TRsPmw%3D&reserved=0>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> --
>>>>>>>>>> Carlos Rovira
>>>>>>>>>> http://about.me/carlosrovira
>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fabout.me%2Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=55MSUXBM2zE5U0csgV1harcuXvKyZ2gd%2BO%2FmD7hjJ50%3D&reserved=0>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>>
>>>>>>>>> Piotr Zarzycki
>>>>>>>>>
>>>>>>>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=NG2rkkxhfc7MTSVRqHzEmHL8HuUpvXI72B9nkW2QfdU%3D&reserved=0>*
>>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> --
>>>>>>>> Carlos Rovira
>>>>>>>> http://about.me/carlosrovira
>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fabout.me%2Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=55MSUXBM2zE5U0csgV1harcuXvKyZ2gd%2BO%2FmD7hjJ50%3D&reserved=0>
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>>
>>>>>>> Piotr Zarzycki
>>>>>>>
>>>>>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=NG2rkkxhfc7MTSVRqHzEmHL8HuUpvXI72B9nkW2QfdU%3D&reserved=0>*
>>>>>>>
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>> --
>>>>>
>>>>> Piotr Zarzycki
>>>>>
>>>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=NG2rkkxhfc7MTSVRqHzEmHL8HuUpvXI72B9nkW2QfdU%3D&reserved=0>*
>>>>>
>>>>
>>>>
>>>
>>
>>
>> --
>> Carlos Rovira
>> http://about.me/carlosrovira
>>
>>
>
>
> --
>
> Piotr Zarzycki
>
> Patreon: *https://www.patreon.com/piotrzarzycki
> <https://www.patreon.com/piotrzarzycki>*
>

Re: RemoteObject

Posted by Prashant Kumar <pr...@gmail.com>.
yes, i tested with AMFPHP also. i was working.

On Fri, Feb 16, 2018 at 9:33 PM, Piotr Zarzycki <pi...@gmail.com>
wrote:

> Prashant,
>
> Did you try it with AMFPHP ?
>
> Thanks, Piotr
>
> 2018-02-16 16:46 GMT+01:00 Prashant Kumar <pr...@gmail.com>:
>
>> I tested couple of scenarios of FlexJS AMF. only fews are working. I will
>> check with Royal and share output tomorrow.
>>
>> On 16-Feb-2018 8:30 PM, "Piotr Zarzycki" <pi...@gmail.com>
>> wrote:
>>
>>> Frederic,
>>>
>>> Could you share some hello world implementation of AMFPHP along with
>>> Hello World app in Flex ? I may also look into that and compare the
>>> results. Just don't want to waste time on setup things to prepare AMFPHP
>>> stuff. Do you have such things ?
>>>
>>> Thanks, Piotr
>>>
>>>
>>> 2018-02-16 15:57 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>>>
>>>> Hi Carlos,
>>>>
>>>> Sure I’ll see what I can do. Feel I have lots to leatn about Royale and
>>>> AMF (it just works with Flash/AIR so not up to date about the inner
>>>> workings).
>>>>
>>>> I’ll try to test the examples over the weekend. Do you think the AMFPHP
>>>> version could be an issue or is it assumed to work in Royale if it works in
>>>> Flex?
>>>>
>>>> Verstuurd vanaf mijn iPhone
>>>>
>>>> Op 16 feb. 2018 om 12:28 heeft Carlos Rovira <ca...@apache.org>
>>>> het volgende geschreven:
>>>>
>>>> Hi Frederic,
>>>> thanks for filling this and take a look into AMF!
>>>> Hope you could help us a bit with this.
>>>>
>>>> 2018-02-16 0:21 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>>>>
>>>>> Hi Alex,
>>>>>
>>>>> I created https://github.com/apache/royale-asjs/issues/119, hope that
>>>>> is in the correct place and with more readable mark-up.
>>>>>
>>>>> Regards,
>>>>>
>>>>> Fréderic
>>>>>
>>>>> On Thu, Feb 15, 2018 at 8:57 PM, Alex Harui <ah...@adobe.com> wrote:
>>>>>
>>>>>> Hi Frederic,
>>>>>>
>>>>>> Where is this output you posted coming from, a network monitor?  It
>>>>>> was too hard to read, so please create a bug report on GitHub and post it
>>>>>> there.
>>>>>>
>>>>>> You might be able to use a network monitor to compare what Flex sent
>>>>>> vs what Royale is sending.  What does your Flex usage of RemoteObject look
>>>>>> like?
>>>>>>
>>>>>> HTH,
>>>>>> -Alex
>>>>>>
>>>>>> From: Fréderic Cox <co...@gmail.com>
>>>>>> Reply-To: "users@royale.apache.org" <us...@royale.apache.org>
>>>>>> Date: Thursday, February 15, 2018 at 5:09 AM
>>>>>> To: "users@royale.apache.org" <us...@royale.apache.org>
>>>>>> Subject: Re: RemoteObject
>>>>>>
>>>>>> Hi Piotr,
>>>>>>
>>>>>> Thanks, I installed the extension and now I'm not getting the CORS
>>>>>> error anymore.
>>>>>> I'm not getting any fault or result event triggered either....
>>>>>>
>>>>>> The endPoint set is
>>>>>> https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php
>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fclients.cityfashion.dev.exuvis.com%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=67VMfKVGZo%2BarMstlt%2BZbX5OdTomYDQNSgM07ycK%2Bvc%3D&reserved=0>
>>>>>>
>>>>>> This is correct, right? (I use this endpoint in Flex and that works
>>>>>> fine)
>>>>>>
>>>>>>
>>>>>>    1. Request URL:
>>>>>>       https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php
>>>>>>       <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fclients.cityfashion.dev.exuvis.com%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=67VMfKVGZo%2BarMstlt%2BZbX5OdTomYDQNSgM07ycK%2Bvc%3D&reserved=0>
>>>>>>       2. Request Method:
>>>>>>       OPTIONS
>>>>>>       3. Status Code:
>>>>>>       200 OK
>>>>>>       4. Remote Address:
>>>>>>       188.93.153.101:443
>>>>>>       <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2F188.93.153.101%3A443&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=UWqG%2BqQTcL1fTnck9i5BPXmrn3ZlgRf8XCPpQ8EcJrE%3D&reserved=0>
>>>>>>       5. Referrer Policy:
>>>>>>       no-referrer-when-downgrade
>>>>>>       1. Response Headersview source
>>>>>>       1. Connection:
>>>>>>       keep-alive
>>>>>>       2. Content-Encoding:
>>>>>>       gzip
>>>>>>       3. Content-Length:
>>>>>>       286
>>>>>>       4. Content-Type:
>>>>>>       text/html; charset=UTF-8
>>>>>>       5. Date:
>>>>>>       Thu, 15 Feb 2018 13:08:17 GMT
>>>>>>       6. Server:
>>>>>>       nginx
>>>>>>       7. Vary:
>>>>>>       Accept-Encoding
>>>>>>       2. Request Headersview source
>>>>>>       1. Accept:
>>>>>>       */*
>>>>>>       2. Accept-Encoding:
>>>>>>       gzip, deflate, br
>>>>>>       3. Accept-Language:
>>>>>>       en-GB,en-US;q=0.9,en;q=0.8
>>>>>>       4. Access-Control-Request-Headers:
>>>>>>       content-type
>>>>>>       5. Access-Control-Request-Method:
>>>>>>       POST
>>>>>>       6. Connection:
>>>>>>       keep-alive
>>>>>>       7. Host:
>>>>>>       clients.cityfashion.dev.exuvis.com
>>>>>>       <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fclients.cityfashion.dev.exuvis.com&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=%2BiTohXW1uaTpydtAlGWa0leTvEQKK2Wg6XtN%2FqQ73%2F0%3D&reserved=0>
>>>>>>       8. Origin:
>>>>>>       null
>>>>>>       9. User-Agent:
>>>>>>       Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_3)
>>>>>>       AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.167 Safari/537.36
>>>>>>
>>>>>> Response is:
>>>>>>
>>>>>> <p>amfphp and this gateway are installed correctly. You may now
>>>>>> connect to this gateway from Flash.</p><p>Note: If you're reading an old
>>>>>> tutorial, it will tell you that you should see a download window instead of
>>>>>> this message. This confused people so this is the new behaviour starting
>>>>>> from amfphp 1.2.</p><p><a href='http://www.amfphp.org/docs
>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.amfphp.org%2Fdocs&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=%2FGtfS6iuQCrcoifQ5pUOXPJ0JJZcOQaMyYsscjKzA9I%3D&reserved=0>'>View
>>>>>> the amfphp documentation</p><p><a href='browser'>Load the service
>>>>>> browser</a></p><pre>
>>>>>>
>>>>>> Should I target a specific file with the JS version? Should the
>>>>>> endPoint be different?
>>>>>>
>>>>>> On Thu, Feb 15, 2018 at 12:07 PM, Piotr Zarzycki <
>>>>>> piotrzarzycki21@gmail.com> wrote:
>>>>>>
>>>>>>> Frederic,
>>>>>>>
>>>>>>> It looks like it is not problem with framework, but rather CORS
>>>>>>> issue. Maybe try to install this plugin [1] and add to the list your url.
>>>>>>>
>>>>>>> [1] https://chrome.google.com/webstore/detail/allow-control-
>>>>>>> allow-origi/nlfbmbojpeacfghkpbjhddihlkkiljbi?hl=en
>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fchrome.google.com%2Fwebstore%2Fdetail%2Fallow-control-allow-origi%2Fnlfbmbojpeacfghkpbjhddihlkkiljbi%3Fhl%3Den&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=CbZH3KQcH0oGU%2FbnBtyVp%2B9zeqDEUcK9Y6UFd0BIESM%3D&reserved=0>
>>>>>>>
>>>>>>> Piotr
>>>>>>>
>>>>>>> 2018-02-15 12:04 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>>>>>>>
>>>>>>>> For me it is still not working in latest release 0.9.1. I based my
>>>>>>>> example on the example in the SDK.
>>>>>>>>
>>>>>>>> <?xml version="1.0" encoding="utf-8"?>
>>>>>>>> <js:Applicationxmlns:fx="http://ns.adobe.com/mxml/2009
>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.adobe.com%2Fmxml%2F2009&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7cSxKCospCIpbkKY4F%2Fp5lsHBH%2BPFp5Vny2ftXWmL5A%3D&reserved=0>
>>>>>>>> "
>>>>>>>> xmlns:js="library://ns.apache.org/royale/basic
>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.apache.org%2Froyale%2Fbasic&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=D%2FBslvPtV9pNNjpoS4KCQlYHB8ArUYEIXCXuAVoNgYM%3D&reserved=0>
>>>>>>>> "applicationComplete="applicationCompleteHandler(event);">
>>>>>>>>
>>>>>>>>     <fx:Script>
>>>>>>>>         <![CDATA[
>>>>>>>>             import org.apache.royale.net
>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Forg.apache.royale.net&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=ATrXbo2PLqz1dNeyvxVu89zy3yaKPxwIwQm9tSG7ybs%3D&reserved=0>
>>>>>>>> .RemoteObject;
>>>>>>>>             import org.apache.royale.net.events.FaultEvent;
>>>>>>>>             import org.apache.royale.net.events.ResultEvent;
>>>>>>>>
>>>>>>>>             privatefunctionapplicationCompleteHandler(evt:Event):
>>>>>>>> void{
>>>>>>>>                 testLabel.text = "Requesting from AMF";
>>>>>>>>                 service.send("getPackages", null);
>>>>>>>>             }
>>>>>>>>
>>>>>>>>             privatefunctionamfFaultHandler(evt:FaultEvent):void{
>>>>>>>>                 testLabel.text = "Fault in calling AMF";
>>>>>>>>             }
>>>>>>>>
>>>>>>>>             privatefunctionamfResultHandler(evt:ResultEvent):void{
>>>>>>>>                 testLabel.text = "Result received from AMF";
>>>>>>>>             }
>>>>>>>>         ]]>
>>>>>>>>     </fx:Script>
>>>>>>>>
>>>>>>>> <js:valuesImpl>
>>>>>>>> <js:SimpleCSSValuesImpl />
>>>>>>>> </js:valuesImpl>
>>>>>>>>
>>>>>>>>    <js:beads>
>>>>>>>> <js:ClassAliasBead />
>>>>>>>> <js:RemoteObjectid="service"result="amfResultHandler(event)"fault=
>>>>>>>> "amfFaultHandler(event)"
>>>>>>>> endPoint = "https://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=mARoGAlKZYBWmNOBwqTpTRYkqG%2Fk0cvrHwR5kgbfNFY%3D&reserved=0>
>>>>>>>> "
>>>>>>>> destination = "Meta"
>>>>>>>> source = "Meta"/>
>>>>>>>> </js:beads>
>>>>>>>>
>>>>>>>> <js:initialView>
>>>>>>>> <js:View>
>>>>>>>> <js:Labelid="testLabel" />
>>>>>>>> </js:View>
>>>>>>>> </js:initialView>
>>>>>>>> </js:Application>
>>>>>>>>
>>>>>>>>
>>>>>>>> It is not working and showing the following error in the browser:
>>>>>>>>
>>>>>>>> Failed to load https://winkelbeheer.cityfashi
>>>>>>>> on.be/amfphp/gateway.php
>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=mARoGAlKZYBWmNOBwqTpTRYkqG%2Fk0cvrHwR5kgbfNFY%3D&reserved=0>:
>>>>>>>> Response to preflight request doesn't pass access control check: No
>>>>>>>> 'Access-Control-Allow-Origin' header is present on the requested resource.
>>>>>>>> Origin 'http://localhost' is therefore not allowed access.
>>>>>>>> Language.js:238destination fault handler
>>>>>>>>
>>>>>>>>    1. {code: -1004, message: "Invalid response type.", detail: "Invalid
>>>>>>>>    XMLHttpRequest response status or type.", data: null}
>>>>>>>>       1. code:-1004
>>>>>>>>       2. data:null
>>>>>>>>       3. detail:"Invalid XMLHttpRequest response status or type."
>>>>>>>>       4. message:"Invalid response type."
>>>>>>>>       5. __proto__:Object
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> It is able to compile and run regardless of the errors in compile
>>>>>>>> log:
>>>>>>>>
>>>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>>>> println
>>>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>>>> he/royale/reflection/AccessorDefinition.js:12: ERROR - required
>>>>>>>> "org.apache.royale.reflection.TypeDefinition" namespace not
>>>>>>>> provided yet
>>>>>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>>>
>>>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>>>> println
>>>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>>>> he/royale/reflection/AccessorDefinition.js:13: ERROR - required
>>>>>>>> "org.apache.royale.reflection.VariableDefinition" namespace not
>>>>>>>> provided yet
>>>>>>>> goog.require('org.apache.royale.reflection.VariableDefinition');
>>>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>>>
>>>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>>>> println
>>>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>>>> he/royale/reflection/MethodDefinition.js:14: ERROR - required
>>>>>>>> "org.apache.royale.reflection.TypeDefinition" namespace not
>>>>>>>> provided yet
>>>>>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>>>
>>>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>>>> println
>>>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>>>> he/royale/reflection/ParameterDefinition.js:13: ERROR- required
>>>>>>>> "org.apache.royale.reflection.TypeDefinition" namespace not
>>>>>>>> provided yet
>>>>>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>>>
>>>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>>>> println
>>>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>>>> he/royale/reflection/TypeDefinition.js:15: ERROR - required
>>>>>>>> "org.apache.royale.reflection.VariableDefinition" namespace not
>>>>>>>> provided yet
>>>>>>>> goog.require('org.apache.royale.reflection.VariableDefinition');
>>>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>>>
>>>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>>>> printSummary
>>>>>>>> WARNING: 5 error(s), 0 warning(s)
>>>>>>>> The project 'HelloRoyale' has been successfully compiled and
>>>>>>>> optimized.
>>>>>>>> 4.566387 seconds
>>>>>>>>
>>>>>>>>
>>>>>>>> On Mon, Jan 15, 2018 at 7:38 PM, Piotr Zarzycki <
>>>>>>>> piotrzarzycki21@gmail.com> wrote:
>>>>>>>>
>>>>>>>>> Carlos,
>>>>>>>>>
>>>>>>>>> No problem. I have also couple of huge things related to Royale to
>>>>>>>>> do before my hand gets dirty with AMF! :) Unless someone urgently will
>>>>>>>>> needed. :)
>>>>>>>>>
>>>>>>>>> Thanks, Piotr
>>>>>>>>>
>>>>>>>>> 2018-01-15 19:27 GMT+01:00 Carlos Rovira <ca...@apache.org>
>>>>>>>>> :
>>>>>>>>>
>>>>>>>>>> Hi Piotr,
>>>>>>>>>> I'll put this on my to do list, but have to do some things first.
>>>>>>>>>> thanks
>>>>>>>>>>
>>>>>>>>>> 2018-01-15 9:26 GMT+01:00 Piotr Zarzycki <
>>>>>>>>>> piotrzarzycki21@gmail.com>:
>>>>>>>>>>
>>>>>>>>>>> Hi Carlos,
>>>>>>>>>>>
>>>>>>>>>>> Can you describe more how to setup those examples ? Could you
>>>>>>>>>>> add to RemoteObjectAMFTest README.md file where you describe steps. I would
>>>>>>>>>>> like to have AMF on my list for tests and improvements. Whenever I look
>>>>>>>>>>> into that I don't know how to proceed with it.
>>>>>>>>>>>
>>>>>>>>>>> Thanks, Piotr
>>>>>>>>>>>
>>>>>>>>>>> 2018-01-15 9:21 GMT+01:00 Carlos Rovira <carlosrovira@apache.org
>>>>>>>>>>> >:
>>>>>>>>>>>
>>>>>>>>>>>> Hi,
>>>>>>>>>>>>
>>>>>>>>>>>> there's an example that we get it working nicely at:
>>>>>>>>>>>>
>>>>>>>>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/
>>>>>>>>>>>> royale/RemoteObjectAMFTest
>>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Ftree%2Fdevelop%2Fexamples%2Froyale%2FRemoteObjectAMFTest&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7kdc48rEQiaI4Qp%2BBdfBcGPxddZIYrTUXrQ%2BN2u4tto%3D&reserved=0>
>>>>>>>>>>>>
>>>>>>>>>>>> you can use that as a starting point for your test
>>>>>>>>>>>>
>>>>>>>>>>>> As well a java web app that is used along that royale client
>>>>>>>>>>>> example is at:
>>>>>>>>>>>>
>>>>>>>>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/amf
>>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Ftree%2Fdevelop%2Fexamples%2Famf&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=PW4DYIeW4PetVe6BdFYjxFeAjCrqofPYtdbRTnJ4xjk%3D&reserved=0>
>>>>>>>>>>>>
>>>>>>>>>>>> thanks
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> 2018-01-15 3:56 GMT+01:00 Carlos Cruz <carlos@nbtbizcapital.com
>>>>>>>>>>>> >:
>>>>>>>>>>>>
>>>>>>>>>>>>> I have a lot of experience with Flex remoting and BlazeDS with
>>>>>>>>>>>>> Java, but with FlexJS and Royale I have none, but extrapolating from some
>>>>>>>>>>>>> JS tests I've done with AMF at this line: amfTestService.send(
>>>>>>>>>>>>> "getShippingMethods", []); you have to call a class in
>>>>>>>>>>>>> gateway.php and a method. Your request needs at least 3 properties.
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> I'm also assuming your JS file and gateway.php are in the same
>>>>>>>>>>>>> domain and same port (this gave me problems).
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> Take what I said regarding my experience with FlexJS and
>>>>>>>>>>>>> Royale into account.
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> Carlos
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> *From:* Fréderic Cox [mailto:coxfrederic@gmail.com]
>>>>>>>>>>>>> *Sent:* Sunday, January 14, 2018 4:01 PM
>>>>>>>>>>>>>
>>>>>>>>>>>>> *To:* users@royale.apache.org
>>>>>>>>>>>>> *Subject:* Re: RemoteObject
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> Script tag was stripped from the post:
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> import org.apache.royale.events.MouseEvent;
>>>>>>>>>>>>>
>>>>>>>>>>>>>                      import org.apache.royale.net.events.F
>>>>>>>>>>>>> aultEvent;
>>>>>>>>>>>>>
>>>>>>>>>>>>>                      import org.apache.royale.net.events.R
>>>>>>>>>>>>> esultEvent;
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>                      protectedfunction
>>>>>>>>>>>>> textbutton_clickHandler(event:org.apache.royale.events.Mouse
>>>>>>>>>>>>> Event):void
>>>>>>>>>>>>>
>>>>>>>>>>>>>                      {
>>>>>>>>>>>>>
>>>>>>>>>>>>>                            statusLabel.text = "calling......."
>>>>>>>>>>>>> ;
>>>>>>>>>>>>>
>>>>>>>>>>>>>                            amfTestService.addEventListener(
>>>>>>>>>>>>> "fault", amfTestService_faultHandler);
>>>>>>>>>>>>>
>>>>>>>>>>>>>                            amfTestService.addEventListener(
>>>>>>>>>>>>> "result", amfTestService_resultHandler);
>>>>>>>>>>>>>
>>>>>>>>>>>>>                            amfTestService.send("getShippi
>>>>>>>>>>>>> ngMethods", []);
>>>>>>>>>>>>>
>>>>>>>>>>>>>                      }
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>                      protectedfunction
>>>>>>>>>>>>> amfTestService_faultHandler(event:FaultEvent):void
>>>>>>>>>>>>>
>>>>>>>>>>>>>                      {
>>>>>>>>>>>>>
>>>>>>>>>>>>>                            statusLabel.text = "error!";
>>>>>>>>>>>>>
>>>>>>>>>>>>>                      }
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>                      protectedfunction
>>>>>>>>>>>>> amfTestService_resultHandler(event:ResultEvent):void
>>>>>>>>>>>>>
>>>>>>>>>>>>>                      {
>>>>>>>>>>>>>
>>>>>>>>>>>>>                            statusLabel.text = "result!";
>>>>>>>>>>>>>
>>>>>>>>>>>>>                      }
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> none of the events are triggered ..URL is
>>>>>>>>>>>>> http://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=EJDBQBL83yBhDn%2BWWgCCVyw0N3tnakhZ7UdEt4JFNaY%3D&reserved=0>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> On Fri, Jan 12, 2018 at 4:55 AM, Carlos Cruz <
>>>>>>>>>>>>> carlos@nbtbizcapital.com> wrote:
>>>>>>>>>>>>>
>>>>>>>>>>>>> I may be blind (and or ignorant as I'm more familiar with
>>>>>>>>>>>>> Flex) but where
>>>>>>>>>>>>> are you sending an AMF request? I don't see any code that
>>>>>>>>>>>>> sends a request to
>>>>>>>>>>>>> a service and invokes method.
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> -----Original Message-----
>>>>>>>>>>>>> From: coxfrederic [mailto:coxfrederic@gmail.com]
>>>>>>>>>>>>> Sent: Thursday, January 11, 2018 9:09 PM
>>>>>>>>>>>>> To: users@royale.apache.org
>>>>>>>>>>>>> Subject: Re: RemoteObject
>>>>>>>>>>>>>
>>>>>>>>>>>>> <?xml version="1.0" encoding="utf-8"?>
>>>>>>>>>>>>>
>>>>>>>>>>>>> <js:Application xmlns:fx="http://ns.adobe.com/mxml/2009
>>>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.adobe.com%2Fmxml%2F2009&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7cSxKCospCIpbkKY4F%2Fp5lsHBH%2BPFp5Vny2ftXWmL5A%3D&reserved=0>
>>>>>>>>>>>>> "
>>>>>>>>>>>>>                    xmlns:js="library://ns.apache
>>>>>>>>>>>>> .org/royale/basic
>>>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.apache.org%2Froyale%2Fbasic&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=D%2FBslvPtV9pNNjpoS4KCQlYHB8ArUYEIXCXuAVoNgYM%3D&reserved=0>"
>>>>>>>>>>>>> >
>>>>>>>>>>>>>         <fx:Script>
>>>>>>>>>>>>>
>>>>>>>>>>>>>         </fx:Script>
>>>>>>>>>>>>>     <js:valuesImpl>
>>>>>>>>>>>>>         <js:SimpleCSSValuesImpl />
>>>>>>>>>>>>>     </js:valuesImpl>
>>>>>>>>>>>>>
>>>>>>>>>>>>>         <js:beads>
>>>>>>>>>>>>>                 <js:ClassAliasBead />
>>>>>>>>>>>>>                 <js:RemoteObject id="amfTestService"
>>>>>>>>>>>>>
>>>>>>>>>>>>> endPoint="http://winkelbeheer.cityfashion.be/amfphp/gateway.
>>>>>>>>>>>>> php
>>>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=EJDBQBL83yBhDn%2BWWgCCVyw0N3tnakhZ7UdEt4JFNaY%3D&reserved=0>
>>>>>>>>>>>>> "
>>>>>>>>>>>>>
>>>>>>>>>>>>>  destination="Meta"
>>>>>>>>>>>>> source="Meta" />
>>>>>>>>>>>>>         </js:beads>
>>>>>>>>>>>>>
>>>>>>>>>>>>>     <js:initialView>
>>>>>>>>>>>>>         <js:View>
>>>>>>>>>>>>>                         <js:VGroup>
>>>>>>>>>>>>>                                 <js:Label id="statusLabel"
>>>>>>>>>>>>> text="Hello
>>>>>>>>>>>>> World!" />
>>>>>>>>>>>>>                                 <js:TextButton text="Get AMF
>>>>>>>>>>>>> data"
>>>>>>>>>>>>> click="textbutton_clickHandler(event)" />
>>>>>>>>>>>>>                         </js:VGroup>
>>>>>>>>>>>>>         </js:View>
>>>>>>>>>>>>>     </js:initialView>
>>>>>>>>>>>>> </js:Application>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> Any idea why I'm not getting a fault nor success event on this?
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> --
>>>>>>>>>>>>> Sent from: http://apache-royale-users.20374.n8.nabble.com/
>>>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fapache-royale-users.20374.n8.nabble.com%2F&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=xvY8nK1QKlWduh6p5x8y19jm%2Br60PSFVlNdi6TRsPmw%3D&reserved=0>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> --
>>>>>>>>>>>> Carlos Rovira
>>>>>>>>>>>> http://about.me/carlosrovira
>>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fabout.me%2Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=55MSUXBM2zE5U0csgV1harcuXvKyZ2gd%2BO%2FmD7hjJ50%3D&reserved=0>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> --
>>>>>>>>>>>
>>>>>>>>>>> Piotr Zarzycki
>>>>>>>>>>>
>>>>>>>>>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=NG2rkkxhfc7MTSVRqHzEmHL8HuUpvXI72B9nkW2QfdU%3D&reserved=0>*
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> --
>>>>>>>>>>
>>>>>>>>> ...
>>
>>
>
>
> --
>
> Piotr Zarzycki
>
> Patreon: *https://www.patreon.com/piotrzarzycki
> <https://www.patreon.com/piotrzarzycki>*
>



-- 
*Regards,*
Prashant Kumar* | *Mob.: +91 8408811225

Re: RemoteObject

Posted by Piotr Zarzycki <pi...@gmail.com>.
Prashant,

Did you try it with AMFPHP ?

Thanks, Piotr

2018-02-16 16:46 GMT+01:00 Prashant Kumar <pr...@gmail.com>:

> I tested couple of scenarios of FlexJS AMF. only fews are working. I will
> check with Royal and share output tomorrow.
>
> On 16-Feb-2018 8:30 PM, "Piotr Zarzycki" <pi...@gmail.com>
> wrote:
>
>> Frederic,
>>
>> Could you share some hello world implementation of AMFPHP along with
>> Hello World app in Flex ? I may also look into that and compare the
>> results. Just don't want to waste time on setup things to prepare AMFPHP
>> stuff. Do you have such things ?
>>
>> Thanks, Piotr
>>
>>
>> 2018-02-16 15:57 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>>
>>> Hi Carlos,
>>>
>>> Sure I’ll see what I can do. Feel I have lots to leatn about Royale and
>>> AMF (it just works with Flash/AIR so not up to date about the inner
>>> workings).
>>>
>>> I’ll try to test the examples over the weekend. Do you think the AMFPHP
>>> version could be an issue or is it assumed to work in Royale if it works in
>>> Flex?
>>>
>>> Verstuurd vanaf mijn iPhone
>>>
>>> Op 16 feb. 2018 om 12:28 heeft Carlos Rovira <ca...@apache.org>
>>> het volgende geschreven:
>>>
>>> Hi Frederic,
>>> thanks for filling this and take a look into AMF!
>>> Hope you could help us a bit with this.
>>>
>>> 2018-02-16 0:21 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>>>
>>>> Hi Alex,
>>>>
>>>> I created https://github.com/apache/royale-asjs/issues/119, hope that
>>>> is in the correct place and with more readable mark-up.
>>>>
>>>> Regards,
>>>>
>>>> Fréderic
>>>>
>>>> On Thu, Feb 15, 2018 at 8:57 PM, Alex Harui <ah...@adobe.com> wrote:
>>>>
>>>>> Hi Frederic,
>>>>>
>>>>> Where is this output you posted coming from, a network monitor?  It
>>>>> was too hard to read, so please create a bug report on GitHub and post it
>>>>> there.
>>>>>
>>>>> You might be able to use a network monitor to compare what Flex sent
>>>>> vs what Royale is sending.  What does your Flex usage of RemoteObject look
>>>>> like?
>>>>>
>>>>> HTH,
>>>>> -Alex
>>>>>
>>>>> From: Fréderic Cox <co...@gmail.com>
>>>>> Reply-To: "users@royale.apache.org" <us...@royale.apache.org>
>>>>> Date: Thursday, February 15, 2018 at 5:09 AM
>>>>> To: "users@royale.apache.org" <us...@royale.apache.org>
>>>>> Subject: Re: RemoteObject
>>>>>
>>>>> Hi Piotr,
>>>>>
>>>>> Thanks, I installed the extension and now I'm not getting the CORS
>>>>> error anymore.
>>>>> I'm not getting any fault or result event triggered either....
>>>>>
>>>>> The endPoint set is
>>>>> https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php
>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fclients.cityfashion.dev.exuvis.com%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=67VMfKVGZo%2BarMstlt%2BZbX5OdTomYDQNSgM07ycK%2Bvc%3D&reserved=0>
>>>>>
>>>>> This is correct, right? (I use this endpoint in Flex and that works
>>>>> fine)
>>>>>
>>>>>
>>>>>    1. Request URL:
>>>>>       https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php
>>>>>       <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fclients.cityfashion.dev.exuvis.com%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=67VMfKVGZo%2BarMstlt%2BZbX5OdTomYDQNSgM07ycK%2Bvc%3D&reserved=0>
>>>>>       2. Request Method:
>>>>>       OPTIONS
>>>>>       3. Status Code:
>>>>>       200 OK
>>>>>       4. Remote Address:
>>>>>       188.93.153.101:443
>>>>>       <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2F188.93.153.101%3A443&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=UWqG%2BqQTcL1fTnck9i5BPXmrn3ZlgRf8XCPpQ8EcJrE%3D&reserved=0>
>>>>>       5. Referrer Policy:
>>>>>       no-referrer-when-downgrade
>>>>>       1. Response Headersview source
>>>>>       1. Connection:
>>>>>       keep-alive
>>>>>       2. Content-Encoding:
>>>>>       gzip
>>>>>       3. Content-Length:
>>>>>       286
>>>>>       4. Content-Type:
>>>>>       text/html; charset=UTF-8
>>>>>       5. Date:
>>>>>       Thu, 15 Feb 2018 13:08:17 GMT
>>>>>       6. Server:
>>>>>       nginx
>>>>>       7. Vary:
>>>>>       Accept-Encoding
>>>>>       2. Request Headersview source
>>>>>       1. Accept:
>>>>>       */*
>>>>>       2. Accept-Encoding:
>>>>>       gzip, deflate, br
>>>>>       3. Accept-Language:
>>>>>       en-GB,en-US;q=0.9,en;q=0.8
>>>>>       4. Access-Control-Request-Headers:
>>>>>       content-type
>>>>>       5. Access-Control-Request-Method:
>>>>>       POST
>>>>>       6. Connection:
>>>>>       keep-alive
>>>>>       7. Host:
>>>>>       clients.cityfashion.dev.exuvis.com
>>>>>       <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fclients.cityfashion.dev.exuvis.com&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=%2BiTohXW1uaTpydtAlGWa0leTvEQKK2Wg6XtN%2FqQ73%2F0%3D&reserved=0>
>>>>>       8. Origin:
>>>>>       null
>>>>>       9. User-Agent:
>>>>>       Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_3)
>>>>>       AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.167 Safari/537.36
>>>>>
>>>>> Response is:
>>>>>
>>>>> <p>amfphp and this gateway are installed correctly. You may now
>>>>> connect to this gateway from Flash.</p><p>Note: If you're reading an old
>>>>> tutorial, it will tell you that you should see a download window instead of
>>>>> this message. This confused people so this is the new behaviour starting
>>>>> from amfphp 1.2.</p><p><a href='http://www.amfphp.org/docs
>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.amfphp.org%2Fdocs&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=%2FGtfS6iuQCrcoifQ5pUOXPJ0JJZcOQaMyYsscjKzA9I%3D&reserved=0>'>View
>>>>> the amfphp documentation</p><p><a href='browser'>Load the service
>>>>> browser</a></p><pre>
>>>>>
>>>>> Should I target a specific file with the JS version? Should the
>>>>> endPoint be different?
>>>>>
>>>>> On Thu, Feb 15, 2018 at 12:07 PM, Piotr Zarzycki <
>>>>> piotrzarzycki21@gmail.com> wrote:
>>>>>
>>>>>> Frederic,
>>>>>>
>>>>>> It looks like it is not problem with framework, but rather CORS
>>>>>> issue. Maybe try to install this plugin [1] and add to the list your url.
>>>>>>
>>>>>> [1] https://chrome.google.com/webstore/detail/allow-control-
>>>>>> allow-origi/nlfbmbojpeacfghkpbjhddihlkkiljbi?hl=en
>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fchrome.google.com%2Fwebstore%2Fdetail%2Fallow-control-allow-origi%2Fnlfbmbojpeacfghkpbjhddihlkkiljbi%3Fhl%3Den&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=CbZH3KQcH0oGU%2FbnBtyVp%2B9zeqDEUcK9Y6UFd0BIESM%3D&reserved=0>
>>>>>>
>>>>>> Piotr
>>>>>>
>>>>>> 2018-02-15 12:04 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>>>>>>
>>>>>>> For me it is still not working in latest release 0.9.1. I based my
>>>>>>> example on the example in the SDK.
>>>>>>>
>>>>>>> <?xml version="1.0" encoding="utf-8"?>
>>>>>>> <js:Applicationxmlns:fx="http://ns.adobe.com/mxml/2009
>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.adobe.com%2Fmxml%2F2009&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7cSxKCospCIpbkKY4F%2Fp5lsHBH%2BPFp5Vny2ftXWmL5A%3D&reserved=0>
>>>>>>> "
>>>>>>> xmlns:js="library://ns.apache.org/royale/basic
>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.apache.org%2Froyale%2Fbasic&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=D%2FBslvPtV9pNNjpoS4KCQlYHB8ArUYEIXCXuAVoNgYM%3D&reserved=0>
>>>>>>> "applicationComplete="applicationCompleteHandler(event);">
>>>>>>>
>>>>>>>     <fx:Script>
>>>>>>>         <![CDATA[
>>>>>>>             import org.apache.royale.net
>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Forg.apache.royale.net&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=ATrXbo2PLqz1dNeyvxVu89zy3yaKPxwIwQm9tSG7ybs%3D&reserved=0>
>>>>>>> .RemoteObject;
>>>>>>>             import org.apache.royale.net.events.FaultEvent;
>>>>>>>             import org.apache.royale.net.events.ResultEvent;
>>>>>>>
>>>>>>>             privatefunctionapplicationCompleteHandler(evt:Event):
>>>>>>> void{
>>>>>>>                 testLabel.text = "Requesting from AMF";
>>>>>>>                 service.send("getPackages", null);
>>>>>>>             }
>>>>>>>
>>>>>>>             privatefunctionamfFaultHandler(evt:FaultEvent):void{
>>>>>>>                 testLabel.text = "Fault in calling AMF";
>>>>>>>             }
>>>>>>>
>>>>>>>             privatefunctionamfResultHandler(evt:ResultEvent):void{
>>>>>>>                 testLabel.text = "Result received from AMF";
>>>>>>>             }
>>>>>>>         ]]>
>>>>>>>     </fx:Script>
>>>>>>>
>>>>>>> <js:valuesImpl>
>>>>>>> <js:SimpleCSSValuesImpl />
>>>>>>> </js:valuesImpl>
>>>>>>>
>>>>>>>    <js:beads>
>>>>>>> <js:ClassAliasBead />
>>>>>>> <js:RemoteObjectid="service"result="amfResultHandler(event)"fault=
>>>>>>> "amfFaultHandler(event)"
>>>>>>> endPoint = "https://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=mARoGAlKZYBWmNOBwqTpTRYkqG%2Fk0cvrHwR5kgbfNFY%3D&reserved=0>
>>>>>>> "
>>>>>>> destination = "Meta"
>>>>>>> source = "Meta"/>
>>>>>>> </js:beads>
>>>>>>>
>>>>>>> <js:initialView>
>>>>>>> <js:View>
>>>>>>> <js:Labelid="testLabel" />
>>>>>>> </js:View>
>>>>>>> </js:initialView>
>>>>>>> </js:Application>
>>>>>>>
>>>>>>>
>>>>>>> It is not working and showing the following error in the browser:
>>>>>>>
>>>>>>> Failed to load https://winkelbeheer.cityfashi
>>>>>>> on.be/amfphp/gateway.php
>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=mARoGAlKZYBWmNOBwqTpTRYkqG%2Fk0cvrHwR5kgbfNFY%3D&reserved=0>:
>>>>>>> Response to preflight request doesn't pass access control check: No
>>>>>>> 'Access-Control-Allow-Origin' header is present on the requested resource.
>>>>>>> Origin 'http://localhost' is therefore not allowed access.
>>>>>>> Language.js:238destination fault handler
>>>>>>>
>>>>>>>    1. {code: -1004, message: "Invalid response type.", detail: "Invalid
>>>>>>>    XMLHttpRequest response status or type.", data: null}
>>>>>>>       1. code:-1004
>>>>>>>       2. data:null
>>>>>>>       3. detail:"Invalid XMLHttpRequest response status or type."
>>>>>>>       4. message:"Invalid response type."
>>>>>>>       5. __proto__:Object
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> It is able to compile and run regardless of the errors in compile
>>>>>>> log:
>>>>>>>
>>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>>> println
>>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>>> he/royale/reflection/AccessorDefinition.js:12: ERROR - required
>>>>>>> "org.apache.royale.reflection.TypeDefinition" namespace not
>>>>>>> provided yet
>>>>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>>
>>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>>> println
>>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>>> he/royale/reflection/AccessorDefinition.js:13: ERROR - required
>>>>>>> "org.apache.royale.reflection.VariableDefinition" namespace not
>>>>>>> provided yet
>>>>>>> goog.require('org.apache.royale.reflection.VariableDefinition');
>>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>>
>>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>>> println
>>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>>> he/royale/reflection/MethodDefinition.js:14: ERROR - required
>>>>>>> "org.apache.royale.reflection.TypeDefinition" namespace not
>>>>>>> provided yet
>>>>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>>
>>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>>> println
>>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>>> he/royale/reflection/ParameterDefinition.js:13: ERROR- required
>>>>>>> "org.apache.royale.reflection.TypeDefinition" namespace not
>>>>>>> provided yet
>>>>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>>
>>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>>> println
>>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>>> he/royale/reflection/TypeDefinition.js:15: ERROR - required
>>>>>>> "org.apache.royale.reflection.VariableDefinition" namespace not
>>>>>>> provided yet
>>>>>>> goog.require('org.apache.royale.reflection.VariableDefinition');
>>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>>
>>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>>> printSummary
>>>>>>> WARNING: 5 error(s), 0 warning(s)
>>>>>>> The project 'HelloRoyale' has been successfully compiled and
>>>>>>> optimized.
>>>>>>> 4.566387 seconds
>>>>>>>
>>>>>>>
>>>>>>> On Mon, Jan 15, 2018 at 7:38 PM, Piotr Zarzycki <
>>>>>>> piotrzarzycki21@gmail.com> wrote:
>>>>>>>
>>>>>>>> Carlos,
>>>>>>>>
>>>>>>>> No problem. I have also couple of huge things related to Royale to
>>>>>>>> do before my hand gets dirty with AMF! :) Unless someone urgently will
>>>>>>>> needed. :)
>>>>>>>>
>>>>>>>> Thanks, Piotr
>>>>>>>>
>>>>>>>> 2018-01-15 19:27 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>>>>>>>>
>>>>>>>>> Hi Piotr,
>>>>>>>>> I'll put this on my to do list, but have to do some things first.
>>>>>>>>> thanks
>>>>>>>>>
>>>>>>>>> 2018-01-15 9:26 GMT+01:00 Piotr Zarzycki <
>>>>>>>>> piotrzarzycki21@gmail.com>:
>>>>>>>>>
>>>>>>>>>> Hi Carlos,
>>>>>>>>>>
>>>>>>>>>> Can you describe more how to setup those examples ? Could you add
>>>>>>>>>> to RemoteObjectAMFTest README.md file where you describe steps. I would
>>>>>>>>>> like to have AMF on my list for tests and improvements. Whenever I look
>>>>>>>>>> into that I don't know how to proceed with it.
>>>>>>>>>>
>>>>>>>>>> Thanks, Piotr
>>>>>>>>>>
>>>>>>>>>> 2018-01-15 9:21 GMT+01:00 Carlos Rovira <ca...@apache.org>
>>>>>>>>>> :
>>>>>>>>>>
>>>>>>>>>>> Hi,
>>>>>>>>>>>
>>>>>>>>>>> there's an example that we get it working nicely at:
>>>>>>>>>>>
>>>>>>>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/
>>>>>>>>>>> royale/RemoteObjectAMFTest
>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Ftree%2Fdevelop%2Fexamples%2Froyale%2FRemoteObjectAMFTest&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7kdc48rEQiaI4Qp%2BBdfBcGPxddZIYrTUXrQ%2BN2u4tto%3D&reserved=0>
>>>>>>>>>>>
>>>>>>>>>>> you can use that as a starting point for your test
>>>>>>>>>>>
>>>>>>>>>>> As well a java web app that is used along that royale client
>>>>>>>>>>> example is at:
>>>>>>>>>>>
>>>>>>>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/amf
>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Ftree%2Fdevelop%2Fexamples%2Famf&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=PW4DYIeW4PetVe6BdFYjxFeAjCrqofPYtdbRTnJ4xjk%3D&reserved=0>
>>>>>>>>>>>
>>>>>>>>>>> thanks
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> 2018-01-15 3:56 GMT+01:00 Carlos Cruz <ca...@nbtbizcapital.com>
>>>>>>>>>>> :
>>>>>>>>>>>
>>>>>>>>>>>> I have a lot of experience with Flex remoting and BlazeDS with
>>>>>>>>>>>> Java, but with FlexJS and Royale I have none, but extrapolating from some
>>>>>>>>>>>> JS tests I've done with AMF at this line: amfTestService.send(
>>>>>>>>>>>> "getShippingMethods", []); you have to call a class in
>>>>>>>>>>>> gateway.php and a method. Your request needs at least 3 properties.
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> I'm also assuming your JS file and gateway.php are in the same
>>>>>>>>>>>> domain and same port (this gave me problems).
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Take what I said regarding my experience with FlexJS and Royale
>>>>>>>>>>>> into account.
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Carlos
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> *From:* Fréderic Cox [mailto:coxfrederic@gmail.com]
>>>>>>>>>>>> *Sent:* Sunday, January 14, 2018 4:01 PM
>>>>>>>>>>>>
>>>>>>>>>>>> *To:* users@royale.apache.org
>>>>>>>>>>>> *Subject:* Re: RemoteObject
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Script tag was stripped from the post:
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> import org.apache.royale.events.MouseEvent;
>>>>>>>>>>>>
>>>>>>>>>>>>                      import org.apache.royale.net.events.F
>>>>>>>>>>>> aultEvent;
>>>>>>>>>>>>
>>>>>>>>>>>>                      import org.apache.royale.net.events.R
>>>>>>>>>>>> esultEvent;
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>                      protectedfunction
>>>>>>>>>>>> textbutton_clickHandler(event:org.apache.royale.events.Mouse
>>>>>>>>>>>> Event):void
>>>>>>>>>>>>
>>>>>>>>>>>>                      {
>>>>>>>>>>>>
>>>>>>>>>>>>                            statusLabel.text = "calling.......";
>>>>>>>>>>>>
>>>>>>>>>>>>                            amfTestService.addEventListener(
>>>>>>>>>>>> "fault", amfTestService_faultHandler);
>>>>>>>>>>>>
>>>>>>>>>>>>                            amfTestService.addEventListener(
>>>>>>>>>>>> "result", amfTestService_resultHandler);
>>>>>>>>>>>>
>>>>>>>>>>>>                            amfTestService.send("getShippi
>>>>>>>>>>>> ngMethods", []);
>>>>>>>>>>>>
>>>>>>>>>>>>                      }
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>                      protectedfunction
>>>>>>>>>>>> amfTestService_faultHandler(event:FaultEvent):void
>>>>>>>>>>>>
>>>>>>>>>>>>                      {
>>>>>>>>>>>>
>>>>>>>>>>>>                            statusLabel.text = "error!";
>>>>>>>>>>>>
>>>>>>>>>>>>                      }
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>                      protectedfunction
>>>>>>>>>>>> amfTestService_resultHandler(event:ResultEvent):void
>>>>>>>>>>>>
>>>>>>>>>>>>                      {
>>>>>>>>>>>>
>>>>>>>>>>>>                            statusLabel.text = "result!";
>>>>>>>>>>>>
>>>>>>>>>>>>                      }
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> none of the events are triggered ..URL is
>>>>>>>>>>>> http://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=EJDBQBL83yBhDn%2BWWgCCVyw0N3tnakhZ7UdEt4JFNaY%3D&reserved=0>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> On Fri, Jan 12, 2018 at 4:55 AM, Carlos Cruz <
>>>>>>>>>>>> carlos@nbtbizcapital.com> wrote:
>>>>>>>>>>>>
>>>>>>>>>>>> I may be blind (and or ignorant as I'm more familiar with Flex)
>>>>>>>>>>>> but where
>>>>>>>>>>>> are you sending an AMF request? I don't see any code that sends
>>>>>>>>>>>> a request to
>>>>>>>>>>>> a service and invokes method.
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> -----Original Message-----
>>>>>>>>>>>> From: coxfrederic [mailto:coxfrederic@gmail.com]
>>>>>>>>>>>> Sent: Thursday, January 11, 2018 9:09 PM
>>>>>>>>>>>> To: users@royale.apache.org
>>>>>>>>>>>> Subject: Re: RemoteObject
>>>>>>>>>>>>
>>>>>>>>>>>> <?xml version="1.0" encoding="utf-8"?>
>>>>>>>>>>>>
>>>>>>>>>>>> <js:Application xmlns:fx="http://ns.adobe.com/mxml/2009
>>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.adobe.com%2Fmxml%2F2009&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7cSxKCospCIpbkKY4F%2Fp5lsHBH%2BPFp5Vny2ftXWmL5A%3D&reserved=0>
>>>>>>>>>>>> "
>>>>>>>>>>>>                    xmlns:js="library://ns.apache
>>>>>>>>>>>> .org/royale/basic
>>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.apache.org%2Froyale%2Fbasic&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=D%2FBslvPtV9pNNjpoS4KCQlYHB8ArUYEIXCXuAVoNgYM%3D&reserved=0>"
>>>>>>>>>>>> >
>>>>>>>>>>>>         <fx:Script>
>>>>>>>>>>>>
>>>>>>>>>>>>         </fx:Script>
>>>>>>>>>>>>     <js:valuesImpl>
>>>>>>>>>>>>         <js:SimpleCSSValuesImpl />
>>>>>>>>>>>>     </js:valuesImpl>
>>>>>>>>>>>>
>>>>>>>>>>>>         <js:beads>
>>>>>>>>>>>>                 <js:ClassAliasBead />
>>>>>>>>>>>>                 <js:RemoteObject id="amfTestService"
>>>>>>>>>>>>
>>>>>>>>>>>> endPoint="http://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=EJDBQBL83yBhDn%2BWWgCCVyw0N3tnakhZ7UdEt4JFNaY%3D&reserved=0>
>>>>>>>>>>>> "
>>>>>>>>>>>>
>>>>>>>>>>>>  destination="Meta"
>>>>>>>>>>>> source="Meta" />
>>>>>>>>>>>>         </js:beads>
>>>>>>>>>>>>
>>>>>>>>>>>>     <js:initialView>
>>>>>>>>>>>>         <js:View>
>>>>>>>>>>>>                         <js:VGroup>
>>>>>>>>>>>>                                 <js:Label id="statusLabel"
>>>>>>>>>>>> text="Hello
>>>>>>>>>>>> World!" />
>>>>>>>>>>>>                                 <js:TextButton text="Get AMF
>>>>>>>>>>>> data"
>>>>>>>>>>>> click="textbutton_clickHandler(event)" />
>>>>>>>>>>>>                         </js:VGroup>
>>>>>>>>>>>>         </js:View>
>>>>>>>>>>>>     </js:initialView>
>>>>>>>>>>>> </js:Application>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Any idea why I'm not getting a fault nor success event on this?
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> --
>>>>>>>>>>>> Sent from: http://apache-royale-users.20374.n8.nabble.com/
>>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fapache-royale-users.20374.n8.nabble.com%2F&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=xvY8nK1QKlWduh6p5x8y19jm%2Br60PSFVlNdi6TRsPmw%3D&reserved=0>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> --
>>>>>>>>>>> Carlos Rovira
>>>>>>>>>>> http://about.me/carlosrovira
>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fabout.me%2Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=55MSUXBM2zE5U0csgV1harcuXvKyZ2gd%2BO%2FmD7hjJ50%3D&reserved=0>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> --
>>>>>>>>>>
>>>>>>>>>> Piotr Zarzycki
>>>>>>>>>>
>>>>>>>>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=NG2rkkxhfc7MTSVRqHzEmHL8HuUpvXI72B9nkW2QfdU%3D&reserved=0>*
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>>
>>>>>>>> ...
>
>


-- 

Piotr Zarzycki

Patreon: *https://www.patreon.com/piotrzarzycki
<https://www.patreon.com/piotrzarzycki>*

Re: RemoteObject

Posted by Carlos Rovira <ca...@apache.org>.
Hi Prashant,
that would be great! thanks for looking into this! We need to get to a
robust Royale AMF implementation!

Carlos

2018-02-16 16:46 GMT+01:00 Prashant Kumar <pr...@gmail.com>:

> I tested couple of scenarios of FlexJS AMF. only fews are working. I will
> check with Royal and share output tomorrow.
>
> On 16-Feb-2018 8:30 PM, "Piotr Zarzycki" <pi...@gmail.com>
> wrote:
>
>> Frederic,
>>
>> Could you share some hello world implementation of AMFPHP along with
>> Hello World app in Flex ? I may also look into that and compare the
>> results. Just don't want to waste time on setup things to prepare AMFPHP
>> stuff. Do you have such things ?
>>
>> Thanks, Piotr
>>
>>
>> 2018-02-16 15:57 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>>
>>> Hi Carlos,
>>>
>>> Sure I’ll see what I can do. Feel I have lots to leatn about Royale and
>>> AMF (it just works with Flash/AIR so not up to date about the inner
>>> workings).
>>>
>>> I’ll try to test the examples over the weekend. Do you think the AMFPHP
>>> version could be an issue or is it assumed to work in Royale if it works in
>>> Flex?
>>>
>>> Verstuurd vanaf mijn iPhone
>>>
>>> Op 16 feb. 2018 om 12:28 heeft Carlos Rovira <ca...@apache.org>
>>> het volgende geschreven:
>>>
>>> Hi Frederic,
>>> thanks for filling this and take a look into AMF!
>>> Hope you could help us a bit with this.
>>>
>>> 2018-02-16 0:21 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>>>
>>>> Hi Alex,
>>>>
>>>> I created https://github.com/apache/royale-asjs/issues/119, hope that
>>>> is in the correct place and with more readable mark-up.
>>>>
>>>> Regards,
>>>>
>>>> Fréderic
>>>>
>>>> On Thu, Feb 15, 2018 at 8:57 PM, Alex Harui <ah...@adobe.com> wrote:
>>>>
>>>>> Hi Frederic,
>>>>>
>>>>> Where is this output you posted coming from, a network monitor?  It
>>>>> was too hard to read, so please create a bug report on GitHub and post it
>>>>> there.
>>>>>
>>>>> You might be able to use a network monitor to compare what Flex sent
>>>>> vs what Royale is sending.  What does your Flex usage of RemoteObject look
>>>>> like?
>>>>>
>>>>> HTH,
>>>>> -Alex
>>>>>
>>>>> From: Fréderic Cox <co...@gmail.com>
>>>>> Reply-To: "users@royale.apache.org" <us...@royale.apache.org>
>>>>> Date: Thursday, February 15, 2018 at 5:09 AM
>>>>> To: "users@royale.apache.org" <us...@royale.apache.org>
>>>>> Subject: Re: RemoteObject
>>>>>
>>>>> Hi Piotr,
>>>>>
>>>>> Thanks, I installed the extension and now I'm not getting the CORS
>>>>> error anymore.
>>>>> I'm not getting any fault or result event triggered either....
>>>>>
>>>>> The endPoint set is
>>>>> https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php
>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fclients.cityfashion.dev.exuvis.com%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=67VMfKVGZo%2BarMstlt%2BZbX5OdTomYDQNSgM07ycK%2Bvc%3D&reserved=0>
>>>>>
>>>>> This is correct, right? (I use this endpoint in Flex and that works
>>>>> fine)
>>>>>
>>>>>
>>>>>    1. Request URL:
>>>>>       https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php
>>>>>       <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fclients.cityfashion.dev.exuvis.com%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=67VMfKVGZo%2BarMstlt%2BZbX5OdTomYDQNSgM07ycK%2Bvc%3D&reserved=0>
>>>>>       2. Request Method:
>>>>>       OPTIONS
>>>>>       3. Status Code:
>>>>>       200 OK
>>>>>       4. Remote Address:
>>>>>       188.93.153.101:443
>>>>>       <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2F188.93.153.101%3A443&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=UWqG%2BqQTcL1fTnck9i5BPXmrn3ZlgRf8XCPpQ8EcJrE%3D&reserved=0>
>>>>>       5. Referrer Policy:
>>>>>       no-referrer-when-downgrade
>>>>>       1. Response Headersview source
>>>>>       1. Connection:
>>>>>       keep-alive
>>>>>       2. Content-Encoding:
>>>>>       gzip
>>>>>       3. Content-Length:
>>>>>       286
>>>>>       4. Content-Type:
>>>>>       text/html; charset=UTF-8
>>>>>       5. Date:
>>>>>       Thu, 15 Feb 2018 13:08:17 GMT
>>>>>       6. Server:
>>>>>       nginx
>>>>>       7. Vary:
>>>>>       Accept-Encoding
>>>>>       2. Request Headersview source
>>>>>       1. Accept:
>>>>>       */*
>>>>>       2. Accept-Encoding:
>>>>>       gzip, deflate, br
>>>>>       3. Accept-Language:
>>>>>       en-GB,en-US;q=0.9,en;q=0.8
>>>>>       4. Access-Control-Request-Headers:
>>>>>       content-type
>>>>>       5. Access-Control-Request-Method:
>>>>>       POST
>>>>>       6. Connection:
>>>>>       keep-alive
>>>>>       7. Host:
>>>>>       clients.cityfashion.dev.exuvis.com
>>>>>       <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fclients.cityfashion.dev.exuvis.com&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=%2BiTohXW1uaTpydtAlGWa0leTvEQKK2Wg6XtN%2FqQ73%2F0%3D&reserved=0>
>>>>>       8. Origin:
>>>>>       null
>>>>>       9. User-Agent:
>>>>>       Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_3)
>>>>>       AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.167 Safari/537.36
>>>>>
>>>>> Response is:
>>>>>
>>>>> <p>amfphp and this gateway are installed correctly. You may now
>>>>> connect to this gateway from Flash.</p><p>Note: If you're reading an old
>>>>> tutorial, it will tell you that you should see a download window instead of
>>>>> this message. This confused people so this is the new behaviour starting
>>>>> from amfphp 1.2.</p><p><a href='http://www.amfphp.org/docs
>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.amfphp.org%2Fdocs&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=%2FGtfS6iuQCrcoifQ5pUOXPJ0JJZcOQaMyYsscjKzA9I%3D&reserved=0>'>View
>>>>> the amfphp documentation</p><p><a href='browser'>Load the service
>>>>> browser</a></p><pre>
>>>>>
>>>>> Should I target a specific file with the JS version? Should the
>>>>> endPoint be different?
>>>>>
>>>>> On Thu, Feb 15, 2018 at 12:07 PM, Piotr Zarzycki <
>>>>> piotrzarzycki21@gmail.com> wrote:
>>>>>
>>>>>> Frederic,
>>>>>>
>>>>>> It looks like it is not problem with framework, but rather CORS
>>>>>> issue. Maybe try to install this plugin [1] and add to the list your url.
>>>>>>
>>>>>> [1] https://chrome.google.com/webstore/detail/allow-control-
>>>>>> allow-origi/nlfbmbojpeacfghkpbjhddihlkkiljbi?hl=en
>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fchrome.google.com%2Fwebstore%2Fdetail%2Fallow-control-allow-origi%2Fnlfbmbojpeacfghkpbjhddihlkkiljbi%3Fhl%3Den&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=CbZH3KQcH0oGU%2FbnBtyVp%2B9zeqDEUcK9Y6UFd0BIESM%3D&reserved=0>
>>>>>>
>>>>>> Piotr
>>>>>>
>>>>>> 2018-02-15 12:04 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>>>>>>
>>>>>>> For me it is still not working in latest release 0.9.1. I based my
>>>>>>> example on the example in the SDK.
>>>>>>>
>>>>>>> <?xml version="1.0" encoding="utf-8"?>
>>>>>>> <js:Applicationxmlns:fx="http://ns.adobe.com/mxml/2009
>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.adobe.com%2Fmxml%2F2009&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7cSxKCospCIpbkKY4F%2Fp5lsHBH%2BPFp5Vny2ftXWmL5A%3D&reserved=0>
>>>>>>> "
>>>>>>> xmlns:js="library://ns.apache.org/royale/basic
>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.apache.org%2Froyale%2Fbasic&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=D%2FBslvPtV9pNNjpoS4KCQlYHB8ArUYEIXCXuAVoNgYM%3D&reserved=0>
>>>>>>> "applicationComplete="applicationCompleteHandler(event);">
>>>>>>>
>>>>>>>     <fx:Script>
>>>>>>>         <![CDATA[
>>>>>>>             import org.apache.royale.net
>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Forg.apache.royale.net&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=ATrXbo2PLqz1dNeyvxVu89zy3yaKPxwIwQm9tSG7ybs%3D&reserved=0>
>>>>>>> .RemoteObject;
>>>>>>>             import org.apache.royale.net.events.FaultEvent;
>>>>>>>             import org.apache.royale.net.events.ResultEvent;
>>>>>>>
>>>>>>>             privatefunctionapplicationCompleteHandler(evt:Event):
>>>>>>> void{
>>>>>>>                 testLabel.text = "Requesting from AMF";
>>>>>>>                 service.send("getPackages", null);
>>>>>>>             }
>>>>>>>
>>>>>>>             privatefunctionamfFaultHandler(evt:FaultEvent):void{
>>>>>>>                 testLabel.text = "Fault in calling AMF";
>>>>>>>             }
>>>>>>>
>>>>>>>             privatefunctionamfResultHandler(evt:ResultEvent):void{
>>>>>>>                 testLabel.text = "Result received from AMF";
>>>>>>>             }
>>>>>>>         ]]>
>>>>>>>     </fx:Script>
>>>>>>>
>>>>>>> <js:valuesImpl>
>>>>>>> <js:SimpleCSSValuesImpl />
>>>>>>> </js:valuesImpl>
>>>>>>>
>>>>>>>    <js:beads>
>>>>>>> <js:ClassAliasBead />
>>>>>>> <js:RemoteObjectid="service"result="amfResultHandler(event)"fault=
>>>>>>> "amfFaultHandler(event)"
>>>>>>> endPoint = "https://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=mARoGAlKZYBWmNOBwqTpTRYkqG%2Fk0cvrHwR5kgbfNFY%3D&reserved=0>
>>>>>>> "
>>>>>>> destination = "Meta"
>>>>>>> source = "Meta"/>
>>>>>>> </js:beads>
>>>>>>>
>>>>>>> <js:initialView>
>>>>>>> <js:View>
>>>>>>> <js:Labelid="testLabel" />
>>>>>>> </js:View>
>>>>>>> </js:initialView>
>>>>>>> </js:Application>
>>>>>>>
>>>>>>>
>>>>>>> It is not working and showing the following error in the browser:
>>>>>>>
>>>>>>> Failed to load https://winkelbeheer.cityfashi
>>>>>>> on.be/amfphp/gateway.php
>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=mARoGAlKZYBWmNOBwqTpTRYkqG%2Fk0cvrHwR5kgbfNFY%3D&reserved=0>:
>>>>>>> Response to preflight request doesn't pass access control check: No
>>>>>>> 'Access-Control-Allow-Origin' header is present on the requested resource.
>>>>>>> Origin 'http://localhost' is therefore not allowed access.
>>>>>>> Language.js:238destination fault handler
>>>>>>>
>>>>>>>    1. {code: -1004, message: "Invalid response type.", detail: "Invalid
>>>>>>>    XMLHttpRequest response status or type.", data: null}
>>>>>>>       1. code:-1004
>>>>>>>       2. data:null
>>>>>>>       3. detail:"Invalid XMLHttpRequest response status or type."
>>>>>>>       4. message:"Invalid response type."
>>>>>>>       5. __proto__:Object
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> It is able to compile and run regardless of the errors in compile
>>>>>>> log:
>>>>>>>
>>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>>> println
>>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>>> he/royale/reflection/AccessorDefinition.js:12: ERROR - required
>>>>>>> "org.apache.royale.reflection.TypeDefinition" namespace not
>>>>>>> provided yet
>>>>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>>
>>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>>> println
>>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>>> he/royale/reflection/AccessorDefinition.js:13: ERROR - required
>>>>>>> "org.apache.royale.reflection.VariableDefinition" namespace not
>>>>>>> provided yet
>>>>>>> goog.require('org.apache.royale.reflection.VariableDefinition');
>>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>>
>>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>>> println
>>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>>> he/royale/reflection/MethodDefinition.js:14: ERROR - required
>>>>>>> "org.apache.royale.reflection.TypeDefinition" namespace not
>>>>>>> provided yet
>>>>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>>
>>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>>> println
>>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>>> he/royale/reflection/ParameterDefinition.js:13: ERROR- required
>>>>>>> "org.apache.royale.reflection.TypeDefinition" namespace not
>>>>>>> provided yet
>>>>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>>
>>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>>> println
>>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>>> he/royale/reflection/TypeDefinition.js:15: ERROR - required
>>>>>>> "org.apache.royale.reflection.VariableDefinition" namespace not
>>>>>>> provided yet
>>>>>>> goog.require('org.apache.royale.reflection.VariableDefinition');
>>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>>
>>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>>> printSummary
>>>>>>> WARNING: 5 error(s), 0 warning(s)
>>>>>>> The project 'HelloRoyale' has been successfully compiled and
>>>>>>> optimized.
>>>>>>> 4.566387 seconds
>>>>>>>
>>>>>>>
>>>>>>> On Mon, Jan 15, 2018 at 7:38 PM, Piotr Zarzycki <
>>>>>>> piotrzarzycki21@gmail.com> wrote:
>>>>>>>
>>>>>>>> Carlos,
>>>>>>>>
>>>>>>>> No problem. I have also couple of huge things related to Royale to
>>>>>>>> do before my hand gets dirty with AMF! :) Unless someone urgently will
>>>>>>>> needed. :)
>>>>>>>>
>>>>>>>> Thanks, Piotr
>>>>>>>>
>>>>>>>> 2018-01-15 19:27 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>>>>>>>>
>>>>>>>>> Hi Piotr,
>>>>>>>>> I'll put this on my to do list, but have to do some things first.
>>>>>>>>> thanks
>>>>>>>>>
>>>>>>>>> 2018-01-15 9:26 GMT+01:00 Piotr Zarzycki <
>>>>>>>>> piotrzarzycki21@gmail.com>:
>>>>>>>>>
>>>>>>>>>> Hi Carlos,
>>>>>>>>>>
>>>>>>>>>> Can you describe more how to setup those examples ? Could you add
>>>>>>>>>> to RemoteObjectAMFTest README.md file where you describe steps. I would
>>>>>>>>>> like to have AMF on my list for tests and improvements. Whenever I look
>>>>>>>>>> into that I don't know how to proceed with it.
>>>>>>>>>>
>>>>>>>>>> Thanks, Piotr
>>>>>>>>>>
>>>>>>>>>> 2018-01-15 9:21 GMT+01:00 Carlos Rovira <ca...@apache.org>
>>>>>>>>>> :
>>>>>>>>>>
>>>>>>>>>>> Hi,
>>>>>>>>>>>
>>>>>>>>>>> there's an example that we get it working nicely at:
>>>>>>>>>>>
>>>>>>>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/
>>>>>>>>>>> royale/RemoteObjectAMFTest
>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Ftree%2Fdevelop%2Fexamples%2Froyale%2FRemoteObjectAMFTest&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7kdc48rEQiaI4Qp%2BBdfBcGPxddZIYrTUXrQ%2BN2u4tto%3D&reserved=0>
>>>>>>>>>>>
>>>>>>>>>>> you can use that as a starting point for your test
>>>>>>>>>>>
>>>>>>>>>>> As well a java web app that is used along that royale client
>>>>>>>>>>> example is at:
>>>>>>>>>>>
>>>>>>>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/amf
>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Ftree%2Fdevelop%2Fexamples%2Famf&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=PW4DYIeW4PetVe6BdFYjxFeAjCrqofPYtdbRTnJ4xjk%3D&reserved=0>
>>>>>>>>>>>
>>>>>>>>>>> thanks
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> 2018-01-15 3:56 GMT+01:00 Carlos Cruz <ca...@nbtbizcapital.com>
>>>>>>>>>>> :
>>>>>>>>>>>
>>>>>>>>>>>> I have a lot of experience with Flex remoting and BlazeDS with
>>>>>>>>>>>> Java, but with FlexJS and Royale I have none, but extrapolating from some
>>>>>>>>>>>> JS tests I've done with AMF at this line: amfTestService.send(
>>>>>>>>>>>> "getShippingMethods", []); you have to call a class in
>>>>>>>>>>>> gateway.php and a method. Your request needs at least 3 properties.
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> I'm also assuming your JS file and gateway.php are in the same
>>>>>>>>>>>> domain and same port (this gave me problems).
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Take what I said regarding my experience with FlexJS and Royale
>>>>>>>>>>>> into account.
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Carlos
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> *From:* Fréderic Cox [mailto:coxfrederic@gmail.com]
>>>>>>>>>>>> *Sent:* Sunday, January 14, 2018 4:01 PM
>>>>>>>>>>>>
>>>>>>>>>>>> *To:* users@royale.apache.org
>>>>>>>>>>>> *Subject:* Re: RemoteObject
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Script tag was stripped from the post:
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> import org.apache.royale.events.MouseEvent;
>>>>>>>>>>>>
>>>>>>>>>>>>                      import org.apache.royale.net.events.F
>>>>>>>>>>>> aultEvent;
>>>>>>>>>>>>
>>>>>>>>>>>>                      import org.apache.royale.net.events.R
>>>>>>>>>>>> esultEvent;
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>                      protectedfunction
>>>>>>>>>>>> textbutton_clickHandler(event:org.apache.royale.events.Mouse
>>>>>>>>>>>> Event):void
>>>>>>>>>>>>
>>>>>>>>>>>>                      {
>>>>>>>>>>>>
>>>>>>>>>>>>                            statusLabel.text = "calling.......";
>>>>>>>>>>>>
>>>>>>>>>>>>                            amfTestService.addEventListener(
>>>>>>>>>>>> "fault", amfTestService_faultHandler);
>>>>>>>>>>>>
>>>>>>>>>>>>                            amfTestService.addEventListener(
>>>>>>>>>>>> "result", amfTestService_resultHandler);
>>>>>>>>>>>>
>>>>>>>>>>>>                            amfTestService.send("getShippi
>>>>>>>>>>>> ngMethods", []);
>>>>>>>>>>>>
>>>>>>>>>>>>                      }
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>                      protectedfunction
>>>>>>>>>>>> amfTestService_faultHandler(event:FaultEvent):void
>>>>>>>>>>>>
>>>>>>>>>>>>                      {
>>>>>>>>>>>>
>>>>>>>>>>>>                            statusLabel.text = "error!";
>>>>>>>>>>>>
>>>>>>>>>>>>                      }
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>                      protectedfunction
>>>>>>>>>>>> amfTestService_resultHandler(event:ResultEvent):void
>>>>>>>>>>>>
>>>>>>>>>>>>                      {
>>>>>>>>>>>>
>>>>>>>>>>>>                            statusLabel.text = "result!";
>>>>>>>>>>>>
>>>>>>>>>>>>                      }
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> none of the events are triggered ..URL is
>>>>>>>>>>>> http://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=EJDBQBL83yBhDn%2BWWgCCVyw0N3tnakhZ7UdEt4JFNaY%3D&reserved=0>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> On Fri, Jan 12, 2018 at 4:55 AM, Carlos Cruz <
>>>>>>>>>>>> carlos@nbtbizcapital.com> wrote:
>>>>>>>>>>>>
>>>>>>>>>>>> I may be blind (and or ignorant as I'm more familiar with Flex)
>>>>>>>>>>>> but where
>>>>>>>>>>>> are you sending an AMF request? I don't see any code that sends
>>>>>>>>>>>> a request to
>>>>>>>>>>>> a service and invokes method.
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> -----Original Message-----
>>>>>>>>>>>> From: coxfrederic [mailto:coxfrederic@gmail.com]
>>>>>>>>>>>> Sent: Thursday, January 11, 2018 9:09 PM
>>>>>>>>>>>> To: users@royale.apache.org
>>>>>>>>>>>> Subject: Re: RemoteObject
>>>>>>>>>>>>
>>>>>>>>>>>> <?xml version="1.0" encoding="utf-8"?>
>>>>>>>>>>>>
>>>>>>>>>>>> <js:Application xmlns:fx="http://ns.adobe.com/mxml/2009
>>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.adobe.com%2Fmxml%2F2009&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7cSxKCospCIpbkKY4F%2Fp5lsHBH%2BPFp5Vny2ftXWmL5A%3D&reserved=0>
>>>>>>>>>>>> "
>>>>>>>>>>>>                    xmlns:js="library://ns.apache
>>>>>>>>>>>> .org/royale/basic
>>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.apache.org%2Froyale%2Fbasic&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=D%2FBslvPtV9pNNjpoS4KCQlYHB8ArUYEIXCXuAVoNgYM%3D&reserved=0>"
>>>>>>>>>>>> >
>>>>>>>>>>>>         <fx:Script>
>>>>>>>>>>>>
>>>>>>>>>>>>         </fx:Script>
>>>>>>>>>>>>     <js:valuesImpl>
>>>>>>>>>>>>         <js:SimpleCSSValuesImpl />
>>>>>>>>>>>>     </js:valuesImpl>
>>>>>>>>>>>>
>>>>>>>>>>>>         <js:beads>
>>>>>>>>>>>>                 <js:ClassAliasBead />
>>>>>>>>>>>>                 <js:RemoteObject id="amfTestService"
>>>>>>>>>>>>
>>>>>>>>>>>> endPoint="http://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=EJDBQBL83yBhDn%2BWWgCCVyw0N3tnakhZ7UdEt4JFNaY%3D&reserved=0>
>>>>>>>>>>>> "
>>>>>>>>>>>>
>>>>>>>>>>>>  destination="Meta"
>>>>>>>>>>>> source="Meta" />
>>>>>>>>>>>>         </js:beads>
>>>>>>>>>>>>
>>>>>>>>>>>>     <js:initialView>
>>>>>>>>>>>>         <js:View>
>>>>>>>>>>>>                         <js:VGroup>
>>>>>>>>>>>>                                 <js:Label id="statusLabel"
>>>>>>>>>>>> text="Hello
>>>>>>>>>>>> World!" />
>>>>>>>>>>>>                                 <js:TextButton text="Get AMF
>>>>>>>>>>>> data"
>>>>>>>>>>>> click="textbutton_clickHandler(event)" />
>>>>>>>>>>>>                         </js:VGroup>
>>>>>>>>>>>>         </js:View>
>>>>>>>>>>>>     </js:initialView>
>>>>>>>>>>>> </js:Application>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Any idea why I'm not getting a fault nor success event on this?
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> --
>>>>>>>>>>>> Sent from: http://apache-royale-users.20374.n8.nabble.com/
>>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fapache-royale-users.20374.n8.nabble.com%2F&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=xvY8nK1QKlWduh6p5x8y19jm%2Br60PSFVlNdi6TRsPmw%3D&reserved=0>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> --
>>>>>>>>>>> Carlos Rovira
>>>>>>>>>>> http://about.me/carlosrovira
>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fabout.me%2Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=55MSUXBM2zE5U0csgV1harcuXvKyZ2gd%2BO%2FmD7hjJ50%3D&reserved=0>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> --
>>>>>>>>>>
>>>>>>>>>> Piotr Zarzycki
>>>>>>>>>>
>>>>>>>>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=NG2rkkxhfc7MTSVRqHzEmHL8HuUpvXI72B9nkW2QfdU%3D&reserved=0>*
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>>
>>>>>>>> ...
>
>


-- 
Carlos Rovira
http://about.me/carlosrovira

Re: RemoteObject

Posted by Prashant Kumar <pr...@gmail.com>.
I tested couple of scenarios of FlexJS AMF. only fews are working. I will
check with Royal and share output tomorrow.

On 16-Feb-2018 8:30 PM, "Piotr Zarzycki" <pi...@gmail.com> wrote:

> Frederic,
>
> Could you share some hello world implementation of AMFPHP along with Hello
> World app in Flex ? I may also look into that and compare the results. Just
> don't want to waste time on setup things to prepare AMFPHP stuff. Do you
> have such things ?
>
> Thanks, Piotr
>
>
> 2018-02-16 15:57 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>
>> Hi Carlos,
>>
>> Sure I’ll see what I can do. Feel I have lots to leatn about Royale and
>> AMF (it just works with Flash/AIR so not up to date about the inner
>> workings).
>>
>> I’ll try to test the examples over the weekend. Do you think the AMFPHP
>> version could be an issue or is it assumed to work in Royale if it works in
>> Flex?
>>
>> Verstuurd vanaf mijn iPhone
>>
>> Op 16 feb. 2018 om 12:28 heeft Carlos Rovira <ca...@apache.org>
>> het volgende geschreven:
>>
>> Hi Frederic,
>> thanks for filling this and take a look into AMF!
>> Hope you could help us a bit with this.
>>
>> 2018-02-16 0:21 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>>
>>> Hi Alex,
>>>
>>> I created https://github.com/apache/royale-asjs/issues/119, hope that
>>> is in the correct place and with more readable mark-up.
>>>
>>> Regards,
>>>
>>> Fréderic
>>>
>>> On Thu, Feb 15, 2018 at 8:57 PM, Alex Harui <ah...@adobe.com> wrote:
>>>
>>>> Hi Frederic,
>>>>
>>>> Where is this output you posted coming from, a network monitor?  It was
>>>> too hard to read, so please create a bug report on GitHub and post it there.
>>>>
>>>> You might be able to use a network monitor to compare what Flex sent vs
>>>> what Royale is sending.  What does your Flex usage of RemoteObject look
>>>> like?
>>>>
>>>> HTH,
>>>> -Alex
>>>>
>>>> From: Fréderic Cox <co...@gmail.com>
>>>> Reply-To: "users@royale.apache.org" <us...@royale.apache.org>
>>>> Date: Thursday, February 15, 2018 at 5:09 AM
>>>> To: "users@royale.apache.org" <us...@royale.apache.org>
>>>> Subject: Re: RemoteObject
>>>>
>>>> Hi Piotr,
>>>>
>>>> Thanks, I installed the extension and now I'm not getting the CORS
>>>> error anymore.
>>>> I'm not getting any fault or result event triggered either....
>>>>
>>>> The endPoint set is
>>>> https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php
>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fclients.cityfashion.dev.exuvis.com%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=67VMfKVGZo%2BarMstlt%2BZbX5OdTomYDQNSgM07ycK%2Bvc%3D&reserved=0>
>>>>
>>>> This is correct, right? (I use this endpoint in Flex and that works
>>>> fine)
>>>>
>>>>
>>>>    1. Request URL:
>>>>       https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php
>>>>       <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fclients.cityfashion.dev.exuvis.com%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=67VMfKVGZo%2BarMstlt%2BZbX5OdTomYDQNSgM07ycK%2Bvc%3D&reserved=0>
>>>>       2. Request Method:
>>>>       OPTIONS
>>>>       3. Status Code:
>>>>       200 OK
>>>>       4. Remote Address:
>>>>       188.93.153.101:443
>>>>       <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2F188.93.153.101%3A443&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=UWqG%2BqQTcL1fTnck9i5BPXmrn3ZlgRf8XCPpQ8EcJrE%3D&reserved=0>
>>>>       5. Referrer Policy:
>>>>       no-referrer-when-downgrade
>>>>       1. Response Headersview source
>>>>       1. Connection:
>>>>       keep-alive
>>>>       2. Content-Encoding:
>>>>       gzip
>>>>       3. Content-Length:
>>>>       286
>>>>       4. Content-Type:
>>>>       text/html; charset=UTF-8
>>>>       5. Date:
>>>>       Thu, 15 Feb 2018 13:08:17 GMT
>>>>       6. Server:
>>>>       nginx
>>>>       7. Vary:
>>>>       Accept-Encoding
>>>>       2. Request Headersview source
>>>>       1. Accept:
>>>>       */*
>>>>       2. Accept-Encoding:
>>>>       gzip, deflate, br
>>>>       3. Accept-Language:
>>>>       en-GB,en-US;q=0.9,en;q=0.8
>>>>       4. Access-Control-Request-Headers:
>>>>       content-type
>>>>       5. Access-Control-Request-Method:
>>>>       POST
>>>>       6. Connection:
>>>>       keep-alive
>>>>       7. Host:
>>>>       clients.cityfashion.dev.exuvis.com
>>>>       <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fclients.cityfashion.dev.exuvis.com&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=%2BiTohXW1uaTpydtAlGWa0leTvEQKK2Wg6XtN%2FqQ73%2F0%3D&reserved=0>
>>>>       8. Origin:
>>>>       null
>>>>       9. User-Agent:
>>>>       Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_3)
>>>>       AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.167 Safari/537.36
>>>>
>>>> Response is:
>>>>
>>>> <p>amfphp and this gateway are installed correctly. You may now connect
>>>> to this gateway from Flash.</p><p>Note: If you're reading an old tutorial,
>>>> it will tell you that you should see a download window instead of this
>>>> message. This confused people so this is the new behaviour starting from
>>>> amfphp 1.2.</p><p><a href='http://www.amfphp.org/docs
>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.amfphp.org%2Fdocs&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=%2FGtfS6iuQCrcoifQ5pUOXPJ0JJZcOQaMyYsscjKzA9I%3D&reserved=0>'>View
>>>> the amfphp documentation</p><p><a href='browser'>Load the service
>>>> browser</a></p><pre>
>>>>
>>>> Should I target a specific file with the JS version? Should the
>>>> endPoint be different?
>>>>
>>>> On Thu, Feb 15, 2018 at 12:07 PM, Piotr Zarzycki <
>>>> piotrzarzycki21@gmail.com> wrote:
>>>>
>>>>> Frederic,
>>>>>
>>>>> It looks like it is not problem with framework, but rather CORS issue.
>>>>> Maybe try to install this plugin [1] and add to the list your url.
>>>>>
>>>>> [1] https://chrome.google.com/webstore/detail/allow-control-
>>>>> allow-origi/nlfbmbojpeacfghkpbjhddihlkkiljbi?hl=en
>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fchrome.google.com%2Fwebstore%2Fdetail%2Fallow-control-allow-origi%2Fnlfbmbojpeacfghkpbjhddihlkkiljbi%3Fhl%3Den&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=CbZH3KQcH0oGU%2FbnBtyVp%2B9zeqDEUcK9Y6UFd0BIESM%3D&reserved=0>
>>>>>
>>>>> Piotr
>>>>>
>>>>> 2018-02-15 12:04 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>>>>>
>>>>>> For me it is still not working in latest release 0.9.1. I based my
>>>>>> example on the example in the SDK.
>>>>>>
>>>>>> <?xml version="1.0" encoding="utf-8"?>
>>>>>> <js:Applicationxmlns:fx="http://ns.adobe.com/mxml/2009
>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.adobe.com%2Fmxml%2F2009&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7cSxKCospCIpbkKY4F%2Fp5lsHBH%2BPFp5Vny2ftXWmL5A%3D&reserved=0>
>>>>>> "
>>>>>> xmlns:js="library://ns.apache.org/royale/basic
>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.apache.org%2Froyale%2Fbasic&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=D%2FBslvPtV9pNNjpoS4KCQlYHB8ArUYEIXCXuAVoNgYM%3D&reserved=0>
>>>>>> "applicationComplete="applicationCompleteHandler(event);">
>>>>>>
>>>>>>     <fx:Script>
>>>>>>         <![CDATA[
>>>>>>             import org.apache.royale.net
>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Forg.apache.royale.net&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=ATrXbo2PLqz1dNeyvxVu89zy3yaKPxwIwQm9tSG7ybs%3D&reserved=0>
>>>>>> .RemoteObject;
>>>>>>             import org.apache.royale.net.events.FaultEvent;
>>>>>>             import org.apache.royale.net.events.ResultEvent;
>>>>>>
>>>>>>             privatefunctionapplicationCompleteHandler(evt:Event):void
>>>>>> {
>>>>>>                 testLabel.text = "Requesting from AMF";
>>>>>>                 service.send("getPackages", null);
>>>>>>             }
>>>>>>
>>>>>>             privatefunctionamfFaultHandler(evt:FaultEvent):void{
>>>>>>                 testLabel.text = "Fault in calling AMF";
>>>>>>             }
>>>>>>
>>>>>>             privatefunctionamfResultHandler(evt:ResultEvent):void{
>>>>>>                 testLabel.text = "Result received from AMF";
>>>>>>             }
>>>>>>         ]]>
>>>>>>     </fx:Script>
>>>>>>
>>>>>> <js:valuesImpl>
>>>>>> <js:SimpleCSSValuesImpl />
>>>>>> </js:valuesImpl>
>>>>>>
>>>>>>    <js:beads>
>>>>>> <js:ClassAliasBead />
>>>>>> <js:RemoteObjectid="service"result="amfResultHandler(event)"fault=
>>>>>> "amfFaultHandler(event)"
>>>>>> endPoint = "https://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=mARoGAlKZYBWmNOBwqTpTRYkqG%2Fk0cvrHwR5kgbfNFY%3D&reserved=0>
>>>>>> "
>>>>>> destination = "Meta"
>>>>>> source = "Meta"/>
>>>>>> </js:beads>
>>>>>>
>>>>>> <js:initialView>
>>>>>> <js:View>
>>>>>> <js:Labelid="testLabel" />
>>>>>> </js:View>
>>>>>> </js:initialView>
>>>>>> </js:Application>
>>>>>>
>>>>>>
>>>>>> It is not working and showing the following error in the browser:
>>>>>>
>>>>>> Failed to load https://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=mARoGAlKZYBWmNOBwqTpTRYkqG%2Fk0cvrHwR5kgbfNFY%3D&reserved=0>:
>>>>>> Response to preflight request doesn't pass access control check: No
>>>>>> 'Access-Control-Allow-Origin' header is present on the requested resource.
>>>>>> Origin 'http://localhost' is therefore not allowed access.
>>>>>> Language.js:238destination fault handler
>>>>>>
>>>>>>    1. {code: -1004, message: "Invalid response type.", detail: "Invalid
>>>>>>    XMLHttpRequest response status or type.", data: null}
>>>>>>       1. code:-1004
>>>>>>       2. data:null
>>>>>>       3. detail:"Invalid XMLHttpRequest response status or type."
>>>>>>       4. message:"Invalid response type."
>>>>>>       5. __proto__:Object
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> It is able to compile and run regardless of the errors in compile log:
>>>>>>
>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>> println
>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>> he/royale/reflection/AccessorDefinition.js:12: ERROR - required
>>>>>> "org.apache.royale.reflection.TypeDefinition" namespace not provided
>>>>>> yet
>>>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>
>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>> println
>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>> he/royale/reflection/AccessorDefinition.js:13: ERROR - required
>>>>>> "org.apache.royale.reflection.VariableDefinition" namespace not
>>>>>> provided yet
>>>>>> goog.require('org.apache.royale.reflection.VariableDefinition');
>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>
>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>> println
>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>> he/royale/reflection/MethodDefinition.js:14: ERROR - required
>>>>>> "org.apache.royale.reflection.TypeDefinition" namespace not provided
>>>>>> yet
>>>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>
>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>> println
>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>> he/royale/reflection/ParameterDefinition.js:13: ERROR- required
>>>>>> "org.apache.royale.reflection.TypeDefinition" namespace not provided
>>>>>> yet
>>>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>
>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>> println
>>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>>> he/royale/reflection/TypeDefinition.js:15: ERROR - required
>>>>>> "org.apache.royale.reflection.VariableDefinition" namespace not
>>>>>> provided yet
>>>>>> goog.require('org.apache.royale.reflection.VariableDefinition');
>>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>>
>>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>>> printSummary
>>>>>> WARNING: 5 error(s), 0 warning(s)
>>>>>> The project 'HelloRoyale' has been successfully compiled and
>>>>>> optimized.
>>>>>> 4.566387 seconds
>>>>>>
>>>>>>
>>>>>> On Mon, Jan 15, 2018 at 7:38 PM, Piotr Zarzycki <
>>>>>> piotrzarzycki21@gmail.com> wrote:
>>>>>>
>>>>>>> Carlos,
>>>>>>>
>>>>>>> No problem. I have also couple of huge things related to Royale to
>>>>>>> do before my hand gets dirty with AMF! :) Unless someone urgently will
>>>>>>> needed. :)
>>>>>>>
>>>>>>> Thanks, Piotr
>>>>>>>
>>>>>>> 2018-01-15 19:27 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>>>>>>>
>>>>>>>> Hi Piotr,
>>>>>>>> I'll put this on my to do list, but have to do some things first.
>>>>>>>> thanks
>>>>>>>>
>>>>>>>> 2018-01-15 9:26 GMT+01:00 Piotr Zarzycki <piotrzarzycki21@gmail.com
>>>>>>>> >:
>>>>>>>>
>>>>>>>>> Hi Carlos,
>>>>>>>>>
>>>>>>>>> Can you describe more how to setup those examples ? Could you add
>>>>>>>>> to RemoteObjectAMFTest README.md file where you describe steps. I would
>>>>>>>>> like to have AMF on my list for tests and improvements. Whenever I look
>>>>>>>>> into that I don't know how to proceed with it.
>>>>>>>>>
>>>>>>>>> Thanks, Piotr
>>>>>>>>>
>>>>>>>>> 2018-01-15 9:21 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>>>>>>>>>
>>>>>>>>>> Hi,
>>>>>>>>>>
>>>>>>>>>> there's an example that we get it working nicely at:
>>>>>>>>>>
>>>>>>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/
>>>>>>>>>> royale/RemoteObjectAMFTest
>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Ftree%2Fdevelop%2Fexamples%2Froyale%2FRemoteObjectAMFTest&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7kdc48rEQiaI4Qp%2BBdfBcGPxddZIYrTUXrQ%2BN2u4tto%3D&reserved=0>
>>>>>>>>>>
>>>>>>>>>> you can use that as a starting point for your test
>>>>>>>>>>
>>>>>>>>>> As well a java web app that is used along that royale client
>>>>>>>>>> example is at:
>>>>>>>>>>
>>>>>>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/amf
>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Ftree%2Fdevelop%2Fexamples%2Famf&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=PW4DYIeW4PetVe6BdFYjxFeAjCrqofPYtdbRTnJ4xjk%3D&reserved=0>
>>>>>>>>>>
>>>>>>>>>> thanks
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> 2018-01-15 3:56 GMT+01:00 Carlos Cruz <ca...@nbtbizcapital.com>:
>>>>>>>>>>
>>>>>>>>>>> I have a lot of experience with Flex remoting and BlazeDS with
>>>>>>>>>>> Java, but with FlexJS and Royale I have none, but extrapolating from some
>>>>>>>>>>> JS tests I've done with AMF at this line: amfTestService.send(
>>>>>>>>>>> "getShippingMethods", []); you have to call a class in
>>>>>>>>>>> gateway.php and a method. Your request needs at least 3 properties.
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> I'm also assuming your JS file and gateway.php are in the same
>>>>>>>>>>> domain and same port (this gave me problems).
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Take what I said regarding my experience with FlexJS and Royale
>>>>>>>>>>> into account.
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Carlos
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> *From:* Fréderic Cox [mailto:coxfrederic@gmail.com]
>>>>>>>>>>> *Sent:* Sunday, January 14, 2018 4:01 PM
>>>>>>>>>>>
>>>>>>>>>>> *To:* users@royale.apache.org
>>>>>>>>>>> *Subject:* Re: RemoteObject
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Script tag was stripped from the post:
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> import org.apache.royale.events.MouseEvent;
>>>>>>>>>>>
>>>>>>>>>>>                      import org.apache.royale.net.events.F
>>>>>>>>>>> aultEvent;
>>>>>>>>>>>
>>>>>>>>>>>                      import org.apache.royale.net.events.R
>>>>>>>>>>> esultEvent;
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>                      protectedfunction
>>>>>>>>>>> textbutton_clickHandler(event:org.apache.royale.events.Mouse
>>>>>>>>>>> Event):void
>>>>>>>>>>>
>>>>>>>>>>>                      {
>>>>>>>>>>>
>>>>>>>>>>>                            statusLabel.text = "calling.......";
>>>>>>>>>>>
>>>>>>>>>>>                            amfTestService.addEventListener(
>>>>>>>>>>> "fault", amfTestService_faultHandler);
>>>>>>>>>>>
>>>>>>>>>>>                            amfTestService.addEventListener(
>>>>>>>>>>> "result", amfTestService_resultHandler);
>>>>>>>>>>>
>>>>>>>>>>>                            amfTestService.send("getShippi
>>>>>>>>>>> ngMethods", []);
>>>>>>>>>>>
>>>>>>>>>>>                      }
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>                      protectedfunction
>>>>>>>>>>> amfTestService_faultHandler(event:FaultEvent):void
>>>>>>>>>>>
>>>>>>>>>>>                      {
>>>>>>>>>>>
>>>>>>>>>>>                            statusLabel.text = "error!";
>>>>>>>>>>>
>>>>>>>>>>>                      }
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>                      protectedfunction
>>>>>>>>>>> amfTestService_resultHandler(event:ResultEvent):void
>>>>>>>>>>>
>>>>>>>>>>>                      {
>>>>>>>>>>>
>>>>>>>>>>>                            statusLabel.text = "result!";
>>>>>>>>>>>
>>>>>>>>>>>                      }
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> none of the events are triggered ..URL is
>>>>>>>>>>> http://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=EJDBQBL83yBhDn%2BWWgCCVyw0N3tnakhZ7UdEt4JFNaY%3D&reserved=0>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> On Fri, Jan 12, 2018 at 4:55 AM, Carlos Cruz <
>>>>>>>>>>> carlos@nbtbizcapital.com> wrote:
>>>>>>>>>>>
>>>>>>>>>>> I may be blind (and or ignorant as I'm more familiar with Flex)
>>>>>>>>>>> but where
>>>>>>>>>>> are you sending an AMF request? I don't see any code that sends
>>>>>>>>>>> a request to
>>>>>>>>>>> a service and invokes method.
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> -----Original Message-----
>>>>>>>>>>> From: coxfrederic [mailto:coxfrederic@gmail.com]
>>>>>>>>>>> Sent: Thursday, January 11, 2018 9:09 PM
>>>>>>>>>>> To: users@royale.apache.org
>>>>>>>>>>> Subject: Re: RemoteObject
>>>>>>>>>>>
>>>>>>>>>>> <?xml version="1.0" encoding="utf-8"?>
>>>>>>>>>>>
>>>>>>>>>>> <js:Application xmlns:fx="http://ns.adobe.com/mxml/2009
>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.adobe.com%2Fmxml%2F2009&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7cSxKCospCIpbkKY4F%2Fp5lsHBH%2BPFp5Vny2ftXWmL5A%3D&reserved=0>
>>>>>>>>>>> "
>>>>>>>>>>>                    xmlns:js="library://ns.apache
>>>>>>>>>>> .org/royale/basic
>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.apache.org%2Froyale%2Fbasic&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=D%2FBslvPtV9pNNjpoS4KCQlYHB8ArUYEIXCXuAVoNgYM%3D&reserved=0>"
>>>>>>>>>>> >
>>>>>>>>>>>         <fx:Script>
>>>>>>>>>>>
>>>>>>>>>>>         </fx:Script>
>>>>>>>>>>>     <js:valuesImpl>
>>>>>>>>>>>         <js:SimpleCSSValuesImpl />
>>>>>>>>>>>     </js:valuesImpl>
>>>>>>>>>>>
>>>>>>>>>>>         <js:beads>
>>>>>>>>>>>                 <js:ClassAliasBead />
>>>>>>>>>>>                 <js:RemoteObject id="amfTestService"
>>>>>>>>>>>
>>>>>>>>>>> endPoint="http://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=EJDBQBL83yBhDn%2BWWgCCVyw0N3tnakhZ7UdEt4JFNaY%3D&reserved=0>
>>>>>>>>>>> "
>>>>>>>>>>>
>>>>>>>>>>>  destination="Meta"
>>>>>>>>>>> source="Meta" />
>>>>>>>>>>>         </js:beads>
>>>>>>>>>>>
>>>>>>>>>>>     <js:initialView>
>>>>>>>>>>>         <js:View>
>>>>>>>>>>>                         <js:VGroup>
>>>>>>>>>>>                                 <js:Label id="statusLabel"
>>>>>>>>>>> text="Hello
>>>>>>>>>>> World!" />
>>>>>>>>>>>                                 <js:TextButton text="Get AMF
>>>>>>>>>>> data"
>>>>>>>>>>> click="textbutton_clickHandler(event)" />
>>>>>>>>>>>                         </js:VGroup>
>>>>>>>>>>>         </js:View>
>>>>>>>>>>>     </js:initialView>
>>>>>>>>>>> </js:Application>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Any idea why I'm not getting a fault nor success event on this?
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> --
>>>>>>>>>>> Sent from: http://apache-royale-users.20374.n8.nabble.com/
>>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fapache-royale-users.20374.n8.nabble.com%2F&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=xvY8nK1QKlWduh6p5x8y19jm%2Br60PSFVlNdi6TRsPmw%3D&reserved=0>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> --
>>>>>>>>>> Carlos Rovira
>>>>>>>>>> http://about.me/carlosrovira
>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fabout.me%2Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=55MSUXBM2zE5U0csgV1harcuXvKyZ2gd%2BO%2FmD7hjJ50%3D&reserved=0>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>>
>>>>>>>>> Piotr Zarzycki
>>>>>>>>>
>>>>>>>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=NG2rkkxhfc7MTSVRqHzEmHL8HuUpvXI72B9nkW2QfdU%3D&reserved=0>*
>>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> --
>>>>>>>>
>>>>>>> ...

Re: RemoteObject

Posted by Piotr Zarzycki <pi...@gmail.com>.
Frederic,

Could you share some hello world implementation of AMFPHP along with Hello
World app in Flex ? I may also look into that and compare the results. Just
don't want to waste time on setup things to prepare AMFPHP stuff. Do you
have such things ?

Thanks, Piotr


2018-02-16 15:57 GMT+01:00 Fréderic Cox <co...@gmail.com>:

> Hi Carlos,
>
> Sure I’ll see what I can do. Feel I have lots to leatn about Royale and
> AMF (it just works with Flash/AIR so not up to date about the inner
> workings).
>
> I’ll try to test the examples over the weekend. Do you think the AMFPHP
> version could be an issue or is it assumed to work in Royale if it works in
> Flex?
>
> Verstuurd vanaf mijn iPhone
>
> Op 16 feb. 2018 om 12:28 heeft Carlos Rovira <ca...@apache.org>
> het volgende geschreven:
>
> Hi Frederic,
> thanks for filling this and take a look into AMF!
> Hope you could help us a bit with this.
>
> 2018-02-16 0:21 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>
>> Hi Alex,
>>
>> I created https://github.com/apache/royale-asjs/issues/119, hope that is
>> in the correct place and with more readable mark-up.
>>
>> Regards,
>>
>> Fréderic
>>
>> On Thu, Feb 15, 2018 at 8:57 PM, Alex Harui <ah...@adobe.com> wrote:
>>
>>> Hi Frederic,
>>>
>>> Where is this output you posted coming from, a network monitor?  It was
>>> too hard to read, so please create a bug report on GitHub and post it there.
>>>
>>> You might be able to use a network monitor to compare what Flex sent vs
>>> what Royale is sending.  What does your Flex usage of RemoteObject look
>>> like?
>>>
>>> HTH,
>>> -Alex
>>>
>>> From: Fréderic Cox <co...@gmail.com>
>>> Reply-To: "users@royale.apache.org" <us...@royale.apache.org>
>>> Date: Thursday, February 15, 2018 at 5:09 AM
>>> To: "users@royale.apache.org" <us...@royale.apache.org>
>>> Subject: Re: RemoteObject
>>>
>>> Hi Piotr,
>>>
>>> Thanks, I installed the extension and now I'm not getting the CORS error
>>> anymore.
>>> I'm not getting any fault or result event triggered either....
>>>
>>> The endPoint set is
>>> https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php
>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fclients.cityfashion.dev.exuvis.com%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=67VMfKVGZo%2BarMstlt%2BZbX5OdTomYDQNSgM07ycK%2Bvc%3D&reserved=0>
>>>
>>> This is correct, right? (I use this endpoint in Flex and that works fine)
>>>
>>>
>>>    1. Request URL:
>>>       https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php
>>>       <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fclients.cityfashion.dev.exuvis.com%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=67VMfKVGZo%2BarMstlt%2BZbX5OdTomYDQNSgM07ycK%2Bvc%3D&reserved=0>
>>>       2. Request Method:
>>>       OPTIONS
>>>       3. Status Code:
>>>       200 OK
>>>       4. Remote Address:
>>>       188.93.153.101:443
>>>       <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2F188.93.153.101%3A443&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=UWqG%2BqQTcL1fTnck9i5BPXmrn3ZlgRf8XCPpQ8EcJrE%3D&reserved=0>
>>>       5. Referrer Policy:
>>>       no-referrer-when-downgrade
>>>       1. Response Headersview source
>>>       1. Connection:
>>>       keep-alive
>>>       2. Content-Encoding:
>>>       gzip
>>>       3. Content-Length:
>>>       286
>>>       4. Content-Type:
>>>       text/html; charset=UTF-8
>>>       5. Date:
>>>       Thu, 15 Feb 2018 13:08:17 GMT
>>>       6. Server:
>>>       nginx
>>>       7. Vary:
>>>       Accept-Encoding
>>>       2. Request Headersview source
>>>       1. Accept:
>>>       */*
>>>       2. Accept-Encoding:
>>>       gzip, deflate, br
>>>       3. Accept-Language:
>>>       en-GB,en-US;q=0.9,en;q=0.8
>>>       4. Access-Control-Request-Headers:
>>>       content-type
>>>       5. Access-Control-Request-Method:
>>>       POST
>>>       6. Connection:
>>>       keep-alive
>>>       7. Host:
>>>       clients.cityfashion.dev.exuvis.com
>>>       <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fclients.cityfashion.dev.exuvis.com&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=%2BiTohXW1uaTpydtAlGWa0leTvEQKK2Wg6XtN%2FqQ73%2F0%3D&reserved=0>
>>>       8. Origin:
>>>       null
>>>       9. User-Agent:
>>>       Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_3)
>>>       AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.167 Safari/537.36
>>>
>>> Response is:
>>>
>>> <p>amfphp and this gateway are installed correctly. You may now connect
>>> to this gateway from Flash.</p><p>Note: If you're reading an old tutorial,
>>> it will tell you that you should see a download window instead of this
>>> message. This confused people so this is the new behaviour starting from
>>> amfphp 1.2.</p><p><a href='http://www.amfphp.org/docs
>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.amfphp.org%2Fdocs&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=%2FGtfS6iuQCrcoifQ5pUOXPJ0JJZcOQaMyYsscjKzA9I%3D&reserved=0>'>View
>>> the amfphp documentation</p><p><a href='browser'>Load the service
>>> browser</a></p><pre>
>>>
>>> Should I target a specific file with the JS version? Should the endPoint
>>> be different?
>>>
>>> On Thu, Feb 15, 2018 at 12:07 PM, Piotr Zarzycki <
>>> piotrzarzycki21@gmail.com> wrote:
>>>
>>>> Frederic,
>>>>
>>>> It looks like it is not problem with framework, but rather CORS issue.
>>>> Maybe try to install this plugin [1] and add to the list your url.
>>>>
>>>> [1] https://chrome.google.com/webstore/detail/allow-control-
>>>> allow-origi/nlfbmbojpeacfghkpbjhddihlkkiljbi?hl=en
>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fchrome.google.com%2Fwebstore%2Fdetail%2Fallow-control-allow-origi%2Fnlfbmbojpeacfghkpbjhddihlkkiljbi%3Fhl%3Den&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=CbZH3KQcH0oGU%2FbnBtyVp%2B9zeqDEUcK9Y6UFd0BIESM%3D&reserved=0>
>>>>
>>>> Piotr
>>>>
>>>> 2018-02-15 12:04 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>>>>
>>>>> For me it is still not working in latest release 0.9.1. I based my
>>>>> example on the example in the SDK.
>>>>>
>>>>> <?xml version="1.0" encoding="utf-8"?>
>>>>> <js:Applicationxmlns:fx="http://ns.adobe.com/mxml/2009
>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.adobe.com%2Fmxml%2F2009&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7cSxKCospCIpbkKY4F%2Fp5lsHBH%2BPFp5Vny2ftXWmL5A%3D&reserved=0>
>>>>> "
>>>>> xmlns:js="library://ns.apache.org/royale/basic
>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.apache.org%2Froyale%2Fbasic&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=D%2FBslvPtV9pNNjpoS4KCQlYHB8ArUYEIXCXuAVoNgYM%3D&reserved=0>
>>>>> "applicationComplete="applicationCompleteHandler(event);">
>>>>>
>>>>>     <fx:Script>
>>>>>         <![CDATA[
>>>>>             import org.apache.royale.net
>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Forg.apache.royale.net&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=ATrXbo2PLqz1dNeyvxVu89zy3yaKPxwIwQm9tSG7ybs%3D&reserved=0>
>>>>> .RemoteObject;
>>>>>             import org.apache.royale.net.events.FaultEvent;
>>>>>             import org.apache.royale.net.events.ResultEvent;
>>>>>
>>>>>             privatefunctionapplicationCompleteHandler(evt:Event):void{
>>>>>                 testLabel.text = "Requesting from AMF";
>>>>>                 service.send("getPackages", null);
>>>>>             }
>>>>>
>>>>>             privatefunctionamfFaultHandler(evt:FaultEvent):void{
>>>>>                 testLabel.text = "Fault in calling AMF";
>>>>>             }
>>>>>
>>>>>             privatefunctionamfResultHandler(evt:ResultEvent):void{
>>>>>                 testLabel.text = "Result received from AMF";
>>>>>             }
>>>>>         ]]>
>>>>>     </fx:Script>
>>>>>
>>>>> <js:valuesImpl>
>>>>> <js:SimpleCSSValuesImpl />
>>>>> </js:valuesImpl>
>>>>>
>>>>>    <js:beads>
>>>>> <js:ClassAliasBead />
>>>>> <js:RemoteObjectid="service"result="amfResultHandler(event)"fault=
>>>>> "amfFaultHandler(event)"
>>>>> endPoint = "https://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=mARoGAlKZYBWmNOBwqTpTRYkqG%2Fk0cvrHwR5kgbfNFY%3D&reserved=0>
>>>>> "
>>>>> destination = "Meta"
>>>>> source = "Meta"/>
>>>>> </js:beads>
>>>>>
>>>>> <js:initialView>
>>>>> <js:View>
>>>>> <js:Labelid="testLabel" />
>>>>> </js:View>
>>>>> </js:initialView>
>>>>> </js:Application>
>>>>>
>>>>>
>>>>> It is not working and showing the following error in the browser:
>>>>>
>>>>> Failed to load https://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=mARoGAlKZYBWmNOBwqTpTRYkqG%2Fk0cvrHwR5kgbfNFY%3D&reserved=0>:
>>>>> Response to preflight request doesn't pass access control check: No
>>>>> 'Access-Control-Allow-Origin' header is present on the requested resource.
>>>>> Origin 'http://localhost' is therefore not allowed access.
>>>>> Language.js:238destination fault handler
>>>>>
>>>>>    1. {code: -1004, message: "Invalid response type.", detail: "Invalid
>>>>>    XMLHttpRequest response status or type.", data: null}
>>>>>       1. code:-1004
>>>>>       2. data:null
>>>>>       3. detail:"Invalid XMLHttpRequest response status or type."
>>>>>       4. message:"Invalid response type."
>>>>>       5. __proto__:Object
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> It is able to compile and run regardless of the errors in compile log:
>>>>>
>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>> println
>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>> he/royale/reflection/AccessorDefinition.js:12: ERROR - required
>>>>> "org.apache.royale.reflection.TypeDefinition" namespace not provided
>>>>> yet
>>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>
>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>> println
>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>> he/royale/reflection/AccessorDefinition.js:13: ERROR - required
>>>>> "org.apache.royale.reflection.VariableDefinition" namespace not
>>>>> provided yet
>>>>> goog.require('org.apache.royale.reflection.VariableDefinition');
>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>
>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>> println
>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>> he/royale/reflection/MethodDefinition.js:14: ERROR - required
>>>>> "org.apache.royale.reflection.TypeDefinition" namespace not provided
>>>>> yet
>>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>
>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>> println
>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>> he/royale/reflection/ParameterDefinition.js:13: ERROR- required
>>>>> "org.apache.royale.reflection.TypeDefinition" namespace not provided
>>>>> yet
>>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>
>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>> println
>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>> he/royale/reflection/TypeDefinition.js:15: ERROR - required
>>>>> "org.apache.royale.reflection.VariableDefinition" namespace not
>>>>> provided yet
>>>>> goog.require('org.apache.royale.reflection.VariableDefinition');
>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>
>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>> printSummary
>>>>> WARNING: 5 error(s), 0 warning(s)
>>>>> The project 'HelloRoyale' has been successfully compiled and optimized.
>>>>> 4.566387 seconds
>>>>>
>>>>>
>>>>> On Mon, Jan 15, 2018 at 7:38 PM, Piotr Zarzycki <
>>>>> piotrzarzycki21@gmail.com> wrote:
>>>>>
>>>>>> Carlos,
>>>>>>
>>>>>> No problem. I have also couple of huge things related to Royale to do
>>>>>> before my hand gets dirty with AMF! :) Unless someone urgently will needed.
>>>>>> :)
>>>>>>
>>>>>> Thanks, Piotr
>>>>>>
>>>>>> 2018-01-15 19:27 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>>>>>>
>>>>>>> Hi Piotr,
>>>>>>> I'll put this on my to do list, but have to do some things first.
>>>>>>> thanks
>>>>>>>
>>>>>>> 2018-01-15 9:26 GMT+01:00 Piotr Zarzycki <pi...@gmail.com>
>>>>>>> :
>>>>>>>
>>>>>>>> Hi Carlos,
>>>>>>>>
>>>>>>>> Can you describe more how to setup those examples ? Could you add
>>>>>>>> to RemoteObjectAMFTest README.md file where you describe steps. I would
>>>>>>>> like to have AMF on my list for tests and improvements. Whenever I look
>>>>>>>> into that I don't know how to proceed with it.
>>>>>>>>
>>>>>>>> Thanks, Piotr
>>>>>>>>
>>>>>>>> 2018-01-15 9:21 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>>>>>>>>
>>>>>>>>> Hi,
>>>>>>>>>
>>>>>>>>> there's an example that we get it working nicely at:
>>>>>>>>>
>>>>>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/
>>>>>>>>> royale/RemoteObjectAMFTest
>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Ftree%2Fdevelop%2Fexamples%2Froyale%2FRemoteObjectAMFTest&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7kdc48rEQiaI4Qp%2BBdfBcGPxddZIYrTUXrQ%2BN2u4tto%3D&reserved=0>
>>>>>>>>>
>>>>>>>>> you can use that as a starting point for your test
>>>>>>>>>
>>>>>>>>> As well a java web app that is used along that royale client
>>>>>>>>> example is at:
>>>>>>>>>
>>>>>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/amf
>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Ftree%2Fdevelop%2Fexamples%2Famf&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=PW4DYIeW4PetVe6BdFYjxFeAjCrqofPYtdbRTnJ4xjk%3D&reserved=0>
>>>>>>>>>
>>>>>>>>> thanks
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> 2018-01-15 3:56 GMT+01:00 Carlos Cruz <ca...@nbtbizcapital.com>:
>>>>>>>>>
>>>>>>>>>> I have a lot of experience with Flex remoting and BlazeDS with
>>>>>>>>>> Java, but with FlexJS and Royale I have none, but extrapolating from some
>>>>>>>>>> JS tests I've done with AMF at this line: amfTestService.send(
>>>>>>>>>> "getShippingMethods", []); you have to call a class in
>>>>>>>>>> gateway.php and a method. Your request needs at least 3 properties.
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> I'm also assuming your JS file and gateway.php are in the same
>>>>>>>>>> domain and same port (this gave me problems).
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Take what I said regarding my experience with FlexJS and Royale
>>>>>>>>>> into account.
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Carlos
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> *From:* Fréderic Cox [mailto:coxfrederic@gmail.com]
>>>>>>>>>> *Sent:* Sunday, January 14, 2018 4:01 PM
>>>>>>>>>>
>>>>>>>>>> *To:* users@royale.apache.org
>>>>>>>>>> *Subject:* Re: RemoteObject
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Script tag was stripped from the post:
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> import org.apache.royale.events.MouseEvent;
>>>>>>>>>>
>>>>>>>>>>                      import org.apache.royale.net.events.F
>>>>>>>>>> aultEvent;
>>>>>>>>>>
>>>>>>>>>>                      import org.apache.royale.net.events.R
>>>>>>>>>> esultEvent;
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>                      protectedfunction
>>>>>>>>>> textbutton_clickHandler(event:org.apache.royale.events.Mouse
>>>>>>>>>> Event):void
>>>>>>>>>>
>>>>>>>>>>                      {
>>>>>>>>>>
>>>>>>>>>>                            statusLabel.text = "calling.......";
>>>>>>>>>>
>>>>>>>>>>                            amfTestService.addEventListener(
>>>>>>>>>> "fault", amfTestService_faultHandler);
>>>>>>>>>>
>>>>>>>>>>                            amfTestService.addEventListener(
>>>>>>>>>> "result", amfTestService_resultHandler);
>>>>>>>>>>
>>>>>>>>>>                            amfTestService.send("getShippi
>>>>>>>>>> ngMethods", []);
>>>>>>>>>>
>>>>>>>>>>                      }
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>                      protectedfunction
>>>>>>>>>> amfTestService_faultHandler(event:FaultEvent):void
>>>>>>>>>>
>>>>>>>>>>                      {
>>>>>>>>>>
>>>>>>>>>>                            statusLabel.text = "error!";
>>>>>>>>>>
>>>>>>>>>>                      }
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>                      protectedfunction
>>>>>>>>>> amfTestService_resultHandler(event:ResultEvent):void
>>>>>>>>>>
>>>>>>>>>>                      {
>>>>>>>>>>
>>>>>>>>>>                            statusLabel.text = "result!";
>>>>>>>>>>
>>>>>>>>>>                      }
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> none of the events are triggered ..URL is
>>>>>>>>>> http://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=EJDBQBL83yBhDn%2BWWgCCVyw0N3tnakhZ7UdEt4JFNaY%3D&reserved=0>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> On Fri, Jan 12, 2018 at 4:55 AM, Carlos Cruz <
>>>>>>>>>> carlos@nbtbizcapital.com> wrote:
>>>>>>>>>>
>>>>>>>>>> I may be blind (and or ignorant as I'm more familiar with Flex)
>>>>>>>>>> but where
>>>>>>>>>> are you sending an AMF request? I don't see any code that sends a
>>>>>>>>>> request to
>>>>>>>>>> a service and invokes method.
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> -----Original Message-----
>>>>>>>>>> From: coxfrederic [mailto:coxfrederic@gmail.com]
>>>>>>>>>> Sent: Thursday, January 11, 2018 9:09 PM
>>>>>>>>>> To: users@royale.apache.org
>>>>>>>>>> Subject: Re: RemoteObject
>>>>>>>>>>
>>>>>>>>>> <?xml version="1.0" encoding="utf-8"?>
>>>>>>>>>>
>>>>>>>>>> <js:Application xmlns:fx="http://ns.adobe.com/mxml/2009
>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.adobe.com%2Fmxml%2F2009&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7cSxKCospCIpbkKY4F%2Fp5lsHBH%2BPFp5Vny2ftXWmL5A%3D&reserved=0>
>>>>>>>>>> "
>>>>>>>>>>                    xmlns:js="library://ns.apache.org/royale/basic
>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.apache.org%2Froyale%2Fbasic&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=D%2FBslvPtV9pNNjpoS4KCQlYHB8ArUYEIXCXuAVoNgYM%3D&reserved=0>"
>>>>>>>>>> >
>>>>>>>>>>         <fx:Script>
>>>>>>>>>>
>>>>>>>>>>         </fx:Script>
>>>>>>>>>>     <js:valuesImpl>
>>>>>>>>>>         <js:SimpleCSSValuesImpl />
>>>>>>>>>>     </js:valuesImpl>
>>>>>>>>>>
>>>>>>>>>>         <js:beads>
>>>>>>>>>>                 <js:ClassAliasBead />
>>>>>>>>>>                 <js:RemoteObject id="amfTestService"
>>>>>>>>>>
>>>>>>>>>> endPoint="http://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=EJDBQBL83yBhDn%2BWWgCCVyw0N3tnakhZ7UdEt4JFNaY%3D&reserved=0>
>>>>>>>>>> "
>>>>>>>>>>
>>>>>>>>>>  destination="Meta"
>>>>>>>>>> source="Meta" />
>>>>>>>>>>         </js:beads>
>>>>>>>>>>
>>>>>>>>>>     <js:initialView>
>>>>>>>>>>         <js:View>
>>>>>>>>>>                         <js:VGroup>
>>>>>>>>>>                                 <js:Label id="statusLabel"
>>>>>>>>>> text="Hello
>>>>>>>>>> World!" />
>>>>>>>>>>                                 <js:TextButton text="Get AMF data"
>>>>>>>>>> click="textbutton_clickHandler(event)" />
>>>>>>>>>>                         </js:VGroup>
>>>>>>>>>>         </js:View>
>>>>>>>>>>     </js:initialView>
>>>>>>>>>> </js:Application>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Any idea why I'm not getting a fault nor success event on this?
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> --
>>>>>>>>>> Sent from: http://apache-royale-users.20374.n8.nabble.com/
>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fapache-royale-users.20374.n8.nabble.com%2F&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=xvY8nK1QKlWduh6p5x8y19jm%2Br60PSFVlNdi6TRsPmw%3D&reserved=0>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> Carlos Rovira
>>>>>>>>> http://about.me/carlosrovira
>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fabout.me%2Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=55MSUXBM2zE5U0csgV1harcuXvKyZ2gd%2BO%2FmD7hjJ50%3D&reserved=0>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> --
>>>>>>>>
>>>>>>>> Piotr Zarzycki
>>>>>>>>
>>>>>>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=NG2rkkxhfc7MTSVRqHzEmHL8HuUpvXI72B9nkW2QfdU%3D&reserved=0>*
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> Carlos Rovira
>>>>>>> http://about.me/carlosrovira
>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fabout.me%2Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=55MSUXBM2zE5U0csgV1harcuXvKyZ2gd%2BO%2FmD7hjJ50%3D&reserved=0>
>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>>
>>>>>> Piotr Zarzycki
>>>>>>
>>>>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=NG2rkkxhfc7MTSVRqHzEmHL8HuUpvXI72B9nkW2QfdU%3D&reserved=0>*
>>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>>
>>>> Piotr Zarzycki
>>>>
>>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=NG2rkkxhfc7MTSVRqHzEmHL8HuUpvXI72B9nkW2QfdU%3D&reserved=0>*
>>>>
>>>
>>>
>>
>
>
> --
> Carlos Rovira
> http://about.me/carlosrovira
>
>


-- 

Piotr Zarzycki

Patreon: *https://www.patreon.com/piotrzarzycki
<https://www.patreon.com/piotrzarzycki>*

Re: RemoteObject

Posted by Carlos Rovira <ca...@apache.org>.
Hi Frederic,
as I stated before, it should work flawlessly since all implementations in
different backends should end doing the same.
If not, that means we can find different scenarios and that other AMF
client code knows how to manage it. For that reason I propose you to start
from our java-royal example (there's a java project example and a royale
project example that works together). If that works ok for you, and was not
broken for something we did in the last months, then I'll try to substitute
java backed by AMFPHP backend and see if that works, and from there you can
evolve.

let me know what do you think about this strategy

thanks Frederic! :)



2018-02-16 15:57 GMT+01:00 Fréderic Cox <co...@gmail.com>:

> Hi Carlos,
>
> Sure I’ll see what I can do. Feel I have lots to leatn about Royale and
> AMF (it just works with Flash/AIR so not up to date about the inner
> workings).
>
> I’ll try to test the examples over the weekend. Do you think the AMFPHP
> version could be an issue or is it assumed to work in Royale if it works in
> Flex?
>
> Verstuurd vanaf mijn iPhone
>
> Op 16 feb. 2018 om 12:28 heeft Carlos Rovira <ca...@apache.org>
> het volgende geschreven:
>
> Hi Frederic,
> thanks for filling this and take a look into AMF!
> Hope you could help us a bit with this.
>
> 2018-02-16 0:21 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>
>> Hi Alex,
>>
>> I created https://github.com/apache/royale-asjs/issues/119, hope that is
>> in the correct place and with more readable mark-up.
>>
>> Regards,
>>
>> Fréderic
>>
>> On Thu, Feb 15, 2018 at 8:57 PM, Alex Harui <ah...@adobe.com> wrote:
>>
>>> Hi Frederic,
>>>
>>> Where is this output you posted coming from, a network monitor?  It was
>>> too hard to read, so please create a bug report on GitHub and post it there.
>>>
>>> You might be able to use a network monitor to compare what Flex sent vs
>>> what Royale is sending.  What does your Flex usage of RemoteObject look
>>> like?
>>>
>>> HTH,
>>> -Alex
>>>
>>> From: Fréderic Cox <co...@gmail.com>
>>> Reply-To: "users@royale.apache.org" <us...@royale.apache.org>
>>> Date: Thursday, February 15, 2018 at 5:09 AM
>>> To: "users@royale.apache.org" <us...@royale.apache.org>
>>> Subject: Re: RemoteObject
>>>
>>> Hi Piotr,
>>>
>>> Thanks, I installed the extension and now I'm not getting the CORS error
>>> anymore.
>>> I'm not getting any fault or result event triggered either....
>>>
>>> The endPoint set is
>>> https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php
>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fclients.cityfashion.dev.exuvis.com%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=67VMfKVGZo%2BarMstlt%2BZbX5OdTomYDQNSgM07ycK%2Bvc%3D&reserved=0>
>>>
>>> This is correct, right? (I use this endpoint in Flex and that works fine)
>>>
>>>
>>>    1. Request URL:
>>>       https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php
>>>       <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fclients.cityfashion.dev.exuvis.com%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=67VMfKVGZo%2BarMstlt%2BZbX5OdTomYDQNSgM07ycK%2Bvc%3D&reserved=0>
>>>       2. Request Method:
>>>       OPTIONS
>>>       3. Status Code:
>>>       200 OK
>>>       4. Remote Address:
>>>       188.93.153.101:443
>>>       <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2F188.93.153.101%3A443&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=UWqG%2BqQTcL1fTnck9i5BPXmrn3ZlgRf8XCPpQ8EcJrE%3D&reserved=0>
>>>       5. Referrer Policy:
>>>       no-referrer-when-downgrade
>>>       1. Response Headersview source
>>>       1. Connection:
>>>       keep-alive
>>>       2. Content-Encoding:
>>>       gzip
>>>       3. Content-Length:
>>>       286
>>>       4. Content-Type:
>>>       text/html; charset=UTF-8
>>>       5. Date:
>>>       Thu, 15 Feb 2018 13:08:17 GMT
>>>       6. Server:
>>>       nginx
>>>       7. Vary:
>>>       Accept-Encoding
>>>       2. Request Headersview source
>>>       1. Accept:
>>>       */*
>>>       2. Accept-Encoding:
>>>       gzip, deflate, br
>>>       3. Accept-Language:
>>>       en-GB,en-US;q=0.9,en;q=0.8
>>>       4. Access-Control-Request-Headers:
>>>       content-type
>>>       5. Access-Control-Request-Method:
>>>       POST
>>>       6. Connection:
>>>       keep-alive
>>>       7. Host:
>>>       clients.cityfashion.dev.exuvis.com
>>>       <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fclients.cityfashion.dev.exuvis.com&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=%2BiTohXW1uaTpydtAlGWa0leTvEQKK2Wg6XtN%2FqQ73%2F0%3D&reserved=0>
>>>       8. Origin:
>>>       null
>>>       9. User-Agent:
>>>       Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_3)
>>>       AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.167 Safari/537.36
>>>
>>> Response is:
>>>
>>> <p>amfphp and this gateway are installed correctly. You may now connect
>>> to this gateway from Flash.</p><p>Note: If you're reading an old tutorial,
>>> it will tell you that you should see a download window instead of this
>>> message. This confused people so this is the new behaviour starting from
>>> amfphp 1.2.</p><p><a href='http://www.amfphp.org/docs
>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.amfphp.org%2Fdocs&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=%2FGtfS6iuQCrcoifQ5pUOXPJ0JJZcOQaMyYsscjKzA9I%3D&reserved=0>'>View
>>> the amfphp documentation</p><p><a href='browser'>Load the service
>>> browser</a></p><pre>
>>>
>>> Should I target a specific file with the JS version? Should the endPoint
>>> be different?
>>>
>>> On Thu, Feb 15, 2018 at 12:07 PM, Piotr Zarzycki <
>>> piotrzarzycki21@gmail.com> wrote:
>>>
>>>> Frederic,
>>>>
>>>> It looks like it is not problem with framework, but rather CORS issue.
>>>> Maybe try to install this plugin [1] and add to the list your url.
>>>>
>>>> [1] https://chrome.google.com/webstore/detail/allow-control-
>>>> allow-origi/nlfbmbojpeacfghkpbjhddihlkkiljbi?hl=en
>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fchrome.google.com%2Fwebstore%2Fdetail%2Fallow-control-allow-origi%2Fnlfbmbojpeacfghkpbjhddihlkkiljbi%3Fhl%3Den&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=CbZH3KQcH0oGU%2FbnBtyVp%2B9zeqDEUcK9Y6UFd0BIESM%3D&reserved=0>
>>>>
>>>> Piotr
>>>>
>>>> 2018-02-15 12:04 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>>>>
>>>>> For me it is still not working in latest release 0.9.1. I based my
>>>>> example on the example in the SDK.
>>>>>
>>>>> <?xml version="1.0" encoding="utf-8"?>
>>>>> <js:Applicationxmlns:fx="http://ns.adobe.com/mxml/2009
>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.adobe.com%2Fmxml%2F2009&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7cSxKCospCIpbkKY4F%2Fp5lsHBH%2BPFp5Vny2ftXWmL5A%3D&reserved=0>
>>>>> "
>>>>> xmlns:js="library://ns.apache.org/royale/basic
>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.apache.org%2Froyale%2Fbasic&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=D%2FBslvPtV9pNNjpoS4KCQlYHB8ArUYEIXCXuAVoNgYM%3D&reserved=0>
>>>>> "applicationComplete="applicationCompleteHandler(event);">
>>>>>
>>>>>     <fx:Script>
>>>>>         <![CDATA[
>>>>>             import org.apache.royale.net
>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Forg.apache.royale.net&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=ATrXbo2PLqz1dNeyvxVu89zy3yaKPxwIwQm9tSG7ybs%3D&reserved=0>
>>>>> .RemoteObject;
>>>>>             import org.apache.royale.net.events.FaultEvent;
>>>>>             import org.apache.royale.net.events.ResultEvent;
>>>>>
>>>>>             privatefunctionapplicationCompleteHandler(evt:Event):void{
>>>>>                 testLabel.text = "Requesting from AMF";
>>>>>                 service.send("getPackages", null);
>>>>>             }
>>>>>
>>>>>             privatefunctionamfFaultHandler(evt:FaultEvent):void{
>>>>>                 testLabel.text = "Fault in calling AMF";
>>>>>             }
>>>>>
>>>>>             privatefunctionamfResultHandler(evt:ResultEvent):void{
>>>>>                 testLabel.text = "Result received from AMF";
>>>>>             }
>>>>>         ]]>
>>>>>     </fx:Script>
>>>>>
>>>>> <js:valuesImpl>
>>>>> <js:SimpleCSSValuesImpl />
>>>>> </js:valuesImpl>
>>>>>
>>>>>    <js:beads>
>>>>> <js:ClassAliasBead />
>>>>> <js:RemoteObjectid="service"result="amfResultHandler(event)"fault=
>>>>> "amfFaultHandler(event)"
>>>>> endPoint = "https://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=mARoGAlKZYBWmNOBwqTpTRYkqG%2Fk0cvrHwR5kgbfNFY%3D&reserved=0>
>>>>> "
>>>>> destination = "Meta"
>>>>> source = "Meta"/>
>>>>> </js:beads>
>>>>>
>>>>> <js:initialView>
>>>>> <js:View>
>>>>> <js:Labelid="testLabel" />
>>>>> </js:View>
>>>>> </js:initialView>
>>>>> </js:Application>
>>>>>
>>>>>
>>>>> It is not working and showing the following error in the browser:
>>>>>
>>>>> Failed to load https://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=mARoGAlKZYBWmNOBwqTpTRYkqG%2Fk0cvrHwR5kgbfNFY%3D&reserved=0>:
>>>>> Response to preflight request doesn't pass access control check: No
>>>>> 'Access-Control-Allow-Origin' header is present on the requested resource.
>>>>> Origin 'http://localhost' is therefore not allowed access.
>>>>> Language.js:238destination fault handler
>>>>>
>>>>>    1. {code: -1004, message: "Invalid response type.", detail: "Invalid
>>>>>    XMLHttpRequest response status or type.", data: null}
>>>>>       1. code:-1004
>>>>>       2. data:null
>>>>>       3. detail:"Invalid XMLHttpRequest response status or type."
>>>>>       4. message:"Invalid response type."
>>>>>       5. __proto__:Object
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> It is able to compile and run regardless of the errors in compile log:
>>>>>
>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>> println
>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>> he/royale/reflection/AccessorDefinition.js:12: ERROR - required
>>>>> "org.apache.royale.reflection.TypeDefinition" namespace not provided
>>>>> yet
>>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>
>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>> println
>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>> he/royale/reflection/AccessorDefinition.js:13: ERROR - required
>>>>> "org.apache.royale.reflection.VariableDefinition" namespace not
>>>>> provided yet
>>>>> goog.require('org.apache.royale.reflection.VariableDefinition');
>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>
>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>> println
>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>> he/royale/reflection/MethodDefinition.js:14: ERROR - required
>>>>> "org.apache.royale.reflection.TypeDefinition" namespace not provided
>>>>> yet
>>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>
>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>> println
>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>> he/royale/reflection/ParameterDefinition.js:13: ERROR- required
>>>>> "org.apache.royale.reflection.TypeDefinition" namespace not provided
>>>>> yet
>>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>
>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>> println
>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>>> he/royale/reflection/TypeDefinition.js:15: ERROR - required
>>>>> "org.apache.royale.reflection.VariableDefinition" namespace not
>>>>> provided yet
>>>>> goog.require('org.apache.royale.reflection.VariableDefinition');
>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>>
>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>>> printSummary
>>>>> WARNING: 5 error(s), 0 warning(s)
>>>>> The project 'HelloRoyale' has been successfully compiled and optimized.
>>>>> 4.566387 seconds
>>>>>
>>>>>
>>>>> On Mon, Jan 15, 2018 at 7:38 PM, Piotr Zarzycki <
>>>>> piotrzarzycki21@gmail.com> wrote:
>>>>>
>>>>>> Carlos,
>>>>>>
>>>>>> No problem. I have also couple of huge things related to Royale to do
>>>>>> before my hand gets dirty with AMF! :) Unless someone urgently will needed.
>>>>>> :)
>>>>>>
>>>>>> Thanks, Piotr
>>>>>>
>>>>>> 2018-01-15 19:27 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>>>>>>
>>>>>>> Hi Piotr,
>>>>>>> I'll put this on my to do list, but have to do some things first.
>>>>>>> thanks
>>>>>>>
>>>>>>> 2018-01-15 9:26 GMT+01:00 Piotr Zarzycki <pi...@gmail.com>
>>>>>>> :
>>>>>>>
>>>>>>>> Hi Carlos,
>>>>>>>>
>>>>>>>> Can you describe more how to setup those examples ? Could you add
>>>>>>>> to RemoteObjectAMFTest README.md file where you describe steps. I would
>>>>>>>> like to have AMF on my list for tests and improvements. Whenever I look
>>>>>>>> into that I don't know how to proceed with it.
>>>>>>>>
>>>>>>>> Thanks, Piotr
>>>>>>>>
>>>>>>>> 2018-01-15 9:21 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>>>>>>>>
>>>>>>>>> Hi,
>>>>>>>>>
>>>>>>>>> there's an example that we get it working nicely at:
>>>>>>>>>
>>>>>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/
>>>>>>>>> royale/RemoteObjectAMFTest
>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Ftree%2Fdevelop%2Fexamples%2Froyale%2FRemoteObjectAMFTest&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7kdc48rEQiaI4Qp%2BBdfBcGPxddZIYrTUXrQ%2BN2u4tto%3D&reserved=0>
>>>>>>>>>
>>>>>>>>> you can use that as a starting point for your test
>>>>>>>>>
>>>>>>>>> As well a java web app that is used along that royale client
>>>>>>>>> example is at:
>>>>>>>>>
>>>>>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/amf
>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Ftree%2Fdevelop%2Fexamples%2Famf&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=PW4DYIeW4PetVe6BdFYjxFeAjCrqofPYtdbRTnJ4xjk%3D&reserved=0>
>>>>>>>>>
>>>>>>>>> thanks
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> 2018-01-15 3:56 GMT+01:00 Carlos Cruz <ca...@nbtbizcapital.com>:
>>>>>>>>>
>>>>>>>>>> I have a lot of experience with Flex remoting and BlazeDS with
>>>>>>>>>> Java, but with FlexJS and Royale I have none, but extrapolating from some
>>>>>>>>>> JS tests I've done with AMF at this line: amfTestService.send(
>>>>>>>>>> "getShippingMethods", []); you have to call a class in
>>>>>>>>>> gateway.php and a method. Your request needs at least 3 properties.
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> I'm also assuming your JS file and gateway.php are in the same
>>>>>>>>>> domain and same port (this gave me problems).
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Take what I said regarding my experience with FlexJS and Royale
>>>>>>>>>> into account.
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Carlos
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> *From:* Fréderic Cox [mailto:coxfrederic@gmail.com]
>>>>>>>>>> *Sent:* Sunday, January 14, 2018 4:01 PM
>>>>>>>>>>
>>>>>>>>>> *To:* users@royale.apache.org
>>>>>>>>>> *Subject:* Re: RemoteObject
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Script tag was stripped from the post:
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> import org.apache.royale.events.MouseEvent;
>>>>>>>>>>
>>>>>>>>>>                      import org.apache.royale.net.events.F
>>>>>>>>>> aultEvent;
>>>>>>>>>>
>>>>>>>>>>                      import org.apache.royale.net.events.R
>>>>>>>>>> esultEvent;
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>                      protectedfunction
>>>>>>>>>> textbutton_clickHandler(event:org.apache.royale.events.Mouse
>>>>>>>>>> Event):void
>>>>>>>>>>
>>>>>>>>>>                      {
>>>>>>>>>>
>>>>>>>>>>                            statusLabel.text = "calling.......";
>>>>>>>>>>
>>>>>>>>>>                            amfTestService.addEventListener(
>>>>>>>>>> "fault", amfTestService_faultHandler);
>>>>>>>>>>
>>>>>>>>>>                            amfTestService.addEventListener(
>>>>>>>>>> "result", amfTestService_resultHandler);
>>>>>>>>>>
>>>>>>>>>>                            amfTestService.send("getShippi
>>>>>>>>>> ngMethods", []);
>>>>>>>>>>
>>>>>>>>>>                      }
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>                      protectedfunction
>>>>>>>>>> amfTestService_faultHandler(event:FaultEvent):void
>>>>>>>>>>
>>>>>>>>>>                      {
>>>>>>>>>>
>>>>>>>>>>                            statusLabel.text = "error!";
>>>>>>>>>>
>>>>>>>>>>                      }
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>                      protectedfunction
>>>>>>>>>> amfTestService_resultHandler(event:ResultEvent):void
>>>>>>>>>>
>>>>>>>>>>                      {
>>>>>>>>>>
>>>>>>>>>>                            statusLabel.text = "result!";
>>>>>>>>>>
>>>>>>>>>>                      }
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> none of the events are triggered ..URL is
>>>>>>>>>> http://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=EJDBQBL83yBhDn%2BWWgCCVyw0N3tnakhZ7UdEt4JFNaY%3D&reserved=0>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> On Fri, Jan 12, 2018 at 4:55 AM, Carlos Cruz <
>>>>>>>>>> carlos@nbtbizcapital.com> wrote:
>>>>>>>>>>
>>>>>>>>>> I may be blind (and or ignorant as I'm more familiar with Flex)
>>>>>>>>>> but where
>>>>>>>>>> are you sending an AMF request? I don't see any code that sends a
>>>>>>>>>> request to
>>>>>>>>>> a service and invokes method.
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> -----Original Message-----
>>>>>>>>>> From: coxfrederic [mailto:coxfrederic@gmail.com]
>>>>>>>>>> Sent: Thursday, January 11, 2018 9:09 PM
>>>>>>>>>> To: users@royale.apache.org
>>>>>>>>>> Subject: Re: RemoteObject
>>>>>>>>>>
>>>>>>>>>> <?xml version="1.0" encoding="utf-8"?>
>>>>>>>>>>
>>>>>>>>>> <js:Application xmlns:fx="http://ns.adobe.com/mxml/2009
>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.adobe.com%2Fmxml%2F2009&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7cSxKCospCIpbkKY4F%2Fp5lsHBH%2BPFp5Vny2ftXWmL5A%3D&reserved=0>
>>>>>>>>>> "
>>>>>>>>>>                    xmlns:js="library://ns.apache.org/royale/basic
>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.apache.org%2Froyale%2Fbasic&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=D%2FBslvPtV9pNNjpoS4KCQlYHB8ArUYEIXCXuAVoNgYM%3D&reserved=0>"
>>>>>>>>>> >
>>>>>>>>>>         <fx:Script>
>>>>>>>>>>
>>>>>>>>>>         </fx:Script>
>>>>>>>>>>     <js:valuesImpl>
>>>>>>>>>>         <js:SimpleCSSValuesImpl />
>>>>>>>>>>     </js:valuesImpl>
>>>>>>>>>>
>>>>>>>>>>         <js:beads>
>>>>>>>>>>                 <js:ClassAliasBead />
>>>>>>>>>>                 <js:RemoteObject id="amfTestService"
>>>>>>>>>>
>>>>>>>>>> endPoint="http://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=EJDBQBL83yBhDn%2BWWgCCVyw0N3tnakhZ7UdEt4JFNaY%3D&reserved=0>
>>>>>>>>>> "
>>>>>>>>>>
>>>>>>>>>>  destination="Meta"
>>>>>>>>>> source="Meta" />
>>>>>>>>>>         </js:beads>
>>>>>>>>>>
>>>>>>>>>>     <js:initialView>
>>>>>>>>>>         <js:View>
>>>>>>>>>>                         <js:VGroup>
>>>>>>>>>>                                 <js:Label id="statusLabel"
>>>>>>>>>> text="Hello
>>>>>>>>>> World!" />
>>>>>>>>>>                                 <js:TextButton text="Get AMF data"
>>>>>>>>>> click="textbutton_clickHandler(event)" />
>>>>>>>>>>                         </js:VGroup>
>>>>>>>>>>         </js:View>
>>>>>>>>>>     </js:initialView>
>>>>>>>>>> </js:Application>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Any idea why I'm not getting a fault nor success event on this?
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> --
>>>>>>>>>> Sent from: http://apache-royale-users.20374.n8.nabble.com/
>>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fapache-royale-users.20374.n8.nabble.com%2F&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=xvY8nK1QKlWduh6p5x8y19jm%2Br60PSFVlNdi6TRsPmw%3D&reserved=0>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> Carlos Rovira
>>>>>>>>> http://about.me/carlosrovira
>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fabout.me%2Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=55MSUXBM2zE5U0csgV1harcuXvKyZ2gd%2BO%2FmD7hjJ50%3D&reserved=0>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> --
>>>>>>>>
>>>>>>>> Piotr Zarzycki
>>>>>>>>
>>>>>>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=NG2rkkxhfc7MTSVRqHzEmHL8HuUpvXI72B9nkW2QfdU%3D&reserved=0>*
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> Carlos Rovira
>>>>>>> http://about.me/carlosrovira
>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fabout.me%2Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=55MSUXBM2zE5U0csgV1harcuXvKyZ2gd%2BO%2FmD7hjJ50%3D&reserved=0>
>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>>
>>>>>> Piotr Zarzycki
>>>>>>
>>>>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=NG2rkkxhfc7MTSVRqHzEmHL8HuUpvXI72B9nkW2QfdU%3D&reserved=0>*
>>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>>
>>>> Piotr Zarzycki
>>>>
>>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=NG2rkkxhfc7MTSVRqHzEmHL8HuUpvXI72B9nkW2QfdU%3D&reserved=0>*
>>>>
>>>
>>>
>>
>
>
> --
> Carlos Rovira
> http://about.me/carlosrovira
>
>


-- 
Carlos Rovira
http://about.me/carlosrovira

Re: RemoteObject

Posted by Fréderic Cox <co...@gmail.com>.
Hi Carlos,

Sure I’ll see what I can do. Feel I have lots to leatn about Royale and AMF (it just works with Flash/AIR so not up to date about the inner workings).

I’ll try to test the examples over the weekend. Do you think the AMFPHP version could be an issue or is it assumed to work in Royale if it works in Flex? 

Verstuurd vanaf mijn iPhone

> Op 16 feb. 2018 om 12:28 heeft Carlos Rovira <ca...@apache.org> het volgende geschreven:
> 
> Hi Frederic, 
> thanks for filling this and take a look into AMF!
> Hope you could help us a bit with this.
> 
> 2018-02-16 0:21 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>> Hi Alex, 
>> 
>> I created https://github.com/apache/royale-asjs/issues/119, hope that is in the correct place and with more readable mark-up.
>> 
>> Regards,
>> 
>> Fréderic
>> 
>>> On Thu, Feb 15, 2018 at 8:57 PM, Alex Harui <ah...@adobe.com> wrote:
>>> Hi Frederic,
>>> 
>>> Where is this output you posted coming from, a network monitor?  It was too hard to read, so please create a bug report on GitHub and post it there.
>>> 
>>> You might be able to use a network monitor to compare what Flex sent vs what Royale is sending.  What does your Flex usage of RemoteObject look like?
>>> 
>>> HTH,
>>> -Alex
>>> 
>>> From: Fréderic Cox <co...@gmail.com>
>>> Reply-To: "users@royale.apache.org" <us...@royale.apache.org>
>>> Date: Thursday, February 15, 2018 at 5:09 AM
>>> To: "users@royale.apache.org" <us...@royale.apache.org>
>>> Subject: Re: RemoteObject
>>> 
>>> Hi Piotr,
>>> 
>>> Thanks, I installed the extension and now I'm not getting the CORS error anymore.
>>> I'm not getting any fault or result event triggered either....
>>> 
>>> The endPoint set is
>>> 
>>> https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php
>>> 
>>> 
>>> This is correct, right? (I use this endpoint in Flex and that works fine)
>>> 
>>> 
>>> Request URL: 
>>> https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php
>>> 
>>> Request Method: 
>>> OPTIONS
>>> 
>>> Status Code:  
>>> 200 OK
>>> 
>>> Remote Address: 
>>> 188.93.153.101:443
>>> 
>>> Referrer Policy: 
>>> no-referrer-when-downgrade
>>> Response Headers
>>> view source
>>> 
>>> Connection: 
>>> keep-alive
>>> 
>>> Content-Encoding: 
>>> gzip
>>> 
>>> Content-Length: 
>>> 286
>>> 
>>> Content-Type: 
>>> text/html; charset=UTF-8
>>> 
>>> Date: 
>>> Thu, 15 Feb 2018 13:08:17 GMT
>>> 
>>> Server: 
>>> nginx
>>> 
>>> Vary: 
>>> Accept-Encoding
>>> Request Headers
>>> view source
>>> 
>>> Accept: 
>>> */*
>>> 
>>> Accept-Encoding: 
>>> gzip, deflate, br
>>> 
>>> Accept-Language: 
>>> en-GB,en-US;q=0.9,en;q=0.8
>>> 
>>> Access-Control-Request-Headers: 
>>> content-type
>>> 
>>> Access-Control-Request-Method: 
>>> POST
>>> 
>>> Connection: 
>>> keep-alive
>>> 
>>> Host: 
>>> clients.cityfashion.dev.exuvis.com
>>> 
>>> Origin: 
>>> null
>>> 
>>> User-Agent: 
>>> Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_3) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.167 Safari/537.36
>>> Response is:
>>> 
>>> <p>amfphp and this gateway are installed correctly. You may now connect to this gateway from Flash.</p><p>Note: If you're reading an old tutorial, it will tell you that you should see a download window instead of this message. This confused people so this is the new behaviour starting from amfphp 1.2.</p><p><a href='http://www.amfphp.org/docs'>View the amfphp documentation</p><p><a href='browser'>Load the service browser</a></p><pre>
>>> 
>>> Should I target a specific file with the JS version? Should the endPoint be different?
>>> 
>>>> On Thu, Feb 15, 2018 at 12:07 PM, Piotr Zarzycki <pi...@gmail.com> wrote:
>>>> Frederic,
>>>> 
>>>> It looks like it is not problem with framework, but rather CORS issue. Maybe try to install this plugin [1] and add to the list your url.
>>>> 
>>>> [1] https://chrome.google.com/webstore/detail/allow-control-allow-origi/nlfbmbojpeacfghkpbjhddihlkkiljbi?hl=en
>>>> 
>>>> Piotr
>>>> 
>>>> 2018-02-15 12:04 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>>>>> For me it is still not working in latest release 0.9.1. I based my example on the example in the SDK.
>>>>> 
>>>>> 
>>>>> 
>>>>> <?xml version="1.0"
>>>>>  encoding="utf-8"?>
>>>>> 
>>>>> <js:Applicationxmlns:fx="http://ns.adobe.com/mxml/2009"
>>>>> 
>>>>> 
>>>>> xmlns:js="library://ns.apache.org/royale/basic"applicationComplete="applicationCompleteHandler(event);">
>>>>> 
>>>>> 
>>>>> 
>>>>>     <fx:Script>
>>>>> 
>>>>>         <![CDATA[
>>>>> 
>>>>>             import
>>>>>  org.apache.royale.net.RemoteObject;
>>>>> 
>>>>>             import org.apache.royale.net.events.FaultEvent;
>>>>> 
>>>>>             import org.apache.royale.net.events.ResultEvent;
>>>>> 
>>>>> 
>>>>> 
>>>>>             privatefunctionapplicationCompleteHandler(evt:Event):void{
>>>>> 
>>>>>                 testLabel.text = "Requesting from AMF";
>>>>> 
>>>>>                 service.send("getPackages",
>>>>> null);
>>>>> 
>>>>>             }
>>>>> 
>>>>> 
>>>>> 
>>>>>             privatefunctionamfFaultHandler(evt:FaultEvent):void{
>>>>> 
>>>>>                 testLabel.text = "Fault in calling AMF";
>>>>> 
>>>>>             }
>>>>> 
>>>>> 
>>>>> 
>>>>>             privatefunctionamfResultHandler(evt:ResultEvent):void{
>>>>> 
>>>>>                 testLabel.text = "Result received from AMF";
>>>>> 
>>>>>             }
>>>>> 
>>>>>         ]]>
>>>>> 
>>>>> 
>>>>>     </fx:Script>
>>>>> 
>>>>> 
>>>>> 
>>>>> <js:valuesImpl>
>>>>> 
>>>>> <js:SimpleCSSValuesImpl />
>>>>> 
>>>>> </js:valuesImpl>
>>>>> 
>>>>> 
>>>>> 
>>>>>    <js:beads>
>>>>> 
>>>>> <js:ClassAliasBead />
>>>>> 
>>>>> 
>>>>> <js:RemoteObjectid="service"result="amfResultHandler(event)"fault="amfFaultHandler(event)"
>>>>> 
>>>>> endPoint =
>>>>> "https://winkelbeheer.cityfashion.be/amfphp/gateway.php"
>>>>> 
>>>>> destination =
>>>>> "Meta"
>>>>> 
>>>>> source =
>>>>> "Meta"/>
>>>>> 
>>>>> 
>>>>> </js:beads>
>>>>> 
>>>>> 
>>>>> 
>>>>> <js:initialView>
>>>>> 
>>>>> <js:View>
>>>>> 
>>>>> 
>>>>> <js:Labelid="testLabel"
>>>>>  />
>>>>> 
>>>>> 
>>>>> </js:View>
>>>>> 
>>>>> </js:initialView>
>>>>> 
>>>>> </js:Application>
>>>>> 
>>>>> 
>>>>> 
>>>>> It is not working and showing the following error in the browser:
>>>>> 
>>>>>  Failed
>>>>>  to load 
>>>>> https://winkelbeheer.cityfashion.be/amfphp/gateway.php:
>>>>>  Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://localhost'
>>>>>  is therefore not allowed access.
>>>>> Language.js:238destination
>>>>>  fault handler
>>>>> 
>>>>> 
>>>>> {code: -1004, message: "Invalid
>>>>>  response type.", detail: "Invalid
>>>>>  XMLHttpRequest response status or type.", data: null}
>>>>> code
>>>>> :
>>>>> -1004
>>>>> data
>>>>> :
>>>>> null
>>>>> detail
>>>>> :
>>>>> "Invalid
>>>>>  XMLHttpRequest response status or type."
>>>>> message
>>>>> :
>>>>> "Invalid
>>>>>  response type."
>>>>> __proto__
>>>>> :
>>>>> Object
>>>>> 
>>>>> 
>>>>> 
>>>>> 
>>>>> 
>>>>> 
>>>>> It is able to compile and run regardless of the errors in compile log:
>>>>> 
>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager println
>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apache/royale/reflection/AccessorDefinition.js:12: ERROR - required "org.apache.royale.reflection.TypeDefinition" namespace not provided yet
>>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>> 
>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager println
>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apache/royale/reflection/AccessorDefinition.js:13: ERROR - required "org.apache.royale.reflection.VariableDefinition" namespace not provided yet
>>>>> goog.require('org.apache.royale.reflection.VariableDefinition');
>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>> 
>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager println
>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apache/royale/reflection/MethodDefinition.js:14: ERROR - required "org.apache.royale.reflection.TypeDefinition" namespace not provided yet
>>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>> 
>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager println
>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apache/royale/reflection/ParameterDefinition.js:13: ERROR- required "org.apache.royale.reflection.TypeDefinition" namespace not provided yet
>>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>> 
>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager println
>>>>> SEVERE: /Users/frederic/Desktop/Personal/Web Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apache/royale/reflection/TypeDefinition.js:15: ERROR - required "org.apache.royale.reflection.VariableDefinition" namespace not provided yet
>>>>> goog.require('org.apache.royale.reflection.VariableDefinition');
>>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>> 
>>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager printSummary
>>>>> WARNING: 5 error(s), 0 warning(s)
>>>>> The project 'HelloRoyale' has been successfully compiled and optimized.
>>>>> 4.566387 seconds
>>>>> 
>>>>> 
>>>>>> On Mon, Jan 15, 2018 at 7:38 PM, Piotr Zarzycki <pi...@gmail.com> wrote:
>>>>>> Carlos,
>>>>>> 
>>>>>> No problem. I have also couple of huge things related to Royale to do before my hand gets dirty with AMF! :) Unless someone urgently will needed. :)
>>>>>> 
>>>>>> Thanks, Piotr
>>>>>> 
>>>>>> 2018-01-15 19:27 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>>>>>>> Hi Piotr,
>>>>>>> I'll put this on my to do list, but have to do some things first.
>>>>>>> thanks
>>>>>>> 
>>>>>>> 2018-01-15 9:26 GMT+01:00 Piotr Zarzycki <pi...@gmail.com>:
>>>>>>>> Hi Carlos,
>>>>>>>> 
>>>>>>>> Can you describe more how to setup those examples ? Could you add to RemoteObjectAMFTest README.md file where you describe steps. I would like to have AMF on my list for tests and improvements. Whenever I look into that I don't know how to proceed with it.
>>>>>>>> 
>>>>>>>> Thanks, Piotr
>>>>>>>> 
>>>>>>>> 2018-01-15 9:21 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>>>>>>>>> Hi, 
>>>>>>>>> 
>>>>>>>>> there's an example that we get it working nicely at:
>>>>>>>>> 
>>>>>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/royale/RemoteObjectAMFTest
>>>>>>>>> 
>>>>>>>>> you can use that as a starting point for your test
>>>>>>>>> 
>>>>>>>>> As well a java web app that is used along that royale client example is at:
>>>>>>>>> 
>>>>>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/amf
>>>>>>>>> 
>>>>>>>>> thanks
>>>>>>>>> 
>>>>>>>>> 
>>>>>>>>> 2018-01-15 3:56 GMT+01:00 Carlos Cruz <ca...@nbtbizcapital.com>:
>>>>>>>>>> I have a lot of experience with Flex remoting and BlazeDS with Java, but with FlexJS and Royale I have none, but extrapolating from some JS tests I've done with AMF at this line: amfTestService.send("getShippingMethods", []); you have to call a class in gateway.php and a method. Your request needs at least 3 properties. 
>>>>>>>>>> 
>>>>>>>>>>  
>>>>>>>>>> 
>>>>>>>>>> I'm also assuming your JS file and gateway.php are in the same domain and same port (this gave me problems).
>>>>>>>>>> 
>>>>>>>>>>  
>>>>>>>>>> 
>>>>>>>>>> Take what I said regarding my experience with FlexJS and Royale into account. 
>>>>>>>>>> 
>>>>>>>>>>  
>>>>>>>>>> 
>>>>>>>>>> Carlos 
>>>>>>>>>> 
>>>>>>>>>>  
>>>>>>>>>> 
>>>>>>>>>>  
>>>>>>>>>> 
>>>>>>>>>> From: Fréderic Cox [mailto:coxfrederic@gmail.com] 
>>>>>>>>>> Sent: Sunday, January 14, 2018 4:01 PM
>>>>>>>>>> 
>>>>>>>>>> 
>>>>>>>>>> To: users@royale.apache.org
>>>>>>>>>> Subject: Re: RemoteObject
>>>>>>>>>>  
>>>>>>>>>> 
>>>>>>>>>> Script tag was stripped from the post:
>>>>>>>>>> 
>>>>>>>>>>  
>>>>>>>>>> 
>>>>>>>>>> import org.apache.royale.events.MouseEvent;
>>>>>>>>>>                      import org.apache.royale.net.events.FaultEvent;
>>>>>>>>>>                      import org.apache.royale.net.events.ResultEvent;
>>>>>>>>>>                     
>>>>>>>>>>                      protectedfunction textbutton_clickHandler(event:org.apache.royale.events.MouseEvent):void
>>>>>>>>>>                      {
>>>>>>>>>>                            statusLabel.text = "calling.......";
>>>>>>>>>>                            amfTestService.addEventListener("fault", amfTestService_faultHandler);
>>>>>>>>>>                            amfTestService.addEventListener("result", amfTestService_resultHandler);
>>>>>>>>>>                            amfTestService.send("getShippingMethods", []);
>>>>>>>>>>                      }
>>>>>>>>>>                     
>>>>>>>>>>                      protectedfunction amfTestService_faultHandler(event:FaultEvent):void
>>>>>>>>>>                      {
>>>>>>>>>>                            statusLabel.text = "error!";
>>>>>>>>>>                      }
>>>>>>>>>>                     
>>>>>>>>>>                      protectedfunction amfTestService_resultHandler(event:ResultEvent):void
>>>>>>>>>>                      {
>>>>>>>>>>                            statusLabel.text = "result!";
>>>>>>>>>>                      }
>>>>>>>>>>  
>>>>>>>>>> none of the events are triggered ..URL is http://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>>>>>>  
>>>>>>>>>> 
>>>>>>>>>> On Fri, Jan 12, 2018 at 4:55 AM, Carlos Cruz <ca...@nbtbizcapital.com> wrote:
>>>>>>>>>> 
>>>>>>>>>> I may be blind (and or ignorant as I'm more familiar with Flex) but where
>>>>>>>>>> are you sending an AMF request? I don't see any code that sends a request to
>>>>>>>>>> a service and invokes method.
>>>>>>>>>> 
>>>>>>>>>> 
>>>>>>>>>> -----Original Message-----
>>>>>>>>>> From: coxfrederic [mailto:coxfrederic@gmail.com]
>>>>>>>>>> Sent: Thursday, January 11, 2018 9:09 PM
>>>>>>>>>> To: users@royale.apache.org
>>>>>>>>>> Subject: Re: RemoteObject
>>>>>>>>>> 
>>>>>>>>>> <?xml version="1.0" encoding="utf-8"?>
>>>>>>>>>> 
>>>>>>>>>> <js:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
>>>>>>>>>>                    xmlns:js="library://ns.apache.org/royale/basic" >
>>>>>>>>>>         <fx:Script>
>>>>>>>>>> 
>>>>>>>>>>         </fx:Script>
>>>>>>>>>>     <js:valuesImpl>
>>>>>>>>>>         <js:SimpleCSSValuesImpl />
>>>>>>>>>>     </js:valuesImpl>
>>>>>>>>>> 
>>>>>>>>>>         <js:beads>
>>>>>>>>>>                 <js:ClassAliasBead />
>>>>>>>>>>                 <js:RemoteObject id="amfTestService"
>>>>>>>>>> 
>>>>>>>>>> endPoint="http://winkelbeheer.cityfashion.be/amfphp/gateway.php"
>>>>>>>>>>                                                  destination="Meta"
>>>>>>>>>> source="Meta" />
>>>>>>>>>>         </js:beads>
>>>>>>>>>> 
>>>>>>>>>>     <js:initialView>
>>>>>>>>>>         <js:View>
>>>>>>>>>>                         <js:VGroup>
>>>>>>>>>>                                 <js:Label id="statusLabel" text="Hello
>>>>>>>>>> World!" />
>>>>>>>>>>                                 <js:TextButton text="Get AMF data"
>>>>>>>>>> click="textbutton_clickHandler(event)" />
>>>>>>>>>>                         </js:VGroup>
>>>>>>>>>>         </js:View>
>>>>>>>>>>     </js:initialView>
>>>>>>>>>> </js:Application>
>>>>>>>>>> 
>>>>>>>>>> 
>>>>>>>>>> Any idea why I'm not getting a fault nor success event on this?
>>>>>>>>>> 
>>>>>>>>>> 
>>>>>>>>>> 
>>>>>>>>>> --
>>>>>>>>>> Sent from: http://apache-royale-users.20374.n8.nabble.com/
>>>>>>>>>> 
>>>>>>>>>>  
>>>>>>>>>> 
>>>>>>>>> 
>>>>>>>>> 
>>>>>>>>> 
>>>>>>>>> -- 
>>>>>>>>> Carlos Rovira
>>>>>>>>> http://about.me/carlosrovira
>>>>>>>>> 
>>>>>>>> 
>>>>>>>> 
>>>>>>>> 
>>>>>>>> -- 
>>>>>>>> Piotr Zarzycki 
>>>>>>>> 
>>>>>>>> Patreon: https://www.patreon.com/piotrzarzycki
>>>>>>>> 
>>>>>>> 
>>>>>>> 
>>>>>>> 
>>>>>>> 
>>>>>>> -- 
>>>>>>> Carlos Rovira
>>>>>>> http://about.me/carlosrovira
>>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> -- 
>>>>>> Piotr Zarzycki 
>>>>>> 
>>>>>> Patreon: https://www.patreon.com/piotrzarzycki
>>>>>> 
>>>>> 
>>>> 
>>>> 
>>>> 
>>>> 
>>>> -- 
>>>> Piotr Zarzycki 
>>>> 
>>>> Patreon: https://www.patreon.com/piotrzarzycki
>>>> 
>>> 
>> 
> 
> 
> 
> -- 
> Carlos Rovira
> http://about.me/carlosrovira
> 

Re: RemoteObject

Posted by Carlos Rovira <ca...@apache.org>.
Hi Frederic,
thanks for filling this and take a look into AMF!
Hope you could help us a bit with this.

2018-02-16 0:21 GMT+01:00 Fréderic Cox <co...@gmail.com>:

> Hi Alex,
>
> I created https://github.com/apache/royale-asjs/issues/119, hope that is
> in the correct place and with more readable mark-up.
>
> Regards,
>
> Fréderic
>
> On Thu, Feb 15, 2018 at 8:57 PM, Alex Harui <ah...@adobe.com> wrote:
>
>> Hi Frederic,
>>
>> Where is this output you posted coming from, a network monitor?  It was
>> too hard to read, so please create a bug report on GitHub and post it there.
>>
>> You might be able to use a network monitor to compare what Flex sent vs
>> what Royale is sending.  What does your Flex usage of RemoteObject look
>> like?
>>
>> HTH,
>> -Alex
>>
>> From: Fréderic Cox <co...@gmail.com>
>> Reply-To: "users@royale.apache.org" <us...@royale.apache.org>
>> Date: Thursday, February 15, 2018 at 5:09 AM
>> To: "users@royale.apache.org" <us...@royale.apache.org>
>> Subject: Re: RemoteObject
>>
>> Hi Piotr,
>>
>> Thanks, I installed the extension and now I'm not getting the CORS error
>> anymore.
>> I'm not getting any fault or result event triggered either....
>>
>> The endPoint set is
>> https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php
>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fclients.cityfashion.dev.exuvis.com%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=67VMfKVGZo%2BarMstlt%2BZbX5OdTomYDQNSgM07ycK%2Bvc%3D&reserved=0>
>>
>> This is correct, right? (I use this endpoint in Flex and that works fine)
>>
>>
>>    1. Request URL:
>>       https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php
>>       <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fclients.cityfashion.dev.exuvis.com%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=67VMfKVGZo%2BarMstlt%2BZbX5OdTomYDQNSgM07ycK%2Bvc%3D&reserved=0>
>>       2. Request Method:
>>       OPTIONS
>>       3. Status Code:
>>       200 OK
>>       4. Remote Address:
>>       188.93.153.101:443
>>       <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2F188.93.153.101%3A443&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=UWqG%2BqQTcL1fTnck9i5BPXmrn3ZlgRf8XCPpQ8EcJrE%3D&reserved=0>
>>       5. Referrer Policy:
>>       no-referrer-when-downgrade
>>       1. Response Headersview source
>>       1. Connection:
>>       keep-alive
>>       2. Content-Encoding:
>>       gzip
>>       3. Content-Length:
>>       286
>>       4. Content-Type:
>>       text/html; charset=UTF-8
>>       5. Date:
>>       Thu, 15 Feb 2018 13:08:17 GMT
>>       6. Server:
>>       nginx
>>       7. Vary:
>>       Accept-Encoding
>>       2. Request Headersview source
>>       1. Accept:
>>       */*
>>       2. Accept-Encoding:
>>       gzip, deflate, br
>>       3. Accept-Language:
>>       en-GB,en-US;q=0.9,en;q=0.8
>>       4. Access-Control-Request-Headers:
>>       content-type
>>       5. Access-Control-Request-Method:
>>       POST
>>       6. Connection:
>>       keep-alive
>>       7. Host:
>>       clients.cityfashion.dev.exuvis.com
>>       <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fclients.cityfashion.dev.exuvis.com&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=%2BiTohXW1uaTpydtAlGWa0leTvEQKK2Wg6XtN%2FqQ73%2F0%3D&reserved=0>
>>       8. Origin:
>>       null
>>       9. User-Agent:
>>       Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_3) AppleWebKit/537.36
>>       (KHTML, like Gecko) Chrome/64.0.3282.167 Safari/537.36
>>
>> Response is:
>>
>> <p>amfphp and this gateway are installed correctly. You may now connect
>> to this gateway from Flash.</p><p>Note: If you're reading an old tutorial,
>> it will tell you that you should see a download window instead of this
>> message. This confused people so this is the new behaviour starting from
>> amfphp 1.2.</p><p><a href='http://www.amfphp.org/docs
>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.amfphp.org%2Fdocs&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=%2FGtfS6iuQCrcoifQ5pUOXPJ0JJZcOQaMyYsscjKzA9I%3D&reserved=0>'>View
>> the amfphp documentation</p><p><a href='browser'>Load the service
>> browser</a></p><pre>
>>
>> Should I target a specific file with the JS version? Should the endPoint
>> be different?
>>
>> On Thu, Feb 15, 2018 at 12:07 PM, Piotr Zarzycki <
>> piotrzarzycki21@gmail.com> wrote:
>>
>>> Frederic,
>>>
>>> It looks like it is not problem with framework, but rather CORS issue.
>>> Maybe try to install this plugin [1] and add to the list your url.
>>>
>>> [1] https://chrome.google.com/webstore/detail/allow-control-
>>> allow-origi/nlfbmbojpeacfghkpbjhddihlkkiljbi?hl=en
>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fchrome.google.com%2Fwebstore%2Fdetail%2Fallow-control-allow-origi%2Fnlfbmbojpeacfghkpbjhddihlkkiljbi%3Fhl%3Den&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=CbZH3KQcH0oGU%2FbnBtyVp%2B9zeqDEUcK9Y6UFd0BIESM%3D&reserved=0>
>>>
>>> Piotr
>>>
>>> 2018-02-15 12:04 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>>>
>>>> For me it is still not working in latest release 0.9.1. I based my
>>>> example on the example in the SDK.
>>>>
>>>> <?xml version="1.0" encoding="utf-8"?>
>>>> <js:Applicationxmlns:fx="http://ns.adobe.com/mxml/2009
>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.adobe.com%2Fmxml%2F2009&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7cSxKCospCIpbkKY4F%2Fp5lsHBH%2BPFp5Vny2ftXWmL5A%3D&reserved=0>
>>>> "
>>>> xmlns:js="library://ns.apache.org/royale/basic
>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.apache.org%2Froyale%2Fbasic&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=D%2FBslvPtV9pNNjpoS4KCQlYHB8ArUYEIXCXuAVoNgYM%3D&reserved=0>
>>>> "applicationComplete="applicationCompleteHandler(event);">
>>>>
>>>>     <fx:Script>
>>>>         <![CDATA[
>>>>             import org.apache.royale.net
>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Forg.apache.royale.net&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=ATrXbo2PLqz1dNeyvxVu89zy3yaKPxwIwQm9tSG7ybs%3D&reserved=0>
>>>> .RemoteObject;
>>>>             import org.apache.royale.net.events.FaultEvent;
>>>>             import org.apache.royale.net.events.ResultEvent;
>>>>
>>>>             privatefunctionapplicationCompleteHandler(evt:Event):void{
>>>>                 testLabel.text = "Requesting from AMF";
>>>>                 service.send("getPackages", null);
>>>>             }
>>>>
>>>>             privatefunctionamfFaultHandler(evt:FaultEvent):void{
>>>>                 testLabel.text = "Fault in calling AMF";
>>>>             }
>>>>
>>>>             privatefunctionamfResultHandler(evt:ResultEvent):void{
>>>>                 testLabel.text = "Result received from AMF";
>>>>             }
>>>>         ]]>
>>>>     </fx:Script>
>>>>
>>>> <js:valuesImpl>
>>>> <js:SimpleCSSValuesImpl />
>>>> </js:valuesImpl>
>>>>
>>>>    <js:beads>
>>>> <js:ClassAliasBead />
>>>> <js:RemoteObjectid="service"result="amfResultHandler(event)"fault=
>>>> "amfFaultHandler(event)"
>>>> endPoint = "https://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=mARoGAlKZYBWmNOBwqTpTRYkqG%2Fk0cvrHwR5kgbfNFY%3D&reserved=0>
>>>> "
>>>> destination = "Meta"
>>>> source = "Meta"/>
>>>> </js:beads>
>>>>
>>>> <js:initialView>
>>>> <js:View>
>>>> <js:Labelid="testLabel" />
>>>> </js:View>
>>>> </js:initialView>
>>>> </js:Application>
>>>>
>>>>
>>>> It is not working and showing the following error in the browser:
>>>>
>>>> Failed to load https://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=mARoGAlKZYBWmNOBwqTpTRYkqG%2Fk0cvrHwR5kgbfNFY%3D&reserved=0>:
>>>> Response to preflight request doesn't pass access control check: No
>>>> 'Access-Control-Allow-Origin' header is present on the requested resource.
>>>> Origin 'http://localhost' is therefore not allowed access.
>>>> Language.js:238destination fault handler
>>>>
>>>>    1. {code: -1004, message: "Invalid response type.", detail: "Invalid
>>>>    XMLHttpRequest response status or type.", data: null}
>>>>       1. code:-1004
>>>>       2. data:null
>>>>       3. detail:"Invalid XMLHttpRequest response status or type."
>>>>       4. message:"Invalid response type."
>>>>       5. __proto__:Object
>>>>
>>>>
>>>>
>>>>
>>>> It is able to compile and run regardless of the errors in compile log:
>>>>
>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>> println
>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>> he/royale/reflection/AccessorDefinition.js:12: ERROR - required
>>>> "org.apache.royale.reflection.TypeDefinition" namespace not provided
>>>> yet
>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>
>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>> println
>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>> he/royale/reflection/AccessorDefinition.js:13: ERROR - required
>>>> "org.apache.royale.reflection.VariableDefinition" namespace not
>>>> provided yet
>>>> goog.require('org.apache.royale.reflection.VariableDefinition');
>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>
>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>> println
>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>> he/royale/reflection/MethodDefinition.js:14: ERROR - required
>>>> "org.apache.royale.reflection.TypeDefinition" namespace not provided
>>>> yet
>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>
>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>> println
>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>> he/royale/reflection/ParameterDefinition.js:13: ERROR- required
>>>> "org.apache.royale.reflection.TypeDefinition" namespace not provided
>>>> yet
>>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>
>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>> println
>>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>>> he/royale/reflection/TypeDefinition.js:15: ERROR - required
>>>> "org.apache.royale.reflection.VariableDefinition" namespace not
>>>> provided yet
>>>> goog.require('org.apache.royale.reflection.VariableDefinition');
>>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>>
>>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>>> printSummary
>>>> WARNING: 5 error(s), 0 warning(s)
>>>> The project 'HelloRoyale' has been successfully compiled and optimized.
>>>> 4.566387 seconds
>>>>
>>>>
>>>> On Mon, Jan 15, 2018 at 7:38 PM, Piotr Zarzycki <
>>>> piotrzarzycki21@gmail.com> wrote:
>>>>
>>>>> Carlos,
>>>>>
>>>>> No problem. I have also couple of huge things related to Royale to do
>>>>> before my hand gets dirty with AMF! :) Unless someone urgently will needed.
>>>>> :)
>>>>>
>>>>> Thanks, Piotr
>>>>>
>>>>> 2018-01-15 19:27 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>>>>>
>>>>>> Hi Piotr,
>>>>>> I'll put this on my to do list, but have to do some things first.
>>>>>> thanks
>>>>>>
>>>>>> 2018-01-15 9:26 GMT+01:00 Piotr Zarzycki <pi...@gmail.com>:
>>>>>>
>>>>>>> Hi Carlos,
>>>>>>>
>>>>>>> Can you describe more how to setup those examples ? Could you add to
>>>>>>> RemoteObjectAMFTest README.md file where you describe steps. I would like
>>>>>>> to have AMF on my list for tests and improvements. Whenever I look into
>>>>>>> that I don't know how to proceed with it.
>>>>>>>
>>>>>>> Thanks, Piotr
>>>>>>>
>>>>>>> 2018-01-15 9:21 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>>>>>>>
>>>>>>>> Hi,
>>>>>>>>
>>>>>>>> there's an example that we get it working nicely at:
>>>>>>>>
>>>>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/
>>>>>>>> royale/RemoteObjectAMFTest
>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Ftree%2Fdevelop%2Fexamples%2Froyale%2FRemoteObjectAMFTest&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7kdc48rEQiaI4Qp%2BBdfBcGPxddZIYrTUXrQ%2BN2u4tto%3D&reserved=0>
>>>>>>>>
>>>>>>>> you can use that as a starting point for your test
>>>>>>>>
>>>>>>>> As well a java web app that is used along that royale client
>>>>>>>> example is at:
>>>>>>>>
>>>>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/amf
>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Ftree%2Fdevelop%2Fexamples%2Famf&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=PW4DYIeW4PetVe6BdFYjxFeAjCrqofPYtdbRTnJ4xjk%3D&reserved=0>
>>>>>>>>
>>>>>>>> thanks
>>>>>>>>
>>>>>>>>
>>>>>>>> 2018-01-15 3:56 GMT+01:00 Carlos Cruz <ca...@nbtbizcapital.com>:
>>>>>>>>
>>>>>>>>> I have a lot of experience with Flex remoting and BlazeDS with
>>>>>>>>> Java, but with FlexJS and Royale I have none, but extrapolating from some
>>>>>>>>> JS tests I've done with AMF at this line: amfTestService.send("get
>>>>>>>>> ShippingMethods", []); you have to call a class in gateway.php
>>>>>>>>> and a method. Your request needs at least 3 properties.
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> I'm also assuming your JS file and gateway.php are in the same
>>>>>>>>> domain and same port (this gave me problems).
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Take what I said regarding my experience with FlexJS and Royale
>>>>>>>>> into account.
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Carlos
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> *From:* Fréderic Cox [mailto:coxfrederic@gmail.com]
>>>>>>>>> *Sent:* Sunday, January 14, 2018 4:01 PM
>>>>>>>>>
>>>>>>>>> *To:* users@royale.apache.org
>>>>>>>>> *Subject:* Re: RemoteObject
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Script tag was stripped from the post:
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> import org.apache.royale.events.MouseEvent;
>>>>>>>>>
>>>>>>>>>                      import org.apache.royale.net.events.F
>>>>>>>>> aultEvent;
>>>>>>>>>
>>>>>>>>>                      import org.apache.royale.net.events.R
>>>>>>>>> esultEvent;
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>                      protectedfunction
>>>>>>>>> textbutton_clickHandler(event:org.apache.royale.events.Mouse
>>>>>>>>> Event):void
>>>>>>>>>
>>>>>>>>>                      {
>>>>>>>>>
>>>>>>>>>                            statusLabel.text = "calling.......";
>>>>>>>>>
>>>>>>>>>                            amfTestService.addEventListener("fault",
>>>>>>>>> amfTestService_faultHandler);
>>>>>>>>>
>>>>>>>>>                            amfTestService.addEventListener(
>>>>>>>>> "result", amfTestService_resultHandler);
>>>>>>>>>
>>>>>>>>>                            amfTestService.send("getShippi
>>>>>>>>> ngMethods", []);
>>>>>>>>>
>>>>>>>>>                      }
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>                      protectedfunction
>>>>>>>>> amfTestService_faultHandler(event:FaultEvent):void
>>>>>>>>>
>>>>>>>>>                      {
>>>>>>>>>
>>>>>>>>>                            statusLabel.text = "error!";
>>>>>>>>>
>>>>>>>>>                      }
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>                      protectedfunction
>>>>>>>>> amfTestService_resultHandler(event:ResultEvent):void
>>>>>>>>>
>>>>>>>>>                      {
>>>>>>>>>
>>>>>>>>>                            statusLabel.text = "result!";
>>>>>>>>>
>>>>>>>>>                      }
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> none of the events are triggered ..URL is
>>>>>>>>> http://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=EJDBQBL83yBhDn%2BWWgCCVyw0N3tnakhZ7UdEt4JFNaY%3D&reserved=0>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On Fri, Jan 12, 2018 at 4:55 AM, Carlos Cruz <
>>>>>>>>> carlos@nbtbizcapital.com> wrote:
>>>>>>>>>
>>>>>>>>> I may be blind (and or ignorant as I'm more familiar with Flex)
>>>>>>>>> but where
>>>>>>>>> are you sending an AMF request? I don't see any code that sends a
>>>>>>>>> request to
>>>>>>>>> a service and invokes method.
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> -----Original Message-----
>>>>>>>>> From: coxfrederic [mailto:coxfrederic@gmail.com]
>>>>>>>>> Sent: Thursday, January 11, 2018 9:09 PM
>>>>>>>>> To: users@royale.apache.org
>>>>>>>>> Subject: Re: RemoteObject
>>>>>>>>>
>>>>>>>>> <?xml version="1.0" encoding="utf-8"?>
>>>>>>>>>
>>>>>>>>> <js:Application xmlns:fx="http://ns.adobe.com/mxml/2009
>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.adobe.com%2Fmxml%2F2009&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7cSxKCospCIpbkKY4F%2Fp5lsHBH%2BPFp5Vny2ftXWmL5A%3D&reserved=0>
>>>>>>>>> "
>>>>>>>>>                    xmlns:js="library://ns.apache.org/royale/basic
>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.apache.org%2Froyale%2Fbasic&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=D%2FBslvPtV9pNNjpoS4KCQlYHB8ArUYEIXCXuAVoNgYM%3D&reserved=0>"
>>>>>>>>> >
>>>>>>>>>         <fx:Script>
>>>>>>>>>
>>>>>>>>>         </fx:Script>
>>>>>>>>>     <js:valuesImpl>
>>>>>>>>>         <js:SimpleCSSValuesImpl />
>>>>>>>>>     </js:valuesImpl>
>>>>>>>>>
>>>>>>>>>         <js:beads>
>>>>>>>>>                 <js:ClassAliasBead />
>>>>>>>>>                 <js:RemoteObject id="amfTestService"
>>>>>>>>>
>>>>>>>>> endPoint="http://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=EJDBQBL83yBhDn%2BWWgCCVyw0N3tnakhZ7UdEt4JFNaY%3D&reserved=0>
>>>>>>>>> "
>>>>>>>>>                                                  destination="Meta"
>>>>>>>>> source="Meta" />
>>>>>>>>>         </js:beads>
>>>>>>>>>
>>>>>>>>>     <js:initialView>
>>>>>>>>>         <js:View>
>>>>>>>>>                         <js:VGroup>
>>>>>>>>>                                 <js:Label id="statusLabel"
>>>>>>>>> text="Hello
>>>>>>>>> World!" />
>>>>>>>>>                                 <js:TextButton text="Get AMF data"
>>>>>>>>> click="textbutton_clickHandler(event)" />
>>>>>>>>>                         </js:VGroup>
>>>>>>>>>         </js:View>
>>>>>>>>>     </js:initialView>
>>>>>>>>> </js:Application>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Any idea why I'm not getting a fault nor success event on this?
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> Sent from: http://apache-royale-users.20374.n8.nabble.com/
>>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fapache-royale-users.20374.n8.nabble.com%2F&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=xvY8nK1QKlWduh6p5x8y19jm%2Br60PSFVlNdi6TRsPmw%3D&reserved=0>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> --
>>>>>>>> Carlos Rovira
>>>>>>>> http://about.me/carlosrovira
>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fabout.me%2Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=55MSUXBM2zE5U0csgV1harcuXvKyZ2gd%2BO%2FmD7hjJ50%3D&reserved=0>
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>>
>>>>>>> Piotr Zarzycki
>>>>>>>
>>>>>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=NG2rkkxhfc7MTSVRqHzEmHL8HuUpvXI72B9nkW2QfdU%3D&reserved=0>*
>>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> Carlos Rovira
>>>>>> http://about.me/carlosrovira
>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fabout.me%2Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=55MSUXBM2zE5U0csgV1harcuXvKyZ2gd%2BO%2FmD7hjJ50%3D&reserved=0>
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>> --
>>>>>
>>>>> Piotr Zarzycki
>>>>>
>>>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=NG2rkkxhfc7MTSVRqHzEmHL8HuUpvXI72B9nkW2QfdU%3D&reserved=0>*
>>>>>
>>>>
>>>>
>>>
>>>
>>> --
>>>
>>> Piotr Zarzycki
>>>
>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=NG2rkkxhfc7MTSVRqHzEmHL8HuUpvXI72B9nkW2QfdU%3D&reserved=0>*
>>>
>>
>>
>


-- 
Carlos Rovira
http://about.me/carlosrovira

Re: RemoteObject

Posted by Fréderic Cox <co...@gmail.com>.
Hi Alex,

I created https://github.com/apache/royale-asjs/issues/119, hope that is in
the correct place and with more readable mark-up.

Regards,

Fréderic

On Thu, Feb 15, 2018 at 8:57 PM, Alex Harui <ah...@adobe.com> wrote:

> Hi Frederic,
>
> Where is this output you posted coming from, a network monitor?  It was
> too hard to read, so please create a bug report on GitHub and post it there.
>
> You might be able to use a network monitor to compare what Flex sent vs
> what Royale is sending.  What does your Flex usage of RemoteObject look
> like?
>
> HTH,
> -Alex
>
> From: Fréderic Cox <co...@gmail.com>
> Reply-To: "users@royale.apache.org" <us...@royale.apache.org>
> Date: Thursday, February 15, 2018 at 5:09 AM
> To: "users@royale.apache.org" <us...@royale.apache.org>
> Subject: Re: RemoteObject
>
> Hi Piotr,
>
> Thanks, I installed the extension and now I'm not getting the CORS error
> anymore.
> I'm not getting any fault or result event triggered either....
>
> The endPoint set is
> https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php
> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fclients.cityfashion.dev.exuvis.com%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=67VMfKVGZo%2BarMstlt%2BZbX5OdTomYDQNSgM07ycK%2Bvc%3D&reserved=0>
>
> This is correct, right? (I use this endpoint in Flex and that works fine)
>
>
>    1. Request URL:
>       https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php
>       <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fclients.cityfashion.dev.exuvis.com%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=67VMfKVGZo%2BarMstlt%2BZbX5OdTomYDQNSgM07ycK%2Bvc%3D&reserved=0>
>       2. Request Method:
>       OPTIONS
>       3. Status Code:
>       200 OK
>       4. Remote Address:
>       188.93.153.101:443
>       <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2F188.93.153.101%3A443&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=UWqG%2BqQTcL1fTnck9i5BPXmrn3ZlgRf8XCPpQ8EcJrE%3D&reserved=0>
>       5. Referrer Policy:
>       no-referrer-when-downgrade
>       1. Response Headersview source
>       1. Connection:
>       keep-alive
>       2. Content-Encoding:
>       gzip
>       3. Content-Length:
>       286
>       4. Content-Type:
>       text/html; charset=UTF-8
>       5. Date:
>       Thu, 15 Feb 2018 13:08:17 GMT
>       6. Server:
>       nginx
>       7. Vary:
>       Accept-Encoding
>       2. Request Headersview source
>       1. Accept:
>       */*
>       2. Accept-Encoding:
>       gzip, deflate, br
>       3. Accept-Language:
>       en-GB,en-US;q=0.9,en;q=0.8
>       4. Access-Control-Request-Headers:
>       content-type
>       5. Access-Control-Request-Method:
>       POST
>       6. Connection:
>       keep-alive
>       7. Host:
>       clients.cityfashion.dev.exuvis.com
>       <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fclients.cityfashion.dev.exuvis.com&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=%2BiTohXW1uaTpydtAlGWa0leTvEQKK2Wg6XtN%2FqQ73%2F0%3D&reserved=0>
>       8. Origin:
>       null
>       9. User-Agent:
>       Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_3) AppleWebKit/537.36
>       (KHTML, like Gecko) Chrome/64.0.3282.167 Safari/537.36
>
> Response is:
>
> <p>amfphp and this gateway are installed correctly. You may now connect to
> this gateway from Flash.</p><p>Note: If you're reading an old tutorial, it
> will tell you that you should see a download window instead of this
> message. This confused people so this is the new behaviour starting from
> amfphp 1.2.</p><p><a href='http://www.amfphp.org/docs
> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.amfphp.org%2Fdocs&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=%2FGtfS6iuQCrcoifQ5pUOXPJ0JJZcOQaMyYsscjKzA9I%3D&reserved=0>'>View
> the amfphp documentation</p><p><a href='browser'>Load the service
> browser</a></p><pre>
>
> Should I target a specific file with the JS version? Should the endPoint
> be different?
>
> On Thu, Feb 15, 2018 at 12:07 PM, Piotr Zarzycki <
> piotrzarzycki21@gmail.com> wrote:
>
>> Frederic,
>>
>> It looks like it is not problem with framework, but rather CORS issue.
>> Maybe try to install this plugin [1] and add to the list your url.
>>
>> [1] https://chrome.google.com/webstore/detail/allow-control-
>> allow-origi/nlfbmbojpeacfghkpbjhddihlkkiljbi?hl=en
>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fchrome.google.com%2Fwebstore%2Fdetail%2Fallow-control-allow-origi%2Fnlfbmbojpeacfghkpbjhddihlkkiljbi%3Fhl%3Den&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=CbZH3KQcH0oGU%2FbnBtyVp%2B9zeqDEUcK9Y6UFd0BIESM%3D&reserved=0>
>>
>> Piotr
>>
>> 2018-02-15 12:04 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>>
>>> For me it is still not working in latest release 0.9.1. I based my
>>> example on the example in the SDK.
>>>
>>> <?xml version="1.0" encoding="utf-8"?>
>>> <js:Applicationxmlns:fx="http://ns.adobe.com/mxml/2009
>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.adobe.com%2Fmxml%2F2009&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7cSxKCospCIpbkKY4F%2Fp5lsHBH%2BPFp5Vny2ftXWmL5A%3D&reserved=0>
>>> "
>>> xmlns:js="library://ns.apache.org/royale/basic
>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.apache.org%2Froyale%2Fbasic&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=D%2FBslvPtV9pNNjpoS4KCQlYHB8ArUYEIXCXuAVoNgYM%3D&reserved=0>
>>> "applicationComplete="applicationCompleteHandler(event);">
>>>
>>>     <fx:Script>
>>>         <![CDATA[
>>>             import org.apache.royale.net
>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Forg.apache.royale.net&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=ATrXbo2PLqz1dNeyvxVu89zy3yaKPxwIwQm9tSG7ybs%3D&reserved=0>
>>> .RemoteObject;
>>>             import org.apache.royale.net.events.FaultEvent;
>>>             import org.apache.royale.net.events.ResultEvent;
>>>
>>>             privatefunctionapplicationCompleteHandler(evt:Event):void{
>>>                 testLabel.text = "Requesting from AMF";
>>>                 service.send("getPackages", null);
>>>             }
>>>
>>>             privatefunctionamfFaultHandler(evt:FaultEvent):void{
>>>                 testLabel.text = "Fault in calling AMF";
>>>             }
>>>
>>>             privatefunctionamfResultHandler(evt:ResultEvent):void{
>>>                 testLabel.text = "Result received from AMF";
>>>             }
>>>         ]]>
>>>     </fx:Script>
>>>
>>> <js:valuesImpl>
>>> <js:SimpleCSSValuesImpl />
>>> </js:valuesImpl>
>>>
>>>    <js:beads>
>>> <js:ClassAliasBead />
>>> <js:RemoteObjectid="service"result="amfResultHandler(event)"fault=
>>> "amfFaultHandler(event)"
>>> endPoint = "https://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=mARoGAlKZYBWmNOBwqTpTRYkqG%2Fk0cvrHwR5kgbfNFY%3D&reserved=0>
>>> "
>>> destination = "Meta"
>>> source = "Meta"/>
>>> </js:beads>
>>>
>>> <js:initialView>
>>> <js:View>
>>> <js:Labelid="testLabel" />
>>> </js:View>
>>> </js:initialView>
>>> </js:Application>
>>>
>>>
>>> It is not working and showing the following error in the browser:
>>>
>>> Failed to load https://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=mARoGAlKZYBWmNOBwqTpTRYkqG%2Fk0cvrHwR5kgbfNFY%3D&reserved=0>:
>>> Response to preflight request doesn't pass access control check: No
>>> 'Access-Control-Allow-Origin' header is present on the requested resource.
>>> Origin 'http://localhost' is therefore not allowed access.
>>> Language.js:238destination fault handler
>>>
>>>    1. {code: -1004, message: "Invalid response type.", detail: "Invalid
>>>    XMLHttpRequest response status or type.", data: null}
>>>       1. code:-1004
>>>       2. data:null
>>>       3. detail:"Invalid XMLHttpRequest response status or type."
>>>       4. message:"Invalid response type."
>>>       5. __proto__:Object
>>>
>>>
>>>
>>>
>>> It is able to compile and run regardless of the errors in compile log:
>>>
>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>> println
>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>> he/royale/reflection/AccessorDefinition.js:12: ERROR - required
>>> "org.apache.royale.reflection.TypeDefinition" namespace not provided yet
>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>
>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>> println
>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>> he/royale/reflection/AccessorDefinition.js:13: ERROR - required
>>> "org.apache.royale.reflection.VariableDefinition" namespace not
>>> provided yet
>>> goog.require('org.apache.royale.reflection.VariableDefinition');
>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>
>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>> println
>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>> he/royale/reflection/MethodDefinition.js:14: ERROR - required
>>> "org.apache.royale.reflection.TypeDefinition" namespace not provided yet
>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>
>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>> println
>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>> he/royale/reflection/ParameterDefinition.js:13: ERROR- required
>>> "org.apache.royale.reflection.TypeDefinition" namespace not provided yet
>>> goog.require('org.apache.royale.reflection.TypeDefinition');
>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>
>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>> println
>>> SEVERE: /Users/frederic/Desktop/Personal/Web
>>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>>> he/royale/reflection/TypeDefinition.js:15: ERROR - required
>>> "org.apache.royale.reflection.VariableDefinition" namespace not
>>> provided yet
>>> goog.require('org.apache.royale.reflection.VariableDefinition');
>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>
>>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>>> printSummary
>>> WARNING: 5 error(s), 0 warning(s)
>>> The project 'HelloRoyale' has been successfully compiled and optimized.
>>> 4.566387 seconds
>>>
>>>
>>> On Mon, Jan 15, 2018 at 7:38 PM, Piotr Zarzycki <
>>> piotrzarzycki21@gmail.com> wrote:
>>>
>>>> Carlos,
>>>>
>>>> No problem. I have also couple of huge things related to Royale to do
>>>> before my hand gets dirty with AMF! :) Unless someone urgently will needed.
>>>> :)
>>>>
>>>> Thanks, Piotr
>>>>
>>>> 2018-01-15 19:27 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>>>>
>>>>> Hi Piotr,
>>>>> I'll put this on my to do list, but have to do some things first.
>>>>> thanks
>>>>>
>>>>> 2018-01-15 9:26 GMT+01:00 Piotr Zarzycki <pi...@gmail.com>:
>>>>>
>>>>>> Hi Carlos,
>>>>>>
>>>>>> Can you describe more how to setup those examples ? Could you add to
>>>>>> RemoteObjectAMFTest README.md file where you describe steps. I would like
>>>>>> to have AMF on my list for tests and improvements. Whenever I look into
>>>>>> that I don't know how to proceed with it.
>>>>>>
>>>>>> Thanks, Piotr
>>>>>>
>>>>>> 2018-01-15 9:21 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>>>>>>
>>>>>>> Hi,
>>>>>>>
>>>>>>> there's an example that we get it working nicely at:
>>>>>>>
>>>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/
>>>>>>> royale/RemoteObjectAMFTest
>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Ftree%2Fdevelop%2Fexamples%2Froyale%2FRemoteObjectAMFTest&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7kdc48rEQiaI4Qp%2BBdfBcGPxddZIYrTUXrQ%2BN2u4tto%3D&reserved=0>
>>>>>>>
>>>>>>> you can use that as a starting point for your test
>>>>>>>
>>>>>>> As well a java web app that is used along that royale client example
>>>>>>> is at:
>>>>>>>
>>>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/amf
>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Ftree%2Fdevelop%2Fexamples%2Famf&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=PW4DYIeW4PetVe6BdFYjxFeAjCrqofPYtdbRTnJ4xjk%3D&reserved=0>
>>>>>>>
>>>>>>> thanks
>>>>>>>
>>>>>>>
>>>>>>> 2018-01-15 3:56 GMT+01:00 Carlos Cruz <ca...@nbtbizcapital.com>:
>>>>>>>
>>>>>>>> I have a lot of experience with Flex remoting and BlazeDS with
>>>>>>>> Java, but with FlexJS and Royale I have none, but extrapolating from some
>>>>>>>> JS tests I've done with AMF at this line: amfTestService.send("get
>>>>>>>> ShippingMethods", []); you have to call a class in gateway.php and
>>>>>>>> a method. Your request needs at least 3 properties.
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> I'm also assuming your JS file and gateway.php are in the same
>>>>>>>> domain and same port (this gave me problems).
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> Take what I said regarding my experience with FlexJS and Royale
>>>>>>>> into account.
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> Carlos
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> *From:* Fréderic Cox [mailto:coxfrederic@gmail.com]
>>>>>>>> *Sent:* Sunday, January 14, 2018 4:01 PM
>>>>>>>>
>>>>>>>> *To:* users@royale.apache.org
>>>>>>>> *Subject:* Re: RemoteObject
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> Script tag was stripped from the post:
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> import org.apache.royale.events.MouseEvent;
>>>>>>>>
>>>>>>>>                      import org.apache.royale.net.events.F
>>>>>>>> aultEvent;
>>>>>>>>
>>>>>>>>                      import org.apache.royale.net.events.R
>>>>>>>> esultEvent;
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>                      protectedfunction
>>>>>>>> textbutton_clickHandler(event:org.apache.royale.events.MouseEvent):
>>>>>>>> void
>>>>>>>>
>>>>>>>>                      {
>>>>>>>>
>>>>>>>>                            statusLabel.text = "calling.......";
>>>>>>>>
>>>>>>>>                            amfTestService.addEventListener("fault",
>>>>>>>> amfTestService_faultHandler);
>>>>>>>>
>>>>>>>>                            amfTestService.addEventListener("result",
>>>>>>>> amfTestService_resultHandler);
>>>>>>>>
>>>>>>>>                            amfTestService.send("getShippingMethods",
>>>>>>>> []);
>>>>>>>>
>>>>>>>>                      }
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>                      protectedfunction
>>>>>>>> amfTestService_faultHandler(event:FaultEvent):void
>>>>>>>>
>>>>>>>>                      {
>>>>>>>>
>>>>>>>>                            statusLabel.text = "error!";
>>>>>>>>
>>>>>>>>                      }
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>                      protectedfunction
>>>>>>>> amfTestService_resultHandler(event:ResultEvent):void
>>>>>>>>
>>>>>>>>                      {
>>>>>>>>
>>>>>>>>                            statusLabel.text = "result!";
>>>>>>>>
>>>>>>>>                      }
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> none of the events are triggered ..URL is
>>>>>>>> http://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=EJDBQBL83yBhDn%2BWWgCCVyw0N3tnakhZ7UdEt4JFNaY%3D&reserved=0>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> On Fri, Jan 12, 2018 at 4:55 AM, Carlos Cruz <
>>>>>>>> carlos@nbtbizcapital.com> wrote:
>>>>>>>>
>>>>>>>> I may be blind (and or ignorant as I'm more familiar with Flex) but
>>>>>>>> where
>>>>>>>> are you sending an AMF request? I don't see any code that sends a
>>>>>>>> request to
>>>>>>>> a service and invokes method.
>>>>>>>>
>>>>>>>>
>>>>>>>> -----Original Message-----
>>>>>>>> From: coxfrederic [mailto:coxfrederic@gmail.com]
>>>>>>>> Sent: Thursday, January 11, 2018 9:09 PM
>>>>>>>> To: users@royale.apache.org
>>>>>>>> Subject: Re: RemoteObject
>>>>>>>>
>>>>>>>> <?xml version="1.0" encoding="utf-8"?>
>>>>>>>>
>>>>>>>> <js:Application xmlns:fx="http://ns.adobe.com/mxml/2009
>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.adobe.com%2Fmxml%2F2009&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7cSxKCospCIpbkKY4F%2Fp5lsHBH%2BPFp5Vny2ftXWmL5A%3D&reserved=0>
>>>>>>>> "
>>>>>>>>                    xmlns:js="library://ns.apache.org/royale/basic
>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.apache.org%2Froyale%2Fbasic&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=D%2FBslvPtV9pNNjpoS4KCQlYHB8ArUYEIXCXuAVoNgYM%3D&reserved=0>"
>>>>>>>> >
>>>>>>>>         <fx:Script>
>>>>>>>>
>>>>>>>>         </fx:Script>
>>>>>>>>     <js:valuesImpl>
>>>>>>>>         <js:SimpleCSSValuesImpl />
>>>>>>>>     </js:valuesImpl>
>>>>>>>>
>>>>>>>>         <js:beads>
>>>>>>>>                 <js:ClassAliasBead />
>>>>>>>>                 <js:RemoteObject id="amfTestService"
>>>>>>>>
>>>>>>>> endPoint="http://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=EJDBQBL83yBhDn%2BWWgCCVyw0N3tnakhZ7UdEt4JFNaY%3D&reserved=0>
>>>>>>>> "
>>>>>>>>                                                  destination="Meta"
>>>>>>>> source="Meta" />
>>>>>>>>         </js:beads>
>>>>>>>>
>>>>>>>>     <js:initialView>
>>>>>>>>         <js:View>
>>>>>>>>                         <js:VGroup>
>>>>>>>>                                 <js:Label id="statusLabel"
>>>>>>>> text="Hello
>>>>>>>> World!" />
>>>>>>>>                                 <js:TextButton text="Get AMF data"
>>>>>>>> click="textbutton_clickHandler(event)" />
>>>>>>>>                         </js:VGroup>
>>>>>>>>         </js:View>
>>>>>>>>     </js:initialView>
>>>>>>>> </js:Application>
>>>>>>>>
>>>>>>>>
>>>>>>>> Any idea why I'm not getting a fault nor success event on this?
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> --
>>>>>>>> Sent from: http://apache-royale-users.20374.n8.nabble.com/
>>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fapache-royale-users.20374.n8.nabble.com%2F&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=xvY8nK1QKlWduh6p5x8y19jm%2Br60PSFVlNdi6TRsPmw%3D&reserved=0>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> Carlos Rovira
>>>>>>> http://about.me/carlosrovira
>>>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fabout.me%2Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=55MSUXBM2zE5U0csgV1harcuXvKyZ2gd%2BO%2FmD7hjJ50%3D&reserved=0>
>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>>
>>>>>> Piotr Zarzycki
>>>>>>
>>>>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=NG2rkkxhfc7MTSVRqHzEmHL8HuUpvXI72B9nkW2QfdU%3D&reserved=0>*
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Carlos Rovira
>>>>> http://about.me/carlosrovira
>>>>> <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fabout.me%2Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=55MSUXBM2zE5U0csgV1harcuXvKyZ2gd%2BO%2FmD7hjJ50%3D&reserved=0>
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>>
>>>> Piotr Zarzycki
>>>>
>>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=NG2rkkxhfc7MTSVRqHzEmHL8HuUpvXI72B9nkW2QfdU%3D&reserved=0>*
>>>>
>>>
>>>
>>
>>
>> --
>>
>> Piotr Zarzycki
>>
>> Patreon: *https://www.patreon.com/piotrzarzycki
>> <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=NG2rkkxhfc7MTSVRqHzEmHL8HuUpvXI72B9nkW2QfdU%3D&reserved=0>*
>>
>
>

Re: RemoteObject

Posted by Alex Harui <ah...@adobe.com>.
Hi Frederic,

Where is this output you posted coming from, a network monitor?  It was too hard to read, so please create a bug report on GitHub and post it there.

You might be able to use a network monitor to compare what Flex sent vs what Royale is sending.  What does your Flex usage of RemoteObject look like?

HTH,
-Alex

From: Fréderic Cox <co...@gmail.com>>
Reply-To: "users@royale.apache.org<ma...@royale.apache.org>" <us...@royale.apache.org>>
Date: Thursday, February 15, 2018 at 5:09 AM
To: "users@royale.apache.org<ma...@royale.apache.org>" <us...@royale.apache.org>>
Subject: Re: RemoteObject

Hi Piotr,

Thanks, I installed the extension and now I'm not getting the CORS error anymore.
I'm not getting any fault or result event triggered either....

The endPoint set is
https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fclients.cityfashion.dev.exuvis.com%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=67VMfKVGZo%2BarMstlt%2BZbX5OdTomYDQNSgM07ycK%2Bvc%3D&reserved=0>

This is correct, right? (I use this endpoint in Flex and that works fine)


     *
Request URL:
https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fclients.cityfashion.dev.exuvis.com%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=67VMfKVGZo%2BarMstlt%2BZbX5OdTomYDQNSgM07ycK%2Bvc%3D&reserved=0>
     *
Request Method:
OPTIONS
     *
Status Code:
200 OK
     *
Remote Address:
188.93.153.101:443<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2F188.93.153.101%3A443&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=UWqG%2BqQTcL1fTnck9i5BPXmrn3ZlgRf8XCPpQ8EcJrE%3D&reserved=0>
     *
Referrer Policy:
no-referrer-when-downgrade
  1.  Response Headersview source
     *
Connection:
keep-alive
     *
Content-Encoding:
gzip
     *
Content-Length:
286
     *
Content-Type:
text/html; charset=UTF-8
     *
Date:
Thu, 15 Feb 2018 13:08:17 GMT
     *
Server:
nginx
     *
Vary:
Accept-Encoding
  2.  Request Headersview source
     *
Accept:
*/*
     *
Accept-Encoding:
gzip, deflate, br
     *
Accept-Language:
en-GB,en-US;q=0.9,en;q=0.8
     *
Access-Control-Request-Headers:
content-type
     *
Access-Control-Request-Method:
POST
     *
Connection:
keep-alive
     *
Host:
clients.cityfashion.dev.exuvis.com<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fclients.cityfashion.dev.exuvis.com&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=%2BiTohXW1uaTpydtAlGWa0leTvEQKK2Wg6XtN%2FqQ73%2F0%3D&reserved=0>
     *
Origin:
null
     *
User-Agent:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_3) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.167 Safari/537.36

Response is:

<p>amfphp and this gateway are installed correctly. You may now connect to this gateway from Flash.</p><p>Note: If you're reading an old tutorial, it will tell you that you should see a download window instead of this message. This confused people so this is the new behaviour starting from amfphp 1.2.</p><p><a href='http://www.amfphp.org/docs<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.amfphp.org%2Fdocs&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=%2FGtfS6iuQCrcoifQ5pUOXPJ0JJZcOQaMyYsscjKzA9I%3D&reserved=0>'>View the amfphp documentation</p><p><a href='browser'>Load the service browser</a></p><pre>

Should I target a specific file with the JS version? Should the endPoint be different?

On Thu, Feb 15, 2018 at 12:07 PM, Piotr Zarzycki <pi...@gmail.com>> wrote:
Frederic,

It looks like it is not problem with framework, but rather CORS issue. Maybe try to install this plugin [1] and add to the list your url.

[1] https://chrome.google.com/webstore/detail/allow-control-allow-origi/nlfbmbojpeacfghkpbjhddihlkkiljbi?hl=en<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fchrome.google.com%2Fwebstore%2Fdetail%2Fallow-control-allow-origi%2Fnlfbmbojpeacfghkpbjhddihlkkiljbi%3Fhl%3Den&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=CbZH3KQcH0oGU%2FbnBtyVp%2B9zeqDEUcK9Y6UFd0BIESM%3D&reserved=0>

Piotr

2018-02-15 12:04 GMT+01:00 Fréderic Cox <co...@gmail.com>>:
For me it is still not working in latest release 0.9.1. I based my example on the example in the SDK.

<?xml version="1.0" encoding="utf-8"?>
<js:Applicationxmlns:fx="http://ns.adobe.com/mxml/2009<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.adobe.com%2Fmxml%2F2009&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7cSxKCospCIpbkKY4F%2Fp5lsHBH%2BPFp5Vny2ftXWmL5A%3D&reserved=0>"
xmlns:js="library://ns.apache.org/royale/basic<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.apache.org%2Froyale%2Fbasic&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=D%2FBslvPtV9pNNjpoS4KCQlYHB8ArUYEIXCXuAVoNgYM%3D&reserved=0>"applicationComplete="applicationCompleteHandler(event);">

    <fx:Script>
        <![CDATA[
            import org.apache.royale.net<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Forg.apache.royale.net&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=ATrXbo2PLqz1dNeyvxVu89zy3yaKPxwIwQm9tSG7ybs%3D&reserved=0>.RemoteObject;
            import org.apache.royale.net.events.FaultEvent;
            import org.apache.royale.net.events.ResultEvent;

            privatefunctionapplicationCompleteHandler(evt:Event):void{
                testLabel.text = "Requesting from AMF";
                service.send("getPackages", null);
            }

            privatefunctionamfFaultHandler(evt:FaultEvent):void{
                testLabel.text = "Fault in calling AMF";
            }

            privatefunctionamfResultHandler(evt:ResultEvent):void{
                testLabel.text = "Result received from AMF";
            }
        ]]>
    </fx:Script>

<js:valuesImpl>
<js:SimpleCSSValuesImpl />
</js:valuesImpl>

   <js:beads>
<js:ClassAliasBead />
<js:RemoteObjectid="service"result="amfResultHandler(event)"fault="amfFaultHandler(event)"
endPoint = "https://winkelbeheer.cityfashion.be/amfphp/gateway.php<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=mARoGAlKZYBWmNOBwqTpTRYkqG%2Fk0cvrHwR5kgbfNFY%3D&reserved=0>"
destination = "Meta"
source = "Meta"/>
</js:beads>

<js:initialView>
<js:View>
<js:Labelid="testLabel" />
</js:View>
</js:initialView>
</js:Application>


It is not working and showing the following error in the browser:

Failed to load https://winkelbeheer.cityfashion.be/amfphp/gateway.php<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=mARoGAlKZYBWmNOBwqTpTRYkqG%2Fk0cvrHwR5kgbfNFY%3D&reserved=0>: Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://localhost' is therefore not allowed access.
Language.js:238destination fault handler

  1.  {code: -1004, message: "Invalid response type.", detail: "Invalid XMLHttpRequest response status or type.", data: null}
     *   code:-1004
     *   data:null
     *   detail:"Invalid XMLHttpRequest response status or type."
     *   message:"Invalid response type."
     *   __proto__:Object



It is able to compile and run regardless of the errors in compile log:

Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager println
SEVERE: /Users/frederic/Desktop/Personal/Web Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apache/royale/reflection/AccessorDefinition.js:12: ERROR - required "org.apache.royale.reflection.TypeDefinition" namespace not provided yet
goog.require('org.apache.royale.reflection.TypeDefinition');
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager println
SEVERE: /Users/frederic/Desktop/Personal/Web Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apache/royale/reflection/AccessorDefinition.js:13: ERROR - required "org.apache.royale.reflection.VariableDefinition" namespace not provided yet
goog.require('org.apache.royale.reflection.VariableDefinition');
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager println
SEVERE: /Users/frederic/Desktop/Personal/Web Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apache/royale/reflection/MethodDefinition.js:14: ERROR - required "org.apache.royale.reflection.TypeDefinition" namespace not provided yet
goog.require('org.apache.royale.reflection.TypeDefinition');
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager println
SEVERE: /Users/frederic/Desktop/Personal/Web Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apache/royale/reflection/ParameterDefinition.js:13: ERROR- required "org.apache.royale.reflection.TypeDefinition" namespace not provided yet
goog.require('org.apache.royale.reflection.TypeDefinition');
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager println
SEVERE: /Users/frederic/Desktop/Personal/Web Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apache/royale/reflection/TypeDefinition.js:15: ERROR - required "org.apache.royale.reflection.VariableDefinition" namespace not provided yet
goog.require('org.apache.royale.reflection.VariableDefinition');
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager printSummary
WARNING: 5 error(s), 0 warning(s)
The project 'HelloRoyale' has been successfully compiled and optimized.
4.566387 seconds


On Mon, Jan 15, 2018 at 7:38 PM, Piotr Zarzycki <pi...@gmail.com>> wrote:
Carlos,

No problem. I have also couple of huge things related to Royale to do before my hand gets dirty with AMF! :) Unless someone urgently will needed. :)

Thanks, Piotr

2018-01-15 19:27 GMT+01:00 Carlos Rovira <ca...@apache.org>>:
Hi Piotr,
I'll put this on my to do list, but have to do some things first.
thanks

2018-01-15 9:26 GMT+01:00 Piotr Zarzycki <pi...@gmail.com>>:
Hi Carlos,

Can you describe more how to setup those examples ? Could you add to RemoteObjectAMFTest README.md file where you describe steps. I would like to have AMF on my list for tests and improvements. Whenever I look into that I don't know how to proceed with it.

Thanks, Piotr

2018-01-15 9:21 GMT+01:00 Carlos Rovira <ca...@apache.org>>:
Hi,

there's an example that we get it working nicely at:

https://github.com/apache/royale-asjs/tree/develop/examples/royale/RemoteObjectAMFTest<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Ftree%2Fdevelop%2Fexamples%2Froyale%2FRemoteObjectAMFTest&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7kdc48rEQiaI4Qp%2BBdfBcGPxddZIYrTUXrQ%2BN2u4tto%3D&reserved=0>

you can use that as a starting point for your test

As well a java web app that is used along that royale client example is at:

https://github.com/apache/royale-asjs/tree/develop/examples/amf<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Ftree%2Fdevelop%2Fexamples%2Famf&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=PW4DYIeW4PetVe6BdFYjxFeAjCrqofPYtdbRTnJ4xjk%3D&reserved=0>

thanks


2018-01-15 3:56 GMT+01:00 Carlos Cruz <ca...@nbtbizcapital.com>>:
I have a lot of experience with Flex remoting and BlazeDS with Java, but with FlexJS and Royale I have none, but extrapolating from some JS tests I've done with AMF at this line: amfTestService.send("getShippingMethods", []); you have to call a class in gateway.php and a method. Your request needs at least 3 properties.

I'm also assuming your JS file and gateway.php are in the same domain and same port (this gave me problems).

Take what I said regarding my experience with FlexJS and Royale into account.

Carlos


From: Fréderic Cox [mailto:coxfrederic@gmail.com<ma...@gmail.com>]
Sent: Sunday, January 14, 2018 4:01 PM

To: users@royale.apache.org<ma...@royale.apache.org>
Subject: Re: RemoteObject

Script tag was stripped from the post:


import org.apache.royale.events.MouseEvent;

                     import org.apache.royale.net.events.FaultEvent;

                     import org.apache.royale.net.events.ResultEvent;



                     protectedfunction textbutton_clickHandler(event:org.apache.royale.events.MouseEvent):void

                     {

                           statusLabel.text = "calling.......";

                           amfTestService.addEventListener("fault", amfTestService_faultHandler);

                           amfTestService.addEventListener("result", amfTestService_resultHandler);

                           amfTestService.send("getShippingMethods", []);

                     }



                     protectedfunction amfTestService_faultHandler(event:FaultEvent):void

                     {

                           statusLabel.text = "error!";

                     }



                     protectedfunction amfTestService_resultHandler(event:ResultEvent):void

                     {

                           statusLabel.text = "result!";

                     }



none of the events are triggered ..URL is http://winkelbeheer.cityfashion.be/amfphp/gateway.php<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=EJDBQBL83yBhDn%2BWWgCCVyw0N3tnakhZ7UdEt4JFNaY%3D&reserved=0>

On Fri, Jan 12, 2018 at 4:55 AM, Carlos Cruz <ca...@nbtbizcapital.com>> wrote:
I may be blind (and or ignorant as I'm more familiar with Flex) but where
are you sending an AMF request? I don't see any code that sends a request to
a service and invokes method.

-----Original Message-----
From: coxfrederic [mailto:coxfrederic@gmail.com<ma...@gmail.com>]
Sent: Thursday, January 11, 2018 9:09 PM
To: users@royale.apache.org<ma...@royale.apache.org>
Subject: Re: RemoteObject

<?xml version="1.0" encoding="utf-8"?>

<js:Application xmlns:fx="http://ns.adobe.com/mxml/2009<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.adobe.com%2Fmxml%2F2009&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=7cSxKCospCIpbkKY4F%2Fp5lsHBH%2BPFp5Vny2ftXWmL5A%3D&reserved=0>"
                   xmlns:js="library://ns.apache.org/royale/basic<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.apache.org%2Froyale%2Fbasic&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=D%2FBslvPtV9pNNjpoS4KCQlYHB8ArUYEIXCXuAVoNgYM%3D&reserved=0>" >
        <fx:Script>

        </fx:Script>
    <js:valuesImpl>
        <js:SimpleCSSValuesImpl />
    </js:valuesImpl>

        <js:beads>
                <js:ClassAliasBead />
                <js:RemoteObject id="amfTestService"

endPoint="http://winkelbeheer.cityfashion.be/amfphp/gateway.php<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwinkelbeheer.cityfashion.be%2Famfphp%2Fgateway.php&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=EJDBQBL83yBhDn%2BWWgCCVyw0N3tnakhZ7UdEt4JFNaY%3D&reserved=0>"
                                                 destination="Meta"
source="Meta" />
        </js:beads>

    <js:initialView>
        <js:View>
                        <js:VGroup>
                                <js:Label id="statusLabel" text="Hello
World!" />
                                <js:TextButton text="Get AMF data"
click="textbutton_clickHandler(event)" />
                        </js:VGroup>
        </js:View>
    </js:initialView>
</js:Application>


Any idea why I'm not getting a fault nor success event on this?



--
Sent from: http://apache-royale-users.20374.n8.nabble.com/<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fapache-royale-users.20374.n8.nabble.com%2F&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=xvY8nK1QKlWduh6p5x8y19jm%2Br60PSFVlNdi6TRsPmw%3D&reserved=0>




--
Carlos Rovira
http://about.me/carlosrovira<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fabout.me%2Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=55MSUXBM2zE5U0csgV1harcuXvKyZ2gd%2BO%2FmD7hjJ50%3D&reserved=0>




--

Piotr Zarzycki

Patreon: https://www.patreon.com/piotrzarzycki<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=NG2rkkxhfc7MTSVRqHzEmHL8HuUpvXI72B9nkW2QfdU%3D&reserved=0>



--
Carlos Rovira
http://about.me/carlosrovira<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fabout.me%2Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=55MSUXBM2zE5U0csgV1harcuXvKyZ2gd%2BO%2FmD7hjJ50%3D&reserved=0>




--

Piotr Zarzycki

Patreon: https://www.patreon.com/piotrzarzycki<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=NG2rkkxhfc7MTSVRqHzEmHL8HuUpvXI72B9nkW2QfdU%3D&reserved=0>




--

Piotr Zarzycki

Patreon: https://www.patreon.com/piotrzarzycki<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C3c68ff16e47d4dce093508d5747564fc%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636542969912666397&sdata=NG2rkkxhfc7MTSVRqHzEmHL8HuUpvXI72B9nkW2QfdU%3D&reserved=0>


Re: RemoteObject

Posted by Fréderic Cox <co...@gmail.com>.
Hi Piotr,

Thanks, I installed the extension and now I'm not getting the CORS error
anymore.
I'm not getting any fault or result event triggered either....

The endPoint set is
https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php

This is correct, right? (I use this endpoint in Flex and that works fine)


   1. Request URL:
      https://clients.cityfashion.dev.exuvis.com/amfphp/gateway.php
      2. Request Method:
      OPTIONS
      3. Status Code:
      200 OK
      4. Remote Address:
      188.93.153.101:443
      5. Referrer Policy:
      no-referrer-when-downgrade
      1. Response Headersview source
      1. Connection:
      keep-alive
      2. Content-Encoding:
      gzip
      3. Content-Length:
      286
      4. Content-Type:
      text/html; charset=UTF-8
      5. Date:
      Thu, 15 Feb 2018 13:08:17 GMT
      6. Server:
      nginx
      7. Vary:
      Accept-Encoding
      2. Request Headersview source
      1. Accept:
      */*
      2. Accept-Encoding:
      gzip, deflate, br
      3. Accept-Language:
      en-GB,en-US;q=0.9,en;q=0.8
      4. Access-Control-Request-Headers:
      content-type
      5. Access-Control-Request-Method:
      POST
      6. Connection:
      keep-alive
      7. Host:
      clients.cityfashion.dev.exuvis.com
      8. Origin:
      null
      9. User-Agent:
      Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_3) AppleWebKit/537.36
      (KHTML, like Gecko) Chrome/64.0.3282.167 Safari/537.36

Response is:

<p>amfphp and this gateway are installed correctly. You may now connect to
this gateway from Flash.</p><p>Note: If you're reading an old tutorial, it
will tell you that you should see a download window instead of this
message. This confused people so this is the new behaviour starting from
amfphp 1.2.</p><p><a href='http://www.amfphp.org/docs'>View the amfphp
documentation</p><p><a href='browser'>Load the service browser</a></p><pre>

Should I target a specific file with the JS version? Should the endPoint be
different?

On Thu, Feb 15, 2018 at 12:07 PM, Piotr Zarzycki <pi...@gmail.com>
wrote:

> Frederic,
>
> It looks like it is not problem with framework, but rather CORS issue.
> Maybe try to install this plugin [1] and add to the list your url.
>
> [1] https://chrome.google.com/webstore/detail/allow-control-allow-origi/
> nlfbmbojpeacfghkpbjhddihlkkiljbi?hl=en
>
> Piotr
>
> 2018-02-15 12:04 GMT+01:00 Fréderic Cox <co...@gmail.com>:
>
>> For me it is still not working in latest release 0.9.1. I based my
>> example on the example in the SDK.
>>
>> <?xml version="1.0" encoding="utf-8"?>
>> <js:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
>> xmlns:js="library://ns.apache.org/royale/basic" applicationComplete=
>> "applicationCompleteHandler(event);">
>>
>>     <fx:Script>
>>         <![CDATA[
>>             import org.apache.royale.net.RemoteObject;
>>             import org.apache.royale.net.events.FaultEvent;
>>             import org.apache.royale.net.events.ResultEvent;
>>
>>             private function applicationCompleteHandler(evt:Event):void{
>>                 testLabel.text = "Requesting from AMF";
>>                 service.send("getPackages", null);
>>             }
>>
>>             private function amfFaultHandler(evt:FaultEvent):void{
>>                 testLabel.text = "Fault in calling AMF";
>>             }
>>
>>             private function amfResultHandler(evt:ResultEvent):void{
>>                 testLabel.text = "Result received from AMF";
>>             }
>>         ]]>
>>     </fx:Script>
>>
>> <js:valuesImpl>
>> <js:SimpleCSSValuesImpl />
>> </js:valuesImpl>
>>
>>    <js:beads>
>> <js:ClassAliasBead />
>> <js:RemoteObject id="service" result="amfResultHandler(event)" fault=
>> "amfFaultHandler(event)"
>> endPoint = "https://winkelbeheer.cityfashion.be/amfphp/gateway.php"
>> destination = "Meta"
>> source = "Meta"/>
>> </js:beads>
>>
>> <js:initialView>
>> <js:View>
>> <js:Label id="testLabel" />
>> </js:View>
>> </js:initialView>
>> </js:Application>
>>
>>
>> It is not working and showing the following error in the browser:
>>
>> Failed to load https://winkelbeheer.cityfashion.be/amfphp/gateway.php:
>> Response to preflight request doesn't pass access control check: No
>> 'Access-Control-Allow-Origin' header is present on the requested resource.
>> Origin 'http://localhost' is therefore not allowed access.
>> Language.js:238 destination fault handler
>>
>>    1. {code: -1004, message: "Invalid response type.", detail: "Invalid
>>    XMLHttpRequest response status or type.", data: null}
>>       1. code:-1004
>>       2. data:null
>>       3. detail:"Invalid XMLHttpRequest response status or type."
>>       4. message:"Invalid response type."
>>       5. __proto__:Object
>>
>>
>>
>>
>> It is able to compile and run regardless of the errors in compile log:
>>
>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>> println
>> SEVERE: /Users/frederic/Desktop/Personal/Web
>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>> he/royale/reflection/AccessorDefinition.js:12: ERROR - required
>> "org.apache.royale.reflection.TypeDefinition" namespace not provided yet
>> goog.require('org.apache.royale.reflection.TypeDefinition');
>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>
>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>> println
>> SEVERE: /Users/frederic/Desktop/Personal/Web
>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>> he/royale/reflection/AccessorDefinition.js:13: ERROR - required
>> "org.apache.royale.reflection.VariableDefinition" namespace not provided
>> yet
>> goog.require('org.apache.royale.reflection.VariableDefinition');
>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>
>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>> println
>> SEVERE: /Users/frederic/Desktop/Personal/Web
>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>> he/royale/reflection/MethodDefinition.js:14: ERROR - required
>> "org.apache.royale.reflection.TypeDefinition" namespace not provided yet
>> goog.require('org.apache.royale.reflection.TypeDefinition');
>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>
>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>> println
>> SEVERE: /Users/frederic/Desktop/Personal/Web
>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>> he/royale/reflection/ParameterDefinition.js:13: ERROR- required
>> "org.apache.royale.reflection.TypeDefinition" namespace not provided yet
>> goog.require('org.apache.royale.reflection.TypeDefinition');
>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>
>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>> println
>> SEVERE: /Users/frederic/Desktop/Personal/Web
>> Projects/Workspaces/Royale/HelloRoyale/bin/js-debug/org/apac
>> he/royale/reflection/TypeDefinition.js:15: ERROR - required
>> "org.apache.royale.reflection.VariableDefinition" namespace not provided
>> yet
>> goog.require('org.apache.royale.reflection.VariableDefinition');
>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>
>> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
>> printSummary
>> WARNING: 5 error(s), 0 warning(s)
>> The project 'HelloRoyale' has been successfully compiled and optimized.
>> 4.566387 seconds
>>
>>
>> On Mon, Jan 15, 2018 at 7:38 PM, Piotr Zarzycki <
>> piotrzarzycki21@gmail.com> wrote:
>>
>>> Carlos,
>>>
>>> No problem. I have also couple of huge things related to Royale to do
>>> before my hand gets dirty with AMF! :) Unless someone urgently will needed.
>>> :)
>>>
>>> Thanks, Piotr
>>>
>>> 2018-01-15 19:27 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>>>
>>>> Hi Piotr,
>>>> I'll put this on my to do list, but have to do some things first.
>>>> thanks
>>>>
>>>> 2018-01-15 9:26 GMT+01:00 Piotr Zarzycki <pi...@gmail.com>:
>>>>
>>>>> Hi Carlos,
>>>>>
>>>>> Can you describe more how to setup those examples ? Could you add to
>>>>> RemoteObjectAMFTest README.md file where you describe steps. I would like
>>>>> to have AMF on my list for tests and improvements. Whenever I look into
>>>>> that I don't know how to proceed with it.
>>>>>
>>>>> Thanks, Piotr
>>>>>
>>>>> 2018-01-15 9:21 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>>>>>
>>>>>> Hi,
>>>>>>
>>>>>> there's an example that we get it working nicely at:
>>>>>>
>>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/
>>>>>> royale/RemoteObjectAMFTest
>>>>>>
>>>>>> you can use that as a starting point for your test
>>>>>>
>>>>>> As well a java web app that is used along that royale client example
>>>>>> is at:
>>>>>>
>>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/amf
>>>>>>
>>>>>> thanks
>>>>>>
>>>>>>
>>>>>> 2018-01-15 3:56 GMT+01:00 Carlos Cruz <ca...@nbtbizcapital.com>:
>>>>>>
>>>>>>> I have a lot of experience with Flex remoting and BlazeDS with Java,
>>>>>>> but with FlexJS and Royale I have none, but extrapolating from some JS
>>>>>>> tests I've done with AMF at this line: amfTestService.send("get
>>>>>>> ShippingMethods", []); you have to call a class in gateway.php and
>>>>>>> a method. Your request needs at least 3 properties.
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> I'm also assuming your JS file and gateway.php are in the same
>>>>>>> domain and same port (this gave me problems).
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> Take what I said regarding my experience with FlexJS and Royale into
>>>>>>> account.
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> Carlos
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> *From:* Fréderic Cox [mailto:coxfrederic@gmail.com]
>>>>>>> *Sent:* Sunday, January 14, 2018 4:01 PM
>>>>>>>
>>>>>>> *To:* users@royale.apache.org
>>>>>>> *Subject:* Re: RemoteObject
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> Script tag was stripped from the post:
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> import org.apache.royale.events.MouseEvent;
>>>>>>>
>>>>>>>                      import org.apache.royale.net.events.FaultEvent;
>>>>>>>
>>>>>>>                      import org.apache.royale.net.events.R
>>>>>>> esultEvent;
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>                      protected function
>>>>>>> textbutton_clickHandler(event:org.apache.royale.events.MouseEvent):
>>>>>>> void
>>>>>>>
>>>>>>>                      {
>>>>>>>
>>>>>>>                            statusLabel.text = "calling.......";
>>>>>>>
>>>>>>>                            amfTestService.addEventListener("fault",
>>>>>>> amfTestService_faultHandler);
>>>>>>>
>>>>>>>                            amfTestService.addEventListener("result",
>>>>>>> amfTestService_resultHandler);
>>>>>>>
>>>>>>>                            amfTestService.send("getShippingMethods",
>>>>>>> []);
>>>>>>>
>>>>>>>                      }
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>                      protected function
>>>>>>> amfTestService_faultHandler(event:FaultEvent):void
>>>>>>>
>>>>>>>                      {
>>>>>>>
>>>>>>>                            statusLabel.text = "error!";
>>>>>>>
>>>>>>>                      }
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>                      protected function
>>>>>>> amfTestService_resultHandler(event:ResultEvent):void
>>>>>>>
>>>>>>>                      {
>>>>>>>
>>>>>>>                            statusLabel.text = "result!";
>>>>>>>
>>>>>>>                      }
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> none of the events are triggered ..URL is
>>>>>>> http://winkelbeheer.cityfashion.be/amfphp/gateway.php
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> On Fri, Jan 12, 2018 at 4:55 AM, Carlos Cruz <
>>>>>>> carlos@nbtbizcapital.com> wrote:
>>>>>>>
>>>>>>> I may be blind (and or ignorant as I'm more familiar with Flex) but
>>>>>>> where
>>>>>>> are you sending an AMF request? I don't see any code that sends a
>>>>>>> request to
>>>>>>> a service and invokes method.
>>>>>>>
>>>>>>>
>>>>>>> -----Original Message-----
>>>>>>> From: coxfrederic [mailto:coxfrederic@gmail.com]
>>>>>>> Sent: Thursday, January 11, 2018 9:09 PM
>>>>>>> To: users@royale.apache.org
>>>>>>> Subject: Re: RemoteObject
>>>>>>>
>>>>>>> <?xml version="1.0" encoding="utf-8"?>
>>>>>>>
>>>>>>> <js:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
>>>>>>>                    xmlns:js="library://ns.apache.org/royale/basic" >
>>>>>>>         <fx:Script>
>>>>>>>
>>>>>>>         </fx:Script>
>>>>>>>     <js:valuesImpl>
>>>>>>>         <js:SimpleCSSValuesImpl />
>>>>>>>     </js:valuesImpl>
>>>>>>>
>>>>>>>         <js:beads>
>>>>>>>                 <js:ClassAliasBead />
>>>>>>>                 <js:RemoteObject id="amfTestService"
>>>>>>>
>>>>>>> endPoint="http://winkelbeheer.cityfashion.be/amfphp/gateway.php"
>>>>>>>                                                  destination="Meta"
>>>>>>> source="Meta" />
>>>>>>>         </js:beads>
>>>>>>>
>>>>>>>     <js:initialView>
>>>>>>>         <js:View>
>>>>>>>                         <js:VGroup>
>>>>>>>                                 <js:Label id="statusLabel"
>>>>>>> text="Hello
>>>>>>> World!" />
>>>>>>>                                 <js:TextButton text="Get AMF data"
>>>>>>> click="textbutton_clickHandler(event)" />
>>>>>>>                         </js:VGroup>
>>>>>>>         </js:View>
>>>>>>>     </js:initialView>
>>>>>>> </js:Application>
>>>>>>>
>>>>>>>
>>>>>>> Any idea why I'm not getting a fault nor success event on this?
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> Sent from: http://apache-royale-users.20374.n8.nabble.com/
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> Carlos Rovira
>>>>>> http://about.me/carlosrovira
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>> --
>>>>>
>>>>> Piotr Zarzycki
>>>>>
>>>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>>>> <https://www.patreon.com/piotrzarzycki>*
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> Carlos Rovira
>>>> http://about.me/carlosrovira
>>>>
>>>>
>>>
>>>
>>> --
>>>
>>> Piotr Zarzycki
>>>
>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>> <https://www.patreon.com/piotrzarzycki>*
>>>
>>
>>
>
>
> --
>
> Piotr Zarzycki
>
> Patreon: *https://www.patreon.com/piotrzarzycki
> <https://www.patreon.com/piotrzarzycki>*
>

Re: RemoteObject

Posted by Piotr Zarzycki <pi...@gmail.com>.
Frederic,

It looks like it is not problem with framework, but rather CORS issue.
Maybe try to install this plugin [1] and add to the list your url.

[1]
https://chrome.google.com/webstore/detail/allow-control-allow-origi/nlfbmbojpeacfghkpbjhddihlkkiljbi?hl=en

Piotr

2018-02-15 12:04 GMT+01:00 Fréderic Cox <co...@gmail.com>:

> For me it is still not working in latest release 0.9.1. I based my example
> on the example in the SDK.
>
> <?xml version="1.0" encoding="utf-8"?>
> <js:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
> xmlns:js="library://ns.apache.org/royale/basic" applicationComplete="
> applicationCompleteHandler(event);">
>
>     <fx:Script>
>         <![CDATA[
>             import org.apache.royale.net.RemoteObject;
>             import org.apache.royale.net.events.FaultEvent;
>             import org.apache.royale.net.events.ResultEvent;
>
>             private function applicationCompleteHandler(evt:Event):void{
>                 testLabel.text = "Requesting from AMF";
>                 service.send("getPackages", null);
>             }
>
>             private function amfFaultHandler(evt:FaultEvent):void{
>                 testLabel.text = "Fault in calling AMF";
>             }
>
>             private function amfResultHandler(evt:ResultEvent):void{
>                 testLabel.text = "Result received from AMF";
>             }
>         ]]>
>     </fx:Script>
>
> <js:valuesImpl>
> <js:SimpleCSSValuesImpl />
> </js:valuesImpl>
>
>    <js:beads>
> <js:ClassAliasBead />
> <js:RemoteObject id="service" result="amfResultHandler(event)" fault=
> "amfFaultHandler(event)"
> endPoint = "https://winkelbeheer.cityfashion.be/amfphp/gateway.php"
> destination = "Meta"
> source = "Meta"/>
> </js:beads>
>
> <js:initialView>
> <js:View>
> <js:Label id="testLabel" />
> </js:View>
> </js:initialView>
> </js:Application>
>
>
> It is not working and showing the following error in the browser:
>
> Failed to load https://winkelbeheer.cityfashion.be/amfphp/gateway.php:
> Response to preflight request doesn't pass access control check: No
> 'Access-Control-Allow-Origin' header is present on the requested resource.
> Origin 'http://localhost' is therefore not allowed access.
> Language.js:238 destination fault handler
>
>    1. {code: -1004, message: "Invalid response type.", detail: "Invalid
>    XMLHttpRequest response status or type.", data: null}
>       1. code:-1004
>       2. data:null
>       3. detail:"Invalid XMLHttpRequest response status or type."
>       4. message:"Invalid response type."
>       5. __proto__:Object
>
>
>
>
> It is able to compile and run regardless of the errors in compile log:
>
> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
> println
> SEVERE: /Users/frederic/Desktop/Personal/Web Projects/Workspaces/Royale/
> HelloRoyale/bin/js-debug/org/apache/royale/reflection/AccessorDefinition.js:12:
> ERROR - required "org.apache.royale.reflection.TypeDefinition" namespace
> not provided yet
> goog.require('org.apache.royale.reflection.TypeDefinition');
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>
> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
> println
> SEVERE: /Users/frederic/Desktop/Personal/Web Projects/Workspaces/Royale/
> HelloRoyale/bin/js-debug/org/apache/royale/reflection/AccessorDefinition.js:13:
> ERROR - required "org.apache.royale.reflection.VariableDefinition"
> namespace not provided yet
> goog.require('org.apache.royale.reflection.VariableDefinition');
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>
> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
> println
> SEVERE: /Users/frederic/Desktop/Personal/Web Projects/Workspaces/Royale/
> HelloRoyale/bin/js-debug/org/apache/royale/reflection/MethodDefinition.js:14:
> ERROR - required "org.apache.royale.reflection.TypeDefinition" namespace
> not provided yet
> goog.require('org.apache.royale.reflection.TypeDefinition');
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>
> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
> println
> SEVERE: /Users/frederic/Desktop/Personal/Web Projects/Workspaces/Royale/
> HelloRoyale/bin/js-debug/org/apache/royale/reflection/ParameterDefinition.js:13:
> ERROR- required "org.apache.royale.reflection.TypeDefinition" namespace
> not provided yet
> goog.require('org.apache.royale.reflection.TypeDefinition');
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>
> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
> println
> SEVERE: /Users/frederic/Desktop/Personal/Web Projects/Workspaces/Royale/
> HelloRoyale/bin/js-debug/org/apache/royale/reflection/TypeDefinition.js:15:
> ERROR - required "org.apache.royale.reflection.VariableDefinition"
> namespace not provided yet
> goog.require('org.apache.royale.reflection.VariableDefinition');
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>
> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
> printSummary
> WARNING: 5 error(s), 0 warning(s)
> The project 'HelloRoyale' has been successfully compiled and optimized.
> 4.566387 seconds
>
>
> On Mon, Jan 15, 2018 at 7:38 PM, Piotr Zarzycki <piotrzarzycki21@gmail.com
> > wrote:
>
>> Carlos,
>>
>> No problem. I have also couple of huge things related to Royale to do
>> before my hand gets dirty with AMF! :) Unless someone urgently will needed.
>> :)
>>
>> Thanks, Piotr
>>
>> 2018-01-15 19:27 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>>
>>> Hi Piotr,
>>> I'll put this on my to do list, but have to do some things first.
>>> thanks
>>>
>>> 2018-01-15 9:26 GMT+01:00 Piotr Zarzycki <pi...@gmail.com>:
>>>
>>>> Hi Carlos,
>>>>
>>>> Can you describe more how to setup those examples ? Could you add to
>>>> RemoteObjectAMFTest README.md file where you describe steps. I would like
>>>> to have AMF on my list for tests and improvements. Whenever I look into
>>>> that I don't know how to proceed with it.
>>>>
>>>> Thanks, Piotr
>>>>
>>>> 2018-01-15 9:21 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>>>>
>>>>> Hi,
>>>>>
>>>>> there's an example that we get it working nicely at:
>>>>>
>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/
>>>>> royale/RemoteObjectAMFTest
>>>>>
>>>>> you can use that as a starting point for your test
>>>>>
>>>>> As well a java web app that is used along that royale client example
>>>>> is at:
>>>>>
>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/amf
>>>>>
>>>>> thanks
>>>>>
>>>>>
>>>>> 2018-01-15 3:56 GMT+01:00 Carlos Cruz <ca...@nbtbizcapital.com>:
>>>>>
>>>>>> I have a lot of experience with Flex remoting and BlazeDS with Java,
>>>>>> but with FlexJS and Royale I have none, but extrapolating from some JS
>>>>>> tests I've done with AMF at this line: amfTestService.send("get
>>>>>> ShippingMethods", []); you have to call a class in gateway.php and a
>>>>>> method. Your request needs at least 3 properties.
>>>>>>
>>>>>>
>>>>>>
>>>>>> I'm also assuming your JS file and gateway.php are in the same domain
>>>>>> and same port (this gave me problems).
>>>>>>
>>>>>>
>>>>>>
>>>>>> Take what I said regarding my experience with FlexJS and Royale into
>>>>>> account.
>>>>>>
>>>>>>
>>>>>>
>>>>>> Carlos
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> *From:* Fréderic Cox [mailto:coxfrederic@gmail.com]
>>>>>> *Sent:* Sunday, January 14, 2018 4:01 PM
>>>>>>
>>>>>> *To:* users@royale.apache.org
>>>>>> *Subject:* Re: RemoteObject
>>>>>>
>>>>>>
>>>>>>
>>>>>> Script tag was stripped from the post:
>>>>>>
>>>>>>
>>>>>>
>>>>>> import org.apache.royale.events.MouseEvent;
>>>>>>
>>>>>>                      import org.apache.royale.net.events.FaultEvent;
>>>>>>
>>>>>>                      import org.apache.royale.net.events.ResultEvent;
>>>>>>
>>>>>>
>>>>>>
>>>>>>                      protected function
>>>>>> textbutton_clickHandler(event:org.apache.royale.events.MouseEvent):
>>>>>> void
>>>>>>
>>>>>>                      {
>>>>>>
>>>>>>                            statusLabel.text = "calling.......";
>>>>>>
>>>>>>                            amfTestService.addEventListener("fault",
>>>>>> amfTestService_faultHandler);
>>>>>>
>>>>>>                            amfTestService.addEventListener("result",
>>>>>> amfTestService_resultHandler);
>>>>>>
>>>>>>                            amfTestService.send("getShippingMethods",
>>>>>> []);
>>>>>>
>>>>>>                      }
>>>>>>
>>>>>>
>>>>>>
>>>>>>                      protected function
>>>>>> amfTestService_faultHandler(event:FaultEvent):void
>>>>>>
>>>>>>                      {
>>>>>>
>>>>>>                            statusLabel.text = "error!";
>>>>>>
>>>>>>                      }
>>>>>>
>>>>>>
>>>>>>
>>>>>>                      protected function
>>>>>> amfTestService_resultHandler(event:ResultEvent):void
>>>>>>
>>>>>>                      {
>>>>>>
>>>>>>                            statusLabel.text = "result!";
>>>>>>
>>>>>>                      }
>>>>>>
>>>>>>
>>>>>>
>>>>>> none of the events are triggered ..URL is http://winkelbeheer.cityfas
>>>>>> hion.be/amfphp/gateway.php
>>>>>>
>>>>>>
>>>>>>
>>>>>> On Fri, Jan 12, 2018 at 4:55 AM, Carlos Cruz <
>>>>>> carlos@nbtbizcapital.com> wrote:
>>>>>>
>>>>>> I may be blind (and or ignorant as I'm more familiar with Flex) but
>>>>>> where
>>>>>> are you sending an AMF request? I don't see any code that sends a
>>>>>> request to
>>>>>> a service and invokes method.
>>>>>>
>>>>>>
>>>>>> -----Original Message-----
>>>>>> From: coxfrederic [mailto:coxfrederic@gmail.com]
>>>>>> Sent: Thursday, January 11, 2018 9:09 PM
>>>>>> To: users@royale.apache.org
>>>>>> Subject: Re: RemoteObject
>>>>>>
>>>>>> <?xml version="1.0" encoding="utf-8"?>
>>>>>>
>>>>>> <js:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
>>>>>>                    xmlns:js="library://ns.apache.org/royale/basic" >
>>>>>>         <fx:Script>
>>>>>>
>>>>>>         </fx:Script>
>>>>>>     <js:valuesImpl>
>>>>>>         <js:SimpleCSSValuesImpl />
>>>>>>     </js:valuesImpl>
>>>>>>
>>>>>>         <js:beads>
>>>>>>                 <js:ClassAliasBead />
>>>>>>                 <js:RemoteObject id="amfTestService"
>>>>>>
>>>>>> endPoint="http://winkelbeheer.cityfashion.be/amfphp/gateway.php"
>>>>>>                                                  destination="Meta"
>>>>>> source="Meta" />
>>>>>>         </js:beads>
>>>>>>
>>>>>>     <js:initialView>
>>>>>>         <js:View>
>>>>>>                         <js:VGroup>
>>>>>>                                 <js:Label id="statusLabel" text="Hello
>>>>>> World!" />
>>>>>>                                 <js:TextButton text="Get AMF data"
>>>>>> click="textbutton_clickHandler(event)" />
>>>>>>                         </js:VGroup>
>>>>>>         </js:View>
>>>>>>     </js:initialView>
>>>>>> </js:Application>
>>>>>>
>>>>>>
>>>>>> Any idea why I'm not getting a fault nor success event on this?
>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> Sent from: http://apache-royale-users.20374.n8.nabble.com/
>>>>>>
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Carlos Rovira
>>>>> http://about.me/carlosrovira
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>>
>>>> Piotr Zarzycki
>>>>
>>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>>> <https://www.patreon.com/piotrzarzycki>*
>>>>
>>>
>>>
>>>
>>> --
>>> Carlos Rovira
>>> http://about.me/carlosrovira
>>>
>>>
>>
>>
>> --
>>
>> Piotr Zarzycki
>>
>> Patreon: *https://www.patreon.com/piotrzarzycki
>> <https://www.patreon.com/piotrzarzycki>*
>>
>
>


-- 

Piotr Zarzycki

Patreon: *https://www.patreon.com/piotrzarzycki
<https://www.patreon.com/piotrzarzycki>*

Re: RemoteObject

Posted by Gabe Harbs <ha...@gmail.com>.
Make sure you use the -remove-circulars option.

> On Feb 15, 2018, at 1:04 PM, Fréderic Cox <co...@gmail.com> wrote:
> 
> It is able to compile and run regardless of the errors in compile log:
> 


Re: RemoteObject

Posted by Fréderic Cox <co...@gmail.com>.
Seems CORS was the issue, so I uploaded the script to the same domain then
getting the error:

destination fault handler

   1. org.apache.royale.net.remoting.messages.ErrorMessage {_body: {…},
   correlationId: "", faultCode: "AMFPHP_FILE_NOT_FOUND", faultDetail:
"/var/web/fn0383/enality.clients.v2/amfphp/core/shared/app/BasicActions.php
   on line 33", faultString: "The class {Amf3Broker} could not be found
   under th…clients.v2/amfphp/services/amfphp/Amf3Broker.php}"}
      1. correlationId:""
      2. faultCode:"AMFPHP_FILE_NOT_FOUND"
      3. faultDetail:"/var/web/fn0383/enality.clients.v2/amfphp/core/shared/app/BasicActions.php
      on line 33"
      4. faultString:"The class {Amf3Broker} could not be found under the
      class path
      {/var/web/fn0383/enality.clients.v2/amfphp/services/amfphp/Amf3Broker.php}
      "



Any idea?

On Thu, Feb 15, 2018 at 12:04 PM, Fréderic Cox <co...@gmail.com>
wrote:

> For me it is still not working in latest release 0.9.1. I based my example
> on the example in the SDK.
>
> <?xml version="1.0" encoding="utf-8"?>
> <js:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
> xmlns:js="library://ns.apache.org/royale/basic" applicationComplete="
> applicationCompleteHandler(event);">
>
>     <fx:Script>
>         <![CDATA[
>             import org.apache.royale.net.RemoteObject;
>             import org.apache.royale.net.events.FaultEvent;
>             import org.apache.royale.net.events.ResultEvent;
>
>             private function applicationCompleteHandler(evt:Event):void{
>                 testLabel.text = "Requesting from AMF";
>                 service.send("getPackages", null);
>             }
>
>             private function amfFaultHandler(evt:FaultEvent):void{
>                 testLabel.text = "Fault in calling AMF";
>             }
>
>             private function amfResultHandler(evt:ResultEvent):void{
>                 testLabel.text = "Result received from AMF";
>             }
>         ]]>
>     </fx:Script>
>
> <js:valuesImpl>
> <js:SimpleCSSValuesImpl />
> </js:valuesImpl>
>
>    <js:beads>
> <js:ClassAliasBead />
> <js:RemoteObject id="service" result="amfResultHandler(event)" fault=
> "amfFaultHandler(event)"
> endPoint = "https://winkelbeheer.cityfashion.be/amfphp/gateway.php"
> destination = "Meta"
> source = "Meta"/>
> </js:beads>
>
> <js:initialView>
> <js:View>
> <js:Label id="testLabel" />
> </js:View>
> </js:initialView>
> </js:Application>
>
>
> It is not working and showing the following error in the browser:
>
> Failed to load https://winkelbeheer.cityfashion.be/amfphp/gateway.php:
> Response to preflight request doesn't pass access control check: No
> 'Access-Control-Allow-Origin' header is present on the requested resource.
> Origin 'http://localhost' is therefore not allowed access.
> Language.js:238 destination fault handler
>
>    1. {code: -1004, message: "Invalid response type.", detail: "Invalid
>    XMLHttpRequest response status or type.", data: null}
>       1. code:-1004
>       2. data:null
>       3. detail:"Invalid XMLHttpRequest response status or type."
>       4. message:"Invalid response type."
>       5. __proto__:Object
>
>
>
>
> It is able to compile and run regardless of the errors in compile log:
>
> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
> println
> SEVERE: /Users/frederic/Desktop/Personal/Web Projects/Workspaces/Royale/
> HelloRoyale/bin/js-debug/org/apache/royale/reflection/AccessorDefinition.js:12:
> ERROR - required "org.apache.royale.reflection.TypeDefinition" namespace
> not provided yet
> goog.require('org.apache.royale.reflection.TypeDefinition');
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>
> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
> println
> SEVERE: /Users/frederic/Desktop/Personal/Web Projects/Workspaces/Royale/
> HelloRoyale/bin/js-debug/org/apache/royale/reflection/AccessorDefinition.js:13:
> ERROR - required "org.apache.royale.reflection.VariableDefinition"
> namespace not provided yet
> goog.require('org.apache.royale.reflection.VariableDefinition');
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>
> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
> println
> SEVERE: /Users/frederic/Desktop/Personal/Web Projects/Workspaces/Royale/
> HelloRoyale/bin/js-debug/org/apache/royale/reflection/MethodDefinition.js:14:
> ERROR - required "org.apache.royale.reflection.TypeDefinition" namespace
> not provided yet
> goog.require('org.apache.royale.reflection.TypeDefinition');
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>
> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
> println
> SEVERE: /Users/frederic/Desktop/Personal/Web Projects/Workspaces/Royale/
> HelloRoyale/bin/js-debug/org/apache/royale/reflection/ParameterDefinition.js:13:
> ERROR- required "org.apache.royale.reflection.TypeDefinition" namespace
> not provided yet
> goog.require('org.apache.royale.reflection.TypeDefinition');
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>
> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
> println
> SEVERE: /Users/frederic/Desktop/Personal/Web Projects/Workspaces/Royale/
> HelloRoyale/bin/js-debug/org/apache/royale/reflection/TypeDefinition.js:15:
> ERROR - required "org.apache.royale.reflection.VariableDefinition"
> namespace not provided yet
> goog.require('org.apache.royale.reflection.VariableDefinition');
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>
> Feb 15, 2018 11:51:04 AM com.google.javascript.jscomp.LoggerErrorManager
> printSummary
> WARNING: 5 error(s), 0 warning(s)
> The project 'HelloRoyale' has been successfully compiled and optimized.
> 4.566387 seconds
>
>
> On Mon, Jan 15, 2018 at 7:38 PM, Piotr Zarzycki <piotrzarzycki21@gmail.com
> > wrote:
>
>> Carlos,
>>
>> No problem. I have also couple of huge things related to Royale to do
>> before my hand gets dirty with AMF! :) Unless someone urgently will needed.
>> :)
>>
>> Thanks, Piotr
>>
>> 2018-01-15 19:27 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>>
>>> Hi Piotr,
>>> I'll put this on my to do list, but have to do some things first.
>>> thanks
>>>
>>> 2018-01-15 9:26 GMT+01:00 Piotr Zarzycki <pi...@gmail.com>:
>>>
>>>> Hi Carlos,
>>>>
>>>> Can you describe more how to setup those examples ? Could you add to
>>>> RemoteObjectAMFTest README.md file where you describe steps. I would like
>>>> to have AMF on my list for tests and improvements. Whenever I look into
>>>> that I don't know how to proceed with it.
>>>>
>>>> Thanks, Piotr
>>>>
>>>> 2018-01-15 9:21 GMT+01:00 Carlos Rovira <ca...@apache.org>:
>>>>
>>>>> Hi,
>>>>>
>>>>> there's an example that we get it working nicely at:
>>>>>
>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/
>>>>> royale/RemoteObjectAMFTest
>>>>>
>>>>> you can use that as a starting point for your test
>>>>>
>>>>> As well a java web app that is used along that royale client example
>>>>> is at:
>>>>>
>>>>> https://github.com/apache/royale-asjs/tree/develop/examples/amf
>>>>>
>>>>> thanks
>>>>>
>>>>>
>>>>> 2018-01-15 3:56 GMT+01:00 Carlos Cruz <ca...@nbtbizcapital.com>:
>>>>>
>>>>>> I have a lot of experience with Flex remoting and BlazeDS with Java,
>>>>>> but with FlexJS and Royale I have none, but extrapolating from some JS
>>>>>> tests I've done with AMF at this line: amfTestService.send("get
>>>>>> ShippingMethods", []); you have to call a class in gateway.php and a
>>>>>> method. Your request needs at least 3 properties.
>>>>>>
>>>>>>
>>>>>>
>>>>>> I'm also assuming your JS file and gateway.php are in the same domain
>>>>>> and same port (this gave me problems).
>>>>>>
>>>>>>
>>>>>>
>>>>>> Take what I said regarding my experience with FlexJS and Royale into
>>>>>> account.
>>>>>>
>>>>>>
>>>>>>
>>>>>> Carlos
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> *From:* Fréderic Cox [mailto:coxfrederic@gmail.com]
>>>>>> *Sent:* Sunday, January 14, 2018 4:01 PM
>>>>>>
>>>>>> *To:* users@royale.apache.org
>>>>>> *Subject:* Re: RemoteObject
>>>>>>
>>>>>>
>>>>>>
>>>>>> Script tag was stripped from the post:
>>>>>>
>>>>>>
>>>>>>
>>>>>> import org.apache.royale.events.MouseEvent;
>>>>>>
>>>>>>                      import org.apache.royale.net.events.FaultEvent;
>>>>>>
>>>>>>                      import org.apache.royale.net.events.ResultEvent;
>>>>>>
>>>>>>
>>>>>>
>>>>>>                      protected function
>>>>>> textbutton_clickHandler(event:org.apache.royale.events.MouseEvent):
>>>>>> void
>>>>>>
>>>>>>                      {
>>>>>>
>>>>>>                            statusLabel.text = "calling.......";
>>>>>>
>>>>>>                            amfTestService.addEventListener("fault",
>>>>>> amfTestService_faultHandler);
>>>>>>
>>>>>>                            amfTestService.addEventListener("result",
>>>>>> amfTestService_resultHandler);
>>>>>>
>>>>>>                            amfTestService.send("getShippingMethods",
>>>>>> []);
>>>>>>
>>>>>>                      }
>>>>>>
>>>>>>
>>>>>>
>>>>>>                      protected function
>>>>>> amfTestService_faultHandler(event:FaultEvent):void
>>>>>>
>>>>>>                      {
>>>>>>
>>>>>>                            statusLabel.text = "error!";
>>>>>>
>>>>>>                      }
>>>>>>
>>>>>>
>>>>>>
>>>>>>                      protected function
>>>>>> amfTestService_resultHandler(event:ResultEvent):void
>>>>>>
>>>>>>                      {
>>>>>>
>>>>>>                            statusLabel.text = "result!";
>>>>>>
>>>>>>                      }
>>>>>>
>>>>>>
>>>>>>
>>>>>> none of the events are triggered ..URL is http://winkelbeheer.cityfas
>>>>>> hion.be/amfphp/gateway.php
>>>>>>
>>>>>>
>>>>>>
>>>>>> On Fri, Jan 12, 2018 at 4:55 AM, Carlos Cruz <
>>>>>> carlos@nbtbizcapital.com> wrote:
>>>>>>
>>>>>> I may be blind (and or ignorant as I'm more familiar with Flex) but
>>>>>> where
>>>>>> are you sending an AMF request? I don't see any code that sends a
>>>>>> request to
>>>>>> a service and invokes method.
>>>>>>
>>>>>>
>>>>>> -----Original Message-----
>>>>>> From: coxfrederic [mailto:coxfrederic@gmail.com]
>>>>>> Sent: Thursday, January 11, 2018 9:09 PM
>>>>>> To: users@royale.apache.org
>>>>>> Subject: Re: RemoteObject
>>>>>>
>>>>>> <?xml version="1.0" encoding="utf-8"?>
>>>>>>
>>>>>> <js:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
>>>>>>                    xmlns:js="library://ns.apache.org/royale/basic" >
>>>>>>         <fx:Script>
>>>>>>
>>>>>>         </fx:Script>
>>>>>>     <js:valuesImpl>
>>>>>>         <js:SimpleCSSValuesImpl />
>>>>>>     </js:valuesImpl>
>>>>>>
>>>>>>         <js:beads>
>>>>>>                 <js:ClassAliasBead />
>>>>>>                 <js:RemoteObject id="amfTestService"
>>>>>>
>>>>>> endPoint="http://winkelbeheer.cityfashion.be/amfphp/gateway.php"
>>>>>>                                                  destination="Meta"
>>>>>> source="Meta" />
>>>>>>         </js:beads>
>>>>>>
>>>>>>     <js:initialView>
>>>>>>         <js:View>
>>>>>>                         <js:VGroup>
>>>>>>                                 <js:Label id="statusLabel" text="Hello
>>>>>> World!" />
>>>>>>                                 <js:TextButton text="Get AMF data"
>>>>>> click="textbutton_clickHandler(event)" />
>>>>>>                         </js:VGroup>
>>>>>>         </js:View>
>>>>>>     </js:initialView>
>>>>>> </js:Application>
>>>>>>
>>>>>>
>>>>>> Any idea why I'm not getting a fault nor success event on this?
>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> Sent from: http://apache-royale-users.20374.n8.nabble.com/
>>>>>>
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Carlos Rovira
>>>>> http://about.me/carlosrovira
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>>
>>>> Piotr Zarzycki
>>>>
>>>> Patreon: *https://www.patreon.com/piotrzarzycki
>>>> <https://www.patreon.com/piotrzarzycki>*
>>>>
>>>
>>>
>>>
>>> --
>>> Carlos Rovira
>>> http://about.me/carlosrovira
>>>
>>>
>>
>>
>> --
>>
>> Piotr Zarzycki
>>
>> Patreon: *https://www.patreon.com/piotrzarzycki
>> <https://www.patreon.com/piotrzarzycki>*
>>
>
>