Return-Path: X-Original-To: apmail-stratos-dev-archive@minotaur.apache.org Delivered-To: apmail-stratos-dev-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 4C9A010ECF for ; Sun, 21 Dec 2014 16:28:51 +0000 (UTC) Received: (qmail 12433 invoked by uid 500); 21 Dec 2014 16:28:51 -0000 Delivered-To: apmail-stratos-dev-archive@stratos.apache.org Received: (qmail 12369 invoked by uid 500); 21 Dec 2014 16:28:51 -0000 Mailing-List: contact dev-help@stratos.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@stratos.apache.org Delivered-To: mailing list dev@stratos.apache.org Received: (qmail 12359 invoked by uid 99); 21 Dec 2014 16:28:50 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 21 Dec 2014 16:28:50 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of udara@wso2.com designates 209.85.220.50 as permitted sender) Received: from [209.85.220.50] (HELO mail-pa0-f50.google.com) (209.85.220.50) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 21 Dec 2014 16:28:24 +0000 Received: by mail-pa0-f50.google.com with SMTP id bj1so4423341pad.9 for ; Sun, 21 Dec 2014 08:26:07 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=wso2.com; s=google; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :content-type; bh=0Qxp1nCT3n2MLc6iNFDS3gqD6wtMm3DDBk+gu2ZDcBE=; b=eBBNUK23Dr7mCv1HgaRlVSwbVb9U1dSDXEc5MEt22ZP16lte9fnDVWXxw5UrjqQRJY BKY6xiH6vmaAiSurSp9Sx5vmkG0QuMAw3i9TJH737EwFm2MKwk36KnzaIuMqH0ktGcDz IbgJ6DcNRF7Vb8KofnkDy6wbLk3A/t20y3fR4= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:content-type; bh=0Qxp1nCT3n2MLc6iNFDS3gqD6wtMm3DDBk+gu2ZDcBE=; b=QPAcs2n+A/l8dU0GYTgxLNv852ognKrPyA8p4pyRbj9Q5q1+8CVO6NCBkPIGzC39hz lwyoILd/7MeR8SsIpyD0Eui+tiTlXaobRI07W50RdySpuOoldDKo/sR/X15XRMDcJWc+ 154Bq2XxOPY+P75n3ntzhAk/nztLgVCmuIJMDkhaQ0LFCDJuHCGvKviXPWEbb7BZqiyJ pZVaxm1T9XbiDLMyYJB1fT5/TtoYol6VGaA78BRAitLLUyh9ChzbIr0DWr7aKyaRlC5+ +UnF5mBljQOhogDHURgdg00tYBwABNB2mrcwPKYfd/6k4O1NrNnI1bPZlv/3M5RoW9oI uStw== X-Gm-Message-State: ALoCoQl5u9JQ0jpkVcPXPJgwKZBIB/zxSPKQ2Q7GAK85RxwdkSoO+IIKTd2oqvXlkiicWvK5A42T X-Received: by 10.66.140.102 with SMTP id rf6mr28339169pab.1.1419179167286; Sun, 21 Dec 2014 08:26:07 -0800 (PST) MIME-Version: 1.0 Received: by 10.70.94.103 with HTTP; Sun, 21 Dec 2014 08:25:27 -0800 (PST) In-Reply-To: References: From: Udara Liyanage Date: Sun, 21 Dec 2014 21:55:27 +0530 Message-ID: Subject: Re: Why application is parsed twice To: dev Content-Type: multipart/alternative; boundary=001a113313d223a2d2050abc66cd X-Virus-Checked: Checked by ClamAV on apache.org --001a113313d223a2d2050abc66cd Content-Type: text/plain; charset=UTF-8 Hi Imesh, Below are the admin services using and operations OAuthAdminService - registerOAuthApplicationData IdentityApplicationManagementService - createApplication, getApplication, updateApplication Since authentication handlers does not set the carbon context, there is no way of identifying the user at component level. Thus added a JWT based authenticator, so every admin called is to be authenticated. This is why you see many logs On Sun, Dec 21, 2014 at 8:39 PM, Imesh Gunaratne wrote: > > Can you please explain those admin calls Udara? > I can see ten user logins for an application having two cartridges for one > application parse process: > > [2014-12-21 04:21:56,892] INFO > {org.apache.stratos.autoscaler.api.AutoScalerServiceImpl} - Starting to > add application: [application-id] single-group-app > [2014-12-21 04:21:57,005] INFO > {org.wso2.carbon.core.services.util.CarbonAuthenticationUtil} - > 'admin@carbon.super [-1234]' logged in at [2014-12-21 04:21:57,005+0530] > [2014-12-21 04:21:57,041] INFO > {org.wso2.carbon.core.services.util.CarbonAuthenticationUtil} - > 'admin@carbon.super [-1234]' logged in at [2014-12-21 04:21:57,041+0530] > [2014-12-21 04:21:57,064] INFO > {org.wso2.carbon.core.services.util.CarbonAuthenticationUtil} - > 'admin@carbon.super [-1234]' logged in at [2014-12-21 04:21:57,064+0530] > [2014-12-21 04:21:57,093] INFO > {org.wso2.carbon.core.services.util.CarbonAuthenticationUtil} - > 'admin@carbon.super [-1234]' logged in at [2014-12-21 04:21:57,093+0530] > [2014-12-21 04:21:57,134] INFO > {org.wso2.carbon.core.services.util.CarbonAuthenticationUtil} - > 'admin@carbon.super [-1234]' logged in at [2014-12-21 04:21:57,134+0530] > [2014-12-21 04:21:57,902] INFO > {org.wso2.carbon.core.services.util.CarbonAuthenticationUtil} - > 'admin@carbon.super [-1234]' logged in at [2014-12-21 04:21:57,902+0530] > [2014-12-21 04:21:57,912] INFO > {org.wso2.carbon.core.services.util.CarbonAuthenticationUtil} - > 'admin@carbon.super [-1234]' logged in at [2014-12-21 04:21:57,911+0530] > [2014-12-21 04:21:57,922] INFO > {org.wso2.carbon.core.services.util.CarbonAuthenticationUtil} - > 'admin@carbon.super [-1234]' logged in at [2014-12-21 04:21:57,922+0530] > [2014-12-21 04:21:57,934] INFO > {org.wso2.carbon.core.services.util.CarbonAuthenticationUtil} - > 'admin@carbon.super [-1234]' logged in at [2014-12-21 04:21:57,934+0530] > [2014-12-21 04:21:57,957] INFO > {org.wso2.carbon.core.services.util.CarbonAuthenticationUtil} - > 'admin@carbon.super [-1234]' logged in at [2014-12-21 04:21:57,957+0530] > [2014-12-21 04:21:57,976] INFO > {org.apache.stratos.autoscaler.applications.parser.DefaultApplicationParser} > - Application with id single-group-app parsed successfully > > Thanks > > On Sun, Dec 21, 2014 at 6:22 PM, Udara Liyanage wrote: > >> Hi, >> >> Token generation has 2,3 admin calls and since token is generated twice >> per application (since application is parsed twice). That is why you see >> many logging logs. >> >> >> >> Touched, not typed. Erroneous words are a feature, not a typo. >> > > > > -- > Imesh Gunaratne > > Technical Lead, WSO2 > Committer & PMC Member, Apache Stratos > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 --001a113313d223a2d2050abc66cd Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Hi Imesh,

