Re: [Dev] [SP] What is our dashboard packaging modal

2018-07-10 Thread Udara Rathnayake
Also if we are to move EI/API Analytics to the SP, to ship the default
dashboard we will need this.

On Tue, Jul 10, 2018 at 3:15 PM, Lasantha Samarakoon 
wrote:

> +1 on that. This will be a must-have feature when it comes to solutions.
>
> Instead of aggregating FS stored dashboards with the DB stored dashboards,
> we can simply copy the predefined dashboards from the FS to DB on server
> startup.
>
> On Tue, Jul 10, 2018 at 3:01 PM Nisala Nanayakkara 
> wrote:
>
>> Hi Udara,
>>
>> Currently, we keep the widgets in the file system and the dashboard JSONs
>> in the database. So we have to copy/paste the widgets into the file system
>> and create a DB entry with the dashboard JSON using our REST API.
>>
>> But AFAIK your requirement is to support dashboard packaging in the build
>> time. Since we do not have the control over the DB at the build time. We
>> need to think about an alternative way of achieving your requirement.
>>
>> @Lasantha Samarakoon  Shall we provide a file system
>> location to keep the predefined dashboard JSONs? So that we can get an
>> aggregated value of file system dashboard JSONs and DB dashboard JSONs to
>> show it in dashboard listing page. WDYT?
>>
>> Thanks,
>> Nisala
>>
>> On Mon, Jul 9, 2018 at 9:48 PM Udara Rathnayake  wrote:
>>
>>> Similar to what we had earlier in DS do we have an option to package a
>>> dashboard?
>>>
>>> My requirement is to design/develop a custom dashboard with all
>>> dependencies then deploy in SP programmatically along with a streaming app.
>>> ​
>>>
>>> --
>>> Regards,
>>> UdaraR 
>>>
>>
>>
>> --
>> *Nisala Niroshana Nanayakkara,*
>> Senior Software Engineer
>> Mobile | +94 717600022
>> WSO2 Inc | http://wso2.com/
>>
>
>
> --
> *Lasantha Samarakoon* | Senior Software Engineer
> WSO2, Inc.
> #20, Palm Grove, Colombo 03, Sri Lanka
> 
> Mobile: +94 (71) 214 1576
> Email:  lasant...@wso2.com
> Web:www.wso2.com
>
> lean . enterprise . middleware
>



-- 
Regards,
UdaraR 
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Review & Merge the Pull Request

2018-07-10 Thread Sriskandarajah Suhothayan
Thanks for your contribution

On Wed, Jul 11, 2018 at 12:22 AM Minudika Malshan  wrote:

> Hi Senthuran,
>
> Thanks for your contribution.
> We have merged the PR.
>
>
>
>
> On Wed, Jul 11, 2018 at 12:15 AM, Senthuran Ambalavanar <
> senthuranr...@gmail.com> wrote:
>
>> Hi,
>>
>> Please review & merge the Pull Request [1]
>> , in which I have
>> fixed issue [2] .
>> [1]https://github.com/wso2/carbon-analytics/pull/1363
>> [2]https://github.com/wso2/product-sp/issues/695
>>
>> Thanks & Regards,
>> Senthuran.
>>
>
>
>
> --
> *Minudika Gammanpila*
> Software Engineer - WSO2
>
> Email   :  minud...@wso2.com
> Mobile :  +94715659887
> Web :  http://wso2.com
>
>  
>
-- 

*S. Suhothayan*
Director
*WSO2 Inc. *
http://wso2.com  


*cell: (+94) 779 756 757 | blog: http://suhothayan.blogspot.com/
twitter: http://twitter.com/suhothayan
 | linked-in:
http://lk.linkedin.com/in/suhothayan *
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Review & Merge the Pull Request

2018-07-10 Thread Minudika Malshan
Hi Senthuran,

Thanks for your contribution.
We have merged the PR.




On Wed, Jul 11, 2018 at 12:15 AM, Senthuran Ambalavanar <
senthuranr...@gmail.com> wrote:

