Re: [Dev] encodeURIComponent is not working in ESB-BETA
Hi Nuwan, Now it is working as we expected. Thank you for your prompt response. On Fri, Jun 24, 2016 at 10:36 AM, Nuwan Wimalasekara wrote: > Hi Hariprasath, > > Seems this is also the same issue as [1] with the rhino17 upgrade. You can > get rid of this issue when using toString() function whenever accessing a > string which is concatenated using +. > > mc.setProperty('uri.var.requestQuery',requestQuery.toString()); > > [1] > https://mozilla.github.io/rhino/javadoc/org/mozilla/javascript/ConsString.html > > > Thanks, > Nuwanw > > On Fri, Jun 24, 2016 at 9:01 AM, Malaka Silva wrote: > >> Seems like the behavior of encodeURIComponent >> changed due to rhino upgrade. >> >> @Hariprasath - Can you compare the out put from ESB 490 vs ESB 500? >> Also why are we using [1] to call the endpoint >> instead of call mediator? AFAIK we agreed to change this during the review? >> >> >> @NuwanW - Any idea? >> >> [1] >> https://github.com/wso2-extensions/esb-connector-powerbi/blob/master/src/main/java/org/wso2/carbon/connector/powerbi/auth/PowerBIAccessTokenGenerator.java >> >> On Thu, Jun 23, 2016 at 8:39 PM, Hariprasath Thanarajah < >> haripras...@wso2.com> wrote: >> >>> Hi All, >>> >>> When we trying to run the integration test for PowerBI with the BETA >>> release we got the following error[1], but in 4.9.0 it is working fine. I >>> think it is because of [2]. How can we handle this? >>> >>> [1] >>> [2016-06-23 20:19:14,807] INFO >>> {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - >>> [2016-06-23 20:19:14,807] DEBUG - wire HTTP-Listener I/O dispatcher-1 >> >>> "[\r][\n]" >>> [2016-06-23 20:19:14,807] INFO >>> {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - >>> [2016-06-23 20:19:14,807] DEBUG - wire HTTP-Listener I/O dispatcher-1 >> >>> "{[\n]" >>> [2016-06-23 20:19:14,807] INFO >>> {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - >>> [2016-06-23 20:19:14,807] DEBUG - wire HTTP-Listener I/O dispatcher-1 >> >>> "[\n]" >>> [2016-06-23 20:19:14,807] INFO >>> {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - >>> [2016-06-23 20:19:14,807] DEBUG - wire HTTP-Listener I/O dispatcher-1 >> >>> "[0x9]"authorizationCode":"AAABiL9Kn2Z27UubvWFPbm0gLdM9QCaEE__Umb9UkVqMUwnGW5ABwXLBdG5PDZbal_1sPGCDl9hb0BntSwR-Ru3gD5buzl8WmK-Xr2k8bIOw5sVZJgQOngtTEZIavKvrWs7vdbJy8VXNyv3YAlQrKDDwZ-MO8cZIOMDzg38LQUa4QwDZeaMr-xBenghSVA91OSr-GRtaMxEo_AZg_q_ajQEMThWYFMIfcjwPsXGf9YkMhNMW_rM_sKm6imyk9L6fkmCqL_AzdvT8WjbPHtam8uyQnTFKtv3Jt7wh3DVfVd1W73_I1k7LJd7ruKyMwiZOXwUDB_S4MnYUS-93_oPQm8V92c6aEOi87Hw9QdYP38mPY-mgYt8DcvSNYH8kBnUO59pC4MjLz34TjJA3VqfsOtUJ1o-AyLDZfpoxmMAIhhfq9gpnfBVA4vK22h_a8RHTQH--H1VUUiHQFhQAQVVsXVMPq2RensvexaJDHhDyhz-g6IKct9dZx6PwnFlHXYsmMuzTeC2BTKhdRnag1ZDzNIA7Q0C7C-mnWFR7n63VtMyMrwWXJQHStkWP7C0KjQFOBQCeZbQyJdGVRCc0nSELCtsgKkgnahvm_9mxmv3AlYjXUkGcUGzMAzsgVQxFzFn23B3B4at9N1BB69gm6vtUMTIkBwUqHtwzQqEEs4WO7WDVYPluq23i1IrmXug8qkoykarPujcccII57plUcj99_vVPPbfjIq51PjmMHpFZxbqjKQZ-pNy-OOLgTVyZDgit8Pt3IAA",[\n]" >>> [2016-06-23 20:19:14,808] INFO >>> {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - >>> [2016-06-23 20:19:14,807] DEBUG - wire HTTP-Listener I/O dispatcher-1 >> >>> "[0x9]"resource":"https://analysis.windows.net/powerbi/api"[\n]"; >>> [2016-06-23 20:19:14,808] INFO >>> {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - >>> [2016-06-23 20:19:14,808] DEBUG - wire HTTP-Listener I/O dispatcher-1 >> "}" >>> [2016-06-23 20:19:14,852] INFO >>> {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - >>> [2016-06-23 20:19:14,852] ERROR - SynapseJsonPath #stringValueOf. Error >>> evaluating JSON Path <$.apiUrl>. Returning empty result. Error>>> invalid >>> path >>> [2016-06-23 20:19:14,856] INFO >>> {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - >>> [2016-06-23 20:19:14,856] ERROR - SynapseJsonPath #stringValueOf. Error >>> evaluating JSON Path <$.defaultRetentionPolicy>. Returning empty result. >>> Error>>> invalid path >>> [2016-06-23 20:19:14,859] INFO >>> {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - >>> [2016-06-23 20:19:14,859] ERROR - SynapseJsonPath #stringValueOf. Error >>> evaluating JSON Path <$.datasetName>. Returning empty result. Error>>> >>> invalid path >>> [2016-06-23 20:19:14,861] INFO >>> {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - >>> [2016-06-23 20:19:14,861] ERROR - SynapseJsonPath #stringValueOf. Error >>> evaluating JSON Path <$.tables>. Returning empty result. Error>>> invalid >>> path >>> [2016-06-23 20:19:14,862] INFO >>> {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - >>> [2016-06-23 20:19:14,862] ERROR - SynapseJsonPath #stringValueOf. Error >>> evaluating JSON Path <$.groupId>. Returning empty result. Error>>> invalid >>> path >>> [2016-06-23 20:19:14,863] INFO >>> {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandle
Re: [Dev] encodeURIComponent is not working in ESB-BETA
Hi Hariprasath, Seems this is also the same issue as [1] with the rhino17 upgrade. You can get rid of this issue when using toString() function whenever accessing a string which is concatenated using +. mc.setProperty('uri.var.requestQuery',requestQuery.toString()); [1] https://mozilla.github.io/rhino/javadoc/org/mozilla/javascript/ConsString.html Thanks, Nuwanw On Fri, Jun 24, 2016 at 9:01 AM, Malaka Silva wrote: > Seems like the behavior of encodeURIComponent > changed due to rhino upgrade. > > @Hariprasath - Can you compare the out put from ESB 490 vs ESB 500? > Also why are we using [1] to call the endpoint > instead of call mediator? AFAIK we agreed to change this during the review? > > > @NuwanW - Any idea? > > [1] > https://github.com/wso2-extensions/esb-connector-powerbi/blob/master/src/main/java/org/wso2/carbon/connector/powerbi/auth/PowerBIAccessTokenGenerator.java > > On Thu, Jun 23, 2016 at 8:39 PM, Hariprasath Thanarajah < > haripras...@wso2.com> wrote: > >> Hi All, >> >> When we trying to run the integration test for PowerBI with the BETA >> release we got the following error[1], but in 4.9.0 it is working fine. I >> think it is because of [2]. How can we handle this? >> >> [1] >> [2016-06-23 20:19:14,807] INFO >> {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - >> [2016-06-23 20:19:14,807] DEBUG - wire HTTP-Listener I/O dispatcher-1 >> >> "[\r][\n]" >> [2016-06-23 20:19:14,807] INFO >> {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - >> [2016-06-23 20:19:14,807] DEBUG - wire HTTP-Listener I/O dispatcher-1 >> >> "{[\n]" >> [2016-06-23 20:19:14,807] INFO >> {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - >> [2016-06-23 20:19:14,807] DEBUG - wire HTTP-Listener I/O dispatcher-1 >> >> "[\n]" >> [2016-06-23 20:19:14,807] INFO >> {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - >> [2016-06-23 20:19:14,807] DEBUG - wire HTTP-Listener I/O dispatcher-1 >> >> "[0x9]"authorizationCode":"AAABiL9Kn2Z27UubvWFPbm0gLdM9QCaEE__Umb9UkVqMUwnGW5ABwXLBdG5PDZbal_1sPGCDl9hb0BntSwR-Ru3gD5buzl8WmK-Xr2k8bIOw5sVZJgQOngtTEZIavKvrWs7vdbJy8VXNyv3YAlQrKDDwZ-MO8cZIOMDzg38LQUa4QwDZeaMr-xBenghSVA91OSr-GRtaMxEo_AZg_q_ajQEMThWYFMIfcjwPsXGf9YkMhNMW_rM_sKm6imyk9L6fkmCqL_AzdvT8WjbPHtam8uyQnTFKtv3Jt7wh3DVfVd1W73_I1k7LJd7ruKyMwiZOXwUDB_S4MnYUS-93_oPQm8V92c6aEOi87Hw9QdYP38mPY-mgYt8DcvSNYH8kBnUO59pC4MjLz34TjJA3VqfsOtUJ1o-AyLDZfpoxmMAIhhfq9gpnfBVA4vK22h_a8RHTQH--H1VUUiHQFhQAQVVsXVMPq2RensvexaJDHhDyhz-g6IKct9dZx6PwnFlHXYsmMuzTeC2BTKhdRnag1ZDzNIA7Q0C7C-mnWFR7n63VtMyMrwWXJQHStkWP7C0KjQFOBQCeZbQyJdGVRCc0nSELCtsgKkgnahvm_9mxmv3AlYjXUkGcUGzMAzsgVQxFzFn23B3B4at9N1BB69gm6vtUMTIkBwUqHtwzQqEEs4WO7WDVYPluq23i1IrmXug8qkoykarPujcccII57plUcj99_vVPPbfjIq51PjmMHpFZxbqjKQZ-pNy-OOLgTVyZDgit8Pt3IAA",[\n]" >> [2016-06-23 20:19:14,808] INFO >> {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - >> [2016-06-23 20:19:14,807] DEBUG - wire HTTP-Listener I/O dispatcher-1 >> >> "[0x9]"resource":"https://analysis.windows.net/powerbi/api"[\n]"; >> [2016-06-23 20:19:14,808] INFO >> {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - >> [2016-06-23 20:19:14,808] DEBUG - wire HTTP-Listener I/O dispatcher-1 >> "}" >> [2016-06-23 20:19:14,852] INFO >> {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - >> [2016-06-23 20:19:14,852] ERROR - SynapseJsonPath #stringValueOf. Error >> evaluating JSON Path <$.apiUrl>. Returning empty result. Error>>> invalid >> path >> [2016-06-23 20:19:14,856] INFO >> {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - >> [2016-06-23 20:19:14,856] ERROR - SynapseJsonPath #stringValueOf. Error >> evaluating JSON Path <$.defaultRetentionPolicy>. Returning empty result. >> Error>>> invalid path >> [2016-06-23 20:19:14,859] INFO >> {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - >> [2016-06-23 20:19:14,859] ERROR - SynapseJsonPath #stringValueOf. Error >> evaluating JSON Path <$.datasetName>. Returning empty result. Error>>> >> invalid path >> [2016-06-23 20:19:14,861] INFO >> {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - >> [2016-06-23 20:19:14,861] ERROR - SynapseJsonPath #stringValueOf. Error >> evaluating JSON Path <$.tables>. Returning empty result. Error>>> invalid >> path >> [2016-06-23 20:19:14,862] INFO >> {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - >> [2016-06-23 20:19:14,862] ERROR - SynapseJsonPath #stringValueOf. Error >> evaluating JSON Path <$.groupId>. Returning empty result. Error>>> invalid >> path >> [2016-06-23 20:19:14,863] INFO >> {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - >> [2016-06-23 20:19:14,863] ERROR - SynapseJsonPath #stringValueOf. Error >> evaluating JSON Path <$.datasetId>. Returning empty result. Error>>> >> invalid path >> [2016-06-23 20:19:14,864] INFO >> {org.wso2.carbon.automation.core.utils
Re: [Dev] encodeURIComponent is not working in ESB-BETA
Seems like the behavior of encodeURIComponent changed due to rhino upgrade. @Hariprasath - Can you compare the out put from ESB 490 vs ESB 500? Also why are we using [1] to call the endpoint instead of call mediator? AFAIK we agreed to change this during the review? @NuwanW - Any idea? [1] https://github.com/wso2-extensions/esb-connector-powerbi/blob/master/src/main/java/org/wso2/carbon/connector/powerbi/auth/PowerBIAccessTokenGenerator.java On Thu, Jun 23, 2016 at 8:39 PM, Hariprasath Thanarajah < haripras...@wso2.com> wrote: > Hi All, > > When we trying to run the integration test for PowerBI with the BETA > release we got the following error[1], but in 4.9.0 it is working fine. I > think it is because of [2]. How can we handle this? > > [1] > [2016-06-23 20:19:14,807] INFO > {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - > [2016-06-23 20:19:14,807] DEBUG - wire HTTP-Listener I/O dispatcher-1 >> > "[\r][\n]" > [2016-06-23 20:19:14,807] INFO > {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - > [2016-06-23 20:19:14,807] DEBUG - wire HTTP-Listener I/O dispatcher-1 >> > "{[\n]" > [2016-06-23 20:19:14,807] INFO > {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - > [2016-06-23 20:19:14,807] DEBUG - wire HTTP-Listener I/O dispatcher-1 >> > "[\n]" > [2016-06-23 20:19:14,807] INFO > {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - > [2016-06-23 20:19:14,807] DEBUG - wire HTTP-Listener I/O dispatcher-1 >> > "[0x9]"authorizationCode":"AAABiL9Kn2Z27UubvWFPbm0gLdM9QCaEE__Umb9UkVqMUwnGW5ABwXLBdG5PDZbal_1sPGCDl9hb0BntSwR-Ru3gD5buzl8WmK-Xr2k8bIOw5sVZJgQOngtTEZIavKvrWs7vdbJy8VXNyv3YAlQrKDDwZ-MO8cZIOMDzg38LQUa4QwDZeaMr-xBenghSVA91OSr-GRtaMxEo_AZg_q_ajQEMThWYFMIfcjwPsXGf9YkMhNMW_rM_sKm6imyk9L6fkmCqL_AzdvT8WjbPHtam8uyQnTFKtv3Jt7wh3DVfVd1W73_I1k7LJd7ruKyMwiZOXwUDB_S4MnYUS-93_oPQm8V92c6aEOi87Hw9QdYP38mPY-mgYt8DcvSNYH8kBnUO59pC4MjLz34TjJA3VqfsOtUJ1o-AyLDZfpoxmMAIhhfq9gpnfBVA4vK22h_a8RHTQH--H1VUUiHQFhQAQVVsXVMPq2RensvexaJDHhDyhz-g6IKct9dZx6PwnFlHXYsmMuzTeC2BTKhdRnag1ZDzNIA7Q0C7C-mnWFR7n63VtMyMrwWXJQHStkWP7C0KjQFOBQCeZbQyJdGVRCc0nSELCtsgKkgnahvm_9mxmv3AlYjXUkGcUGzMAzsgVQxFzFn23B3B4at9N1BB69gm6vtUMTIkBwUqHtwzQqEEs4WO7WDVYPluq23i1IrmXug8qkoykarPujcccII57plUcj99_vVPPbfjIq51PjmMHpFZxbqjKQZ-pNy-OOLgTVyZDgit8Pt3IAA",[\n]" > [2016-06-23 20:19:14,808] INFO > {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - > [2016-06-23 20:19:14,807] DEBUG - wire HTTP-Listener I/O dispatcher-1 >> > "[0x9]"resource":"https://analysis.windows.net/powerbi/api"[\n]"; > [2016-06-23 20:19:14,808] INFO > {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - > [2016-06-23 20:19:14,808] DEBUG - wire HTTP-Listener I/O dispatcher-1 >> "}" > [2016-06-23 20:19:14,852] INFO > {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - > [2016-06-23 20:19:14,852] ERROR - SynapseJsonPath #stringValueOf. Error > evaluating JSON Path <$.apiUrl>. Returning empty result. Error>>> invalid > path > [2016-06-23 20:19:14,856] INFO > {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - > [2016-06-23 20:19:14,856] ERROR - SynapseJsonPath #stringValueOf. Error > evaluating JSON Path <$.defaultRetentionPolicy>. Returning empty result. > Error>>> invalid path > [2016-06-23 20:19:14,859] INFO > {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - > [2016-06-23 20:19:14,859] ERROR - SynapseJsonPath #stringValueOf. Error > evaluating JSON Path <$.datasetName>. Returning empty result. Error>>> > invalid path > [2016-06-23 20:19:14,861] INFO > {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - > [2016-06-23 20:19:14,861] ERROR - SynapseJsonPath #stringValueOf. Error > evaluating JSON Path <$.tables>. Returning empty result. Error>>> invalid > path > [2016-06-23 20:19:14,862] INFO > {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - > [2016-06-23 20:19:14,862] ERROR - SynapseJsonPath #stringValueOf. Error > evaluating JSON Path <$.groupId>. Returning empty result. Error>>> invalid > path > [2016-06-23 20:19:14,863] INFO > {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - > [2016-06-23 20:19:14,863] ERROR - SynapseJsonPath #stringValueOf. Error > evaluating JSON Path <$.datasetId>. Returning empty result. Error>>> > invalid path > [2016-06-23 20:19:14,864] INFO > {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - > [2016-06-23 20:19:14,864] ERROR - SynapseJsonPath #stringValueOf. Error > evaluating JSON Path <$.tableName>. Returning empty result. Error>>> > invalid path > [2016-06-23 20:19:14,866] INFO > {org.wso2.carbon.automation.core.utils.coreutils.InputStreamHandler} - > [2016-06-23 20:19:14,865] ERROR - SynapseJsonPath #stringValueOf. Error > evaluating JSON Path <$.rows>. Returning empty result. Error>>> invalid path > [2016-06-23 20:19:14,867] INFO > {org.wso2.carbon.automati