Below are the admi= n services using and operations

OAuthAdminService = - registerOAuthApplicationData
IdentityApplicationManagementServi= ce - createApplication, getApplication, updateApplication

Since authentication handlers does not set the carbon context, ther= e is no way of identifying the user at component level. Thus added a JWT ba= sed authenticator, so every admin called is to be authenticated. This is wh= y you see many logs

On Sun, Dec 21, 2014 at 8:39 PM, Imesh Gunaratne <imesh@apach= e.org> wrote:
= Can you please explain those admin calls Udara?=C2=A0
I can see ten use= r logins for an application having two cartridges for one application parse= process:

[2014-12-21 04:21:56,892] =C2=A0INFO {org= .apache.stratos.autoscaler.api.AutoScalerServiceImpl} - =C2=A0Starting to a= dd application: [application-id] single-group-app
[2014-12-21 04:= 21:57,005] =C2=A0INFO {org.wso2.carbon.core.services.util.CarbonAuthenticat= ionUtil} - =C2=A0'admin@carbon.super [-1234]' logged in at [2014-12= -21 04:21:57,005+0530]
[2014-12-21 04:21:57,041] =C2=A0INFO {org.= wso2.carbon.core.services.util.CarbonAuthenticationUtil} - =C2=A0'admin= @carbon.super [-1234]' logged in at [2014-12-21 04:21:57,041+0530]
[2014-12-21 04:21:57,064] =C2=A0INFO {org.wso2.carbon.core.services.u= til.CarbonAuthenticationUtil} - =C2=A0'admin@carbon.super [-1234]' = logged in at [2014-12-21 04:21:57,064+0530]
[2014-12-21 04:21:57,= 093] =C2=A0INFO {org.wso2.carbon.core.services.util.CarbonAuthenticationUti= l} - =C2=A0'admin@carbon.super [-1234]' logged in at [2014-12-21 04= :21:57,093+0530]
[2014-12-21 04:21:57,134] =C2=A0INFO {org.wso2.c= arbon.core.services.util.CarbonAuthenticationUtil} - =C2=A0'admin@carbo= n.super [-1234]' logged in at [2014-12-21 04:21:57,134+0530]
= [2014-12-21 04:21:57,902] =C2=A0INFO {org.wso2.carbon.core.services.util.Ca= rbonAuthenticationUtil} - =C2=A0'admin@carbon.super [-1234]' logged= in at [2014-12-21 04:21:57,902+0530]
[2014-12-21 04:21:57,912] = =C2=A0INFO {org.wso2.carbon.core.services.util.CarbonAuthenticationUtil} - = =C2=A0'admin@carbon.super [-1234]' logged in at [2014-12-21 04:21:5= 7,911+0530]
[2014-12-21 04:21:57,922] =C2=A0INFO {org.wso2.carbon= .core.services.util.CarbonAuthenticationUtil} - =C2=A0'admin@carbon.sup= er [-1234]' logged in at [2014-12-21 04:21:57,922+0530]
[2014= -12-21 04:21:57,934] =C2=A0INFO {org.wso2.carbon.core.services.util.CarbonA= uthenticationUtil} - =C2=A0'admin@carbon.super [-1234]' logged in a= t [2014-12-21 04:21:57,934+0530]
[2014-12-21 04:21:57,957] =C2=A0= INFO {org.wso2.carbon.core.services.util.CarbonAuthenticationUtil} - =C2=A0= 'admin@carbon.super [-1234]' logged in at [2014-12-21 04:21:57,957+= 0530]
[2014-12-21 04:21:57,976] =C2=A0INFO {org.apache.stratos.au= toscaler.applications.parser.DefaultApplicationParser} - =C2=A0Application = with id single-group-app parsed successfully

Thank= s

On Sun, Dec 21, 2014 at 6:2= 2 PM, Udara Liyanage <udara@wso2.com> wrote:

Hi,

Token generation has 2,3 admin calls and since token is gene= rated twice per application (since application is parsed twice). That is wh= y you see many logging logs.



Touched, not typed. Erroneous words are a feature, not a typ= o.




<= div class=3D"HOEnZb">
--
Imesh G= unaratne

Technical Lead, WSO2
Com= mitter & PMC Member, Apache Stratos


--
--001a113313d223a2d2050abc66cd--