> Hi,
>
> Please review & merge the Pull Request [1]
> , in which I have
> fixed issue [2] .
> [1]https://github.com/wso2/carbon-analytics/pull/1363
> [2]https://github.com/wso2/product-sp/issues/695
>
> Thanks & Regards,
> Senthuran.
>



-- 
*Minudika Gammanpila*
Software Engineer - WSO2

Email   :  minud...@wso2.com
Mobile :  +94715659887
Web :  http://wso2.com

 
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] Review & Merge the Pull Request

2018-07-10 Thread Senthuran Ambalavanar
Hi,

Please review & merge the Pull Request [1]
, in which I have fixed
issue [2] .
[1]https://github.com/wso2/carbon-analytics/pull/1363
[2]https://github.com/wso2/product-sp/issues/695

Thanks & Regards,
Senthuran.
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] WSO2 Log Mediator Leaking Memory

2018-07-10 Thread lalit_shah
Hi All,

We have implemented below logging for the Incoming request, Final response,
call mediator call, script call etc and could see that the memory
consumption has increased by 30 - 40%. We did testing with the same load
after removing logs and found that memory usage was very less.




















We took a heap dump and below are the findings.

About 240MB of 1.06GB (21.7%) of used heap is used to store the tracking
header string "Tracking-Id = dddf3, Event-Type = INBOUND, System-Name = XYZ,
Tag-Name = CACHE, Response-Code = null, get ...[length 191]" by
org.wso2.carbon.utils.logging.TenantAwareLoggingEvent.message object

Please suggest a way to overcome this issue as we need above logging pattern
for the monitoring solution.

Thanks.

Lalit




--
Sent from: http://wso2-oxygen-tank.10903.n7.nabble.com/WSO2-Development-f3.html
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Obtaining user attributes via authentication context.

2018-07-10 Thread Isurianuradha96
Hi Tharidu,

In this scenario, It's required to have an interactive UI configuration to
IDP. For that, I have implemented federated authenticator. Though I can
have a configuration file and do the process with restarting the server
it's out of the use case.  Is there a way to interact custom claim handler
with the UI?

Thank you

On Tue, Jul 10, 2018 at 8:19 PM Isurianuradha96 
wrote:

> Hi Tharidu,
>
> In this scenario, It's required to have an interactive UI configuration to
> IDP. For that, I have implemented federated authenticator. Though I can
> have a configuration file and do the process with restarting the server
> it's out of the use case.  Is there a way to interact custom claim
> handler with the UI?
>
> Thank you.
>
>
> On Tue, Jul 10, 2018 at 2:42 PM Tharindu Edirisinghe 
> wrote:
>
>> Hi Isuri,
>>
>> This is possible by writing a custom claim handler [1]. There, once the
>> user is authenticated, the user claims are available in the claims map.
>> Then you can find the particular claim and invoke the external service to
>> gather the other claims and add those extra claims also to the same map.
>> Then your client app will receive all the claims together. (note that the
>> claim handler globally affects all service providers and if you need to
>> apply the changes only to a particular service provider, then you may check
>> the SP name before executing this logic).
>>
>> Let us know if you face any difficulty when implementing this, so we can
>> assist you.
>>
>> [1] https://docs.wso2.com/display/IS540/Writing+a+Custom+Claim+Handler
>>
>> Thanks,
>> Tharindu Ediririsinghe
>>
>> On Tue, Jul 10, 2018 at 7:45 AM Isurianuradha96 <
>> isurianuradh...@gmail.com> wrote:
>>
>>> Hi all,
>>>
>>> I have come up with a scenario in WSO2IS which is required to first user
>>> needs to authenticate with primary usestore and get authenticated user's
>>> attributes. From user attributes list, I need to get a specific attribute
>>> which is pre-configured by the end user and then call
>>> an external web-service to obtain external claims. Thereafter, this
>>> external claim's values should be used in the response object to send to
>>> the client application.
>>>
>>> I have been trying to achieve this task by configuring two
>>> authentication steps in WSO2IS 5.4.0. As the first step, I used the basic
>>> local authenticator to authenticate the user via primary usestore. As the
>>> next step, I configured a custom federated authenticator which is
>>> implemented to call the external web service. In the second step, I need to
>>> get the user's attributes from the first step but I was not able to find a
>>> way to achieve this. I have been looking into the AuthenticationContext
>>> object to find the relevant attributes but I only found the subject
>>> identifier value of the authenticated user. According to my requirement,
>>> either subject identifier is needed to configure from the first step or
>>> searching through the pre-configured attribute from the attribute list
>>> which is received from the first step. My question is, is there any way to
>>> get the authenticated user's attribute list from the custom federated
>>> authenticator via AuthenticationContext object?
>>>
>>> If my above approach is not doable, please explain me to an alternative
>>> method to achieve this.
>>>
>>> Thank you.
>>>
>>> --
>>> Kind Regards,
>>> Isuri Anuradha.
>>> ___
>>> Dev mailing list
>>> Dev@wso2.org
>>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>>
>>
>>
>> --
>>
>> Tharindu Edirisinghe
>> Associate Technical Lead | WSO2 Inc
>> Platform Security Team
>> Blog : http://tharindue.blogspot.com
>> mobile : +94 775181586
>>
>
>
> --
> Kind Regards,
> Isuri Anuradha.
>


-- 
Kind Regards,
Isuri Anuradha.
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] [IS]Error while running IS in Windows machine

2018-07-10 Thread Dewni Weeraman
 Hi,

I built the product-is (wso2is-5.7.0-m3-SNAPSHOT) from source and tried
running it in my windows machine. While running the server I got the
following error logs in the terminal.

[2018-07-10 18:09:03,072]  INFO {org.wso2.carbon.humantask.
deployer.HumanTaskDep
loyer} -  Initializing HumanTask Deployer for tenant -1234.
[2018-07-10 18:09:04,971] FATAL {org.wso2.carbon.core.init.
CarbonServerManager}
-  WSO2 Carbon initialization Failed
org.apache.axiom.om.OMException: com.ctc.wstx.exc.WstxIOException: Invalid
UTF-8
 middle byte 0x3f (at char #2621, byte #-1)
at org.apache.axiom.om.impl.builder.StAXOMBuilder.next(
StAXOMBuilder.jav
a:296)
at org.apache.axiom.om.impl.llom.OMDocumentImpl.
getOMDocumentElement(OMD
ocumentImpl.java:109)
at org.apache.axiom.om.impl.builder.StAXOMBuilder.
getDocumentElement(StA
XOMBuilder.java:570)
at org.apache.axiom.om.impl.builder.StAXOMBuilder.
getDocumentElement(StA
XOMBuilder.java:566)
at org.apache.axis2.util.XMLUtils.toOM(XMLUtils.java:592)
at org.apache.axis2.util.XMLUtils.toOM(XMLUtils.java:575)
at org.apache.axis2.deployment.DescriptionBuilder.buildOM(
DescriptionBui
lder.java:97)
at org.apache.axis2.deployment.AxisConfigBuilder.
populateConfig(AxisConf
igBuilder.java:91)
at org.apache.axis2.deployment.DeploymentEngine.
populateAxisConfiguratio
n(DeploymentEngine.java:887)
at org.apache.axis2.deployment.FileSystemConfigurator.
getAxisConfigurati
on(FileSystemConfigurator.java:116)
at org.apache.axis2.context.ConfigurationContextFactory.
createConfigurat
ionContext(ConfigurationContextFactory.java:64)
at org.apache.axis2.context.ConfigurationContextFactory.
createConfigurat
ionContextFromFileSystem(ConfigurationContextFactory.java:210)
at org.wso2.carbon.core.init.CarbonServerManager.
getClientConfigurationC
ontext(CarbonServerManager.java:573)
at org.wso2.carbon.core.init.CarbonServerManager.
initializeCarbon(Carbon
ServerManager.java:458)
at org.wso2.carbon.core.init.CarbonServerManager.
removePendingItem(Carbo
nServerManager.java:291)
at org.wso2.carbon.core.init.PreAxis2ConfigItemListener.
bundleChanged(Pr
eAxis2ConfigItemListener.java:118)
at org.eclipse.osgi.framework.internal.core.
BundleContextImpl.dispatchEv
ent(BundleContextImpl.java:847)
at org.eclipse.osgi.framework.eventmgr.EventManager.
dispatchEvent(EventM
anager.java:230)
at org.eclipse.osgi.framework.eventmgr.EventManager$
EventThread.run(Even
tManager.java:340)
Caused by: com.ctc.wstx.exc.WstxIOException: Invalid UTF-8 middle byte 0x3f
(at
char #2621, byte #-1)
at com.ctc.wstx.sr.StreamScanner.constructFromIOE(
StreamScanner.java:625
)
at com.ctc.wstx.sr.StreamScanner.loadMore(StreamScanner.java:997)
at com.ctc.wstx.sr.StreamScanner.getNext(StreamScanner.java:754)
at com.ctc.wstx.sr.BasicStreamReader.nextFromProlog(
BasicStreamReader.ja
va:2000)
at com.ctc.wstx.sr.BasicStreamReader.next(
BasicStreamReader.java:1134)
at org.apache.axiom.om.impl.builder.StAXOMBuilder.
parserNext(StAXOMBuild
er.java:681)
at org.apache.axiom.om.impl.builder.StAXOMBuilder.next(
StAXOMBuilder.jav
a:214)
... 18 more
Caused by: java.io.CharConversionException: Invalid UTF-8 middle byte 0x3f
(at c
har #2621, byte #-1)
at com.ctc.wstx.io.UTF8Reader.reportInvalidOther(UTF8Reader.
java:314)
at com.ctc.wstx.io.UTF8Reader.read(UTF8Reader.java:212)
at com.ctc.wstx.io.ReaderSource.readInto(ReaderSource.java:87)
at com.ctc.wstx.io.BranchingReaderSource.readInto(
BranchingReaderSource.
java:57)
at com.ctc.wstx.sr.StreamScanner.loadMore(StreamScanner.java:991)
... 23 more



However when I download Identity Server 5.7.0 M2 version and run it, I
didn't get the above error. The server start up was successful.

Any help on this is appreciated.

Best Regards,
Dewni Weeraman
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [SP] What is our dashboard packaging modal

2018-07-10 Thread Lasantha Samarakoon
+1 on that. This will be a must-have feature when it comes to solutions.

Instead of aggregating FS stored dashboards with the DB stored dashboards,
we can simply copy the predefined dashboards from the FS to DB on server
startup.

On Tue, Jul 10, 2018 at 3:01 PM Nisala Nanayakkara  wrote:

> Hi Udara,
>
> Currently, we keep the widgets in the file system and the dashboard JSONs
> in the database. So we have to copy/paste the widgets into the file system
> and create a DB entry with the dashboard JSON using our REST API.
>
> But AFAIK your requirement is to support dashboard packaging in the build
> time. Since we do not have the control over the DB at the build time. We
> need to think about an alternative way of achieving your requirement.
>
> @Lasantha Samarakoon  Shall we provide a file system
> location to keep the predefined dashboard JSONs? So that we can get an
> aggregated value of file system dashboard JSONs and DB dashboard JSONs to
> show it in dashboard listing page. WDYT?
>
> Thanks,
> Nisala
>
> On Mon, Jul 9, 2018 at 9:48 PM Udara Rathnayake  wrote:
>
>> Similar to what we had earlier in DS do we have an option to package a
>> dashboard?
>>
>> My requirement is to design/develop a custom dashboard with all
>> dependencies then deploy in SP programmatically along with a streaming app.
>> ​
>>
>> --
>> Regards,
>> UdaraR 
>>
>
>
> --
> *Nisala Niroshana Nanayakkara,*
> Senior Software Engineer
> Mobile | +94 717600022
> WSO2 Inc | http://wso2.com/
>


-- 
*Lasantha Samarakoon* | Senior Software Engineer
WSO2, Inc.
#20, Palm Grove, Colombo 03, Sri Lanka
Mobile: +94 (71) 214 1576
Email:  lasant...@wso2.com
Web:www.wso2.com

lean . enterprise . middleware
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [SP] What is our dashboard packaging modal

2018-07-10 Thread Nisala Nanayakkara
Hi Udara,

Currently, we keep the widgets in the file system and the dashboard JSONs
in the database. So we have to copy/paste the widgets into the file system
and create a DB entry with the dashboard JSON using our REST API.

But AFAIK your requirement is to support dashboard packaging in the build
time. Since we do not have the control over the DB at the build time. We
need to think about an alternative way of achieving your requirement.

@Lasantha Samarakoon  Shall we provide a file system
location to keep the predefined dashboard JSONs? So that we can get an
aggregated value of file system dashboard JSONs and DB dashboard JSONs to
show it in dashboard listing page. WDYT?

Thanks,
Nisala

On Mon, Jul 9, 2018 at 9:48 PM Udara Rathnayake  wrote:

> Similar to what we had earlier in DS do we have an option to package a
> dashboard?
>
> My requirement is to design/develop a custom dashboard with all
> dependencies then deploy in SP programmatically along with a streaming app.
> ​
>
> --
> Regards,
> UdaraR 
>


-- 
*Nisala Niroshana Nanayakkara,*
Senior Software Engineer
Mobile | +94 717600022
WSO2 Inc | http://wso2.com/
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Obtaining user attributes via authentication context.

2018-07-10 Thread Tharindu Edirisinghe
Hi Isuri,

This is possible by writing a custom claim handler [1]. There, once the
user is authenticated, the user claims are available in the claims map.
Then you can find the particular claim and invoke the external service to
gather the other claims and add those extra claims also to the same map.
Then your client app will receive all the claims together. (note that the
claim handler globally affects all service providers and if you need to
apply the changes only to a particular service provider, then you may check
the SP name before executing this logic).

Let us know if you face any difficulty when implementing this, so we can
assist you.

[1] https://docs.wso2.com/display/IS540/Writing+a+Custom+Claim+Handler

Thanks,
Tharindu Ediririsinghe

On Tue, Jul 10, 2018 at 7:45 AM Isurianuradha96 
wrote:

> Hi all,
>
> I have come up with a scenario in WSO2IS which is required to first user
> needs to authenticate with primary usestore and get authenticated user's
> attributes. From user attributes list, I need to get a specific attribute
> which is pre-configured by the end user and then call
> an external web-service to obtain external claims. Thereafter, this
> external claim's values should be used in the response object to send to
> the client application.
>
> I have been trying to achieve this task by configuring two authentication
> steps in WSO2IS 5.4.0. As the first step, I used the basic local
> authenticator to authenticate the user via primary usestore. As the next
> step, I configured a custom federated authenticator which is implemented to
> call the external web service. In the second step, I need to get the user's
> attributes from the first step but I was not able to find a way to achieve
> this. I have been looking into the AuthenticationContext object to find the
> relevant attributes but I only found the subject identifier value of the
> authenticated user. According to my requirement, either subject identifier
> is needed to configure from the first step or searching through the
> pre-configured attribute from the attribute list which is received from the
> first step. My question is, is there any way to get the authenticated
> user's attribute list from the custom federated authenticator via
> AuthenticationContext object?
>
> If my above approach is not doable, please explain me to an alternative
> method to achieve this.
>
> Thank you.
>
> --
> Kind Regards,
> Isuri Anuradha.
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>


-- 

Tharindu Edirisinghe
Associate Technical Lead | WSO2 Inc
Platform Security Team
Blog : http://tharindue.blogspot.com
mobile : +94 775181586
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev