You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@stratos.apache.org by Rajkumar Rajaratnam <ra...@wso2.com> on 2014/10/11 03:11:59 UTC

How we can change the logging format in Stratos?

Hi,

Can we configure the logging format?

Currently we are logging in the format like below;

TID: [0] [STRATOS] [2014-10-11 06:39:05,722]  INFO
{org.apache.stratos.autoscaler.rule.RuleLog} -  Running minimum rule:
[kub-cluster] KubGrp1 [cluster] myphp.php.domain
{org.apache.stratos.autoscaler.rule.RuleLog}
TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
{org.apache.stratos.autoscaler.rule.RuleLog} -  [min-check]  [cluster] :
myphp.php.domain [Replicas] nonTerminated : 2
{org.apache.stratos.autoscaler.rule.RuleLog}
TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
{org.apache.stratos.autoscaler.rule.RuleLog} -  [min-check]  [cluster] :
myphp.php.domain [Replicas] minReplicas : 2
{org.apache.stratos.autoscaler.rule.RuleLog}
TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
{org.apache.stratos.autoscaler.rule.RuleLog} -  Running obsolete containers
rule [kub-cluster] : KubGrp1 [cluster] : myphp.php.domain
{org.apache.stratos.autoscaler.rule.RuleLog}
TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
{org.apache.stratos.autoscaler.rule.RuleLog} -  [obsolete-check] [cluster]
: myphp.php.domain [Replicas] obsoleteReplicas : 0
{org.apache.stratos.autoscaler.rule.RuleLog}
TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
{org.apache.stratos.autoscaler.rule.RuleLog} -  Running scaling rule
[kub-cluster] : KubGrp1 [cluster] : myphp.php.domain
{org.apache.stratos.autoscaler.rule.RuleLog}
TID: [0] [STRATOS] [2014-10-11 06:39:05,724]  INFO
{org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
myphp.php.domain [Replicas] nonTerminated : 2
{org.apache.stratos.autoscaler.rule.RuleLog}
TID: [0] [STRATOS] [2014-10-11 06:39:05,724]  INFO
{org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
myphp.php.domain [Replicas] minReplicas : 2
{org.apache.stratos.autoscaler.rule.RuleLog}
TID: [0] [STRATOS] [2014-10-11 06:39:05,725]  INFO
{org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
myphp.php.domain [Replicas] maxReplicas : 20
{org.apache.stratos.autoscaler.rule.RuleLog}
TID: [0] [STRATOS] [2014-10-11 06:39:05,725]  INFO
{org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
myphp.php.domain [RequestInFlight] resetted ? : false
{org.apache.stratos.autoscaler.rule.RuleLog}
TID: [0] [STRATOS] [2014-10-11 06:39:05,725]  INFO
{org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
myphp.php.domain [RequestInFlight] predicted value : 0.0
{org.apache.stratos.autoscaler.rule.RuleLog}
TID: [0] [STRATOS] [2014-10-11 06:39:05,726]  INFO
{org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
myphp.php.domain [RequestInFlight] upper limit : 80.0
{org.apache.stratos.autoscaler.rule.RuleLog}
TID: [0] [STRATOS] [2014-10-11 06:39:05,726]  INFO
{org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
myphp.php.domain [RequestInFlight] lower limit : 5.0
{org.apache.stratos.autoscaler.rule.RuleLog}
TID: [0] [STRATOS] [2014-10-11 06:39:05,726]  INFO
{org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
myphp.php.domain [MemoryConsumption] resetted ? : true
{org.apache.stratos.autoscaler.rule.RuleLog}
TID: [0] [STRATOS] [2014-10-11 06:39:05,727]  INFO
{org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
myphp.php.domain [MemoryConsumption] predicted value : 29.142266099066546
{org.apache.stratos.autoscaler.rule.RuleLog}
TID: [0] [STRATOS] [2014-10-11 06:39:05,727]  INFO
{org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
myphp.php.domain [MemoryConsumption] upper limit : 80.0
{org.apache.stratos.autoscaler.rule.RuleLog}
TID: [0] [STRATOS] [2014-10-11 06:39:05,727]  INFO
{org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
myphp.php.domain [MemoryConsumption] lower limit : 15.0
{org.apache.stratos.autoscaler.rule.RuleLog}
TID: [0] [STRATOS] [2014-10-11 06:39:05,728]  INFO
{org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
myphp.php.domain [LoadAverage] resetted ? : true
{org.apache.stratos.autoscaler.rule.RuleLog}
TID: [0] [STRATOS] [2014-10-11 06:39:05,728]  INFO
{org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
myphp.php.domain [LoadAverage] predicted value : 2.70735374011565
{org.apache.stratos.autoscaler.rule.RuleLog}
TID: [0] [STRATOS] [2014-10-11 06:39:05,729]  INFO
{org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
myphp.php.domain [LoadAverage] upper limit : 180.0
{org.apache.stratos.autoscaler.rule.RuleLog}
TID: [0] [STRATOS] [2014-10-11 06:39:05,729]  INFO
{org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
myphp.php.domain [LoadAverage] lower limit : 100.0
{org.apache.stratos.autoscaler.rule.RuleLog}
TID: [0] [STRATOS] [2014-10-11 06:39:05,729]  INFO
{org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
myphp.php.domain scale-up action : false
{org.apache.stratos.autoscaler.rule.RuleLog}
TID: [0] [STRATOS] [2014-10-11 06:39:05,730]  INFO
{org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
myphp.php.domain scale-down action : false
{org.apache.stratos.autoscaler.rule.RuleLog}
TID: [0] [STRATOS] [2014-10-11 06:39:05,731]  INFO
{org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling] No decision made
to either scale up or down ...  {org.apache.stratos.autoscaler.rule.RuleLog}


How can I remove the TID part and Stratos part when logging?

Thanks.


-- 
Rajkumar Rajaratnam
Software Engineer | WSO2, Inc.
Mobile +94777568639 | +94783498120

Re: How we can change the logging format in Stratos?

Posted by Sajith Kariyawasam <sa...@wso2.com>.
committed to both container-autoscaling and master branches

On Sat, Oct 11, 2014 at 8:06 AM, Rajkumar Rajaratnam <ra...@wso2.com>
wrote:

>
>
> On Sat, Oct 11, 2014 at 7:59 AM, Sajith Kariyawasam <sa...@wso2.com>
> wrote:
>
>> Hi,
>>
>> Haven't noticed this until now :)
>>
>> in og4j.appender.CARBON_LOGFILE.layout.ConversionPattern=TID: [%T] [%S]
>> [%d] %P%5p *{%c}* - %x %m* {%c}*%n
>> %c appears twice, which lets the class name to logged twice
>> I think we should remove that, thanks Raj or pointing out!
>>
>
> Thanks Sajith. Can you fix and commit it to container-autoscaling branch?
>
>
>> Thanks,
>> Sajith
>>
>> On Sat, Oct 11, 2014 at 6:50 AM, Rajkumar Rajaratnam <ra...@wso2.com>
>> wrote:
>>
>>> Hi,
>>>
>>> On Sat, Oct 11, 2014 at 6:44 AM, Nirmal Fernando <nirmal070125@gmail.com
>>> > wrote:
>>>
>>>> Why do you want to remove TID part? It stands for Tenant ID.
>>>>
>>>
>>> I didn't meant to remove it from code base. I wanted to do it locally in
>>> my running setup so that I can clearly observe the scaling logs. It is very
>>> lengthy now. And the logging class name
>>> ({org.apache.stratos.autoscaler.rule.RuleLog}) printed twice at the start
>>> and the end.
>>>
>>>
>>>> All these can be configured via log4j.properties files corresponding
>>>> Appenders.
>>>>
>>>
>>> Thanks, I will check that.
>>>
>>>
>>>>
>>>> On Sat, Oct 11, 2014 at 6:41 AM, Rajkumar Rajaratnam <
>>>> rajkumarr@wso2.com> wrote:
>>>>
>>>>> Hi,
>>>>>
>>>>> Can we configure the logging format?
>>>>>
>>>>> Currently we are logging in the format like below;
>>>>>
>>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,722]  INFO
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  Running minimum rule:
>>>>> [kub-cluster] KubGrp1 [cluster] myphp.php.domain
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [min-check]  [cluster] :
>>>>> myphp.php.domain [Replicas] nonTerminated : 2
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [min-check]  [cluster] :
>>>>> myphp.php.domain [Replicas] minReplicas : 2
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  Running obsolete containers
>>>>> rule [kub-cluster] : KubGrp1 [cluster] : myphp.php.domain
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [obsolete-check] [cluster]
>>>>> : myphp.php.domain [Replicas] obsoleteReplicas : 0
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  Running scaling rule
>>>>> [kub-cluster] : KubGrp1 [cluster] : myphp.php.domain
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,724]  INFO
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>>> myphp.php.domain [Replicas] nonTerminated : 2
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,724]  INFO
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>>> myphp.php.domain [Replicas] minReplicas : 2
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,725]  INFO
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>>> myphp.php.domain [Replicas] maxReplicas : 20
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,725]  INFO
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>>> myphp.php.domain [RequestInFlight] resetted ? : false
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,725]  INFO
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>>> myphp.php.domain [RequestInFlight] predicted value : 0.0
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,726]  INFO
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>>> myphp.php.domain [RequestInFlight] upper limit : 80.0
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,726]  INFO
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>>> myphp.php.domain [RequestInFlight] lower limit : 5.0
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,726]  INFO
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>>> myphp.php.domain [MemoryConsumption] resetted ? : true
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,727]  INFO
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>>> myphp.php.domain [MemoryConsumption] predicted value : 29.142266099066546
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,727]  INFO
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>>> myphp.php.domain [MemoryConsumption] upper limit : 80.0
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,727]  INFO
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>>> myphp.php.domain [MemoryConsumption] lower limit : 15.0
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,728]  INFO
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>>> myphp.php.domain [LoadAverage] resetted ? : true
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,728]  INFO
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>>> myphp.php.domain [LoadAverage] predicted value : 2.70735374011565
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,729]  INFO
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>>> myphp.php.domain [LoadAverage] upper limit : 180.0
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,729]  INFO
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>>> myphp.php.domain [LoadAverage] lower limit : 100.0
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,729]  INFO
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>>> myphp.php.domain scale-up action : false
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,730]  INFO
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>>> myphp.php.domain scale-down action : false
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,731]  INFO
>>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling] No decision made
>>>>> to either scale up or down ...  {org.apache.stratos.autoscaler.rule.RuleLog}
>>>>>
>>>>>
>>>>> How can I remove the TID part and Stratos part when logging?
>>>>>
>>>>> Thanks.
>>>>>
>>>>>
>>>>> --
>>>>> Rajkumar Rajaratnam
>>>>> Software Engineer | WSO2, Inc.
>>>>> Mobile +94777568639 | +94783498120
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> Best Regards,
>>>> Nirmal
>>>>
>>>> Nirmal Fernando.
>>>> PPMC Member & Committer of Apache Stratos,
>>>> Senior Software Engineer, WSO2 Inc.
>>>>
>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>
>>>
>>>
>>>
>>> --
>>> Rajkumar Rajaratnam
>>> Software Engineer | WSO2, Inc.
>>> Mobile +94777568639 | +94783498120
>>>
>>
>>
>>
>> --
>> *Sajith Kariyawasam*
>>
>>
>> *Committer and PMC member, Apache Stratos,WSO2 Inc., http://wso2.com
>> <http://wso2.com>AMIE (SL)Mobile: +94772269575*
>>
>
>
>
> --
> Rajkumar Rajaratnam
> Software Engineer | WSO2, Inc.
> Mobile +94777568639 | +94783498120
>



-- 
*Sajith Kariyawasam*


*Committer and PMC member, Apache Stratos,WSO2 Inc., http://wso2.com
<http://wso2.com>AMIE (SL)Mobile: +94772269575*

Re: How we can change the logging format in Stratos?

Posted by Rajkumar Rajaratnam <ra...@wso2.com>.
On Sat, Oct 11, 2014 at 7:59 AM, Sajith Kariyawasam <sa...@wso2.com> wrote:

> Hi,
>
> Haven't noticed this until now :)
>
> in og4j.appender.CARBON_LOGFILE.layout.ConversionPattern=TID: [%T] [%S]
> [%d] %P%5p *{%c}* - %x %m* {%c}*%n
> %c appears twice, which lets the class name to logged twice
> I think we should remove that, thanks Raj or pointing out!
>

Thanks Sajith. Can you fix and commit it to container-autoscaling branch?


> Thanks,
> Sajith
>
> On Sat, Oct 11, 2014 at 6:50 AM, Rajkumar Rajaratnam <ra...@wso2.com>
> wrote:
>
>> Hi,
>>
>> On Sat, Oct 11, 2014 at 6:44 AM, Nirmal Fernando <ni...@gmail.com>
>> wrote:
>>
>>> Why do you want to remove TID part? It stands for Tenant ID.
>>>
>>
>> I didn't meant to remove it from code base. I wanted to do it locally in
>> my running setup so that I can clearly observe the scaling logs. It is very
>> lengthy now. And the logging class name
>> ({org.apache.stratos.autoscaler.rule.RuleLog}) printed twice at the start
>> and the end.
>>
>>
>>> All these can be configured via log4j.properties files corresponding
>>> Appenders.
>>>
>>
>> Thanks, I will check that.
>>
>>
>>>
>>> On Sat, Oct 11, 2014 at 6:41 AM, Rajkumar Rajaratnam <rajkumarr@wso2.com
>>> > wrote:
>>>
>>>> Hi,
>>>>
>>>> Can we configure the logging format?
>>>>
>>>> Currently we are logging in the format like below;
>>>>
>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,722]  INFO
>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  Running minimum rule:
>>>> [kub-cluster] KubGrp1 [cluster] myphp.php.domain
>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [min-check]  [cluster] :
>>>> myphp.php.domain [Replicas] nonTerminated : 2
>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [min-check]  [cluster] :
>>>> myphp.php.domain [Replicas] minReplicas : 2
>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  Running obsolete containers
>>>> rule [kub-cluster] : KubGrp1 [cluster] : myphp.php.domain
>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [obsolete-check] [cluster]
>>>> : myphp.php.domain [Replicas] obsoleteReplicas : 0
>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  Running scaling rule
>>>> [kub-cluster] : KubGrp1 [cluster] : myphp.php.domain
>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,724]  INFO
>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>> myphp.php.domain [Replicas] nonTerminated : 2
>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,724]  INFO
>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>> myphp.php.domain [Replicas] minReplicas : 2
>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,725]  INFO
>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>> myphp.php.domain [Replicas] maxReplicas : 20
>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,725]  INFO
>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>> myphp.php.domain [RequestInFlight] resetted ? : false
>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,725]  INFO
>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>> myphp.php.domain [RequestInFlight] predicted value : 0.0
>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,726]  INFO
>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>> myphp.php.domain [RequestInFlight] upper limit : 80.0
>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,726]  INFO
>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>> myphp.php.domain [RequestInFlight] lower limit : 5.0
>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,726]  INFO
>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>> myphp.php.domain [MemoryConsumption] resetted ? : true
>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,727]  INFO
>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>> myphp.php.domain [MemoryConsumption] predicted value : 29.142266099066546
>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,727]  INFO
>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>> myphp.php.domain [MemoryConsumption] upper limit : 80.0
>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,727]  INFO
>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>> myphp.php.domain [MemoryConsumption] lower limit : 15.0
>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,728]  INFO
>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>> myphp.php.domain [LoadAverage] resetted ? : true
>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,728]  INFO
>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>> myphp.php.domain [LoadAverage] predicted value : 2.70735374011565
>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,729]  INFO
>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>> myphp.php.domain [LoadAverage] upper limit : 180.0
>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,729]  INFO
>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>> myphp.php.domain [LoadAverage] lower limit : 100.0
>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,729]  INFO
>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>> myphp.php.domain scale-up action : false
>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,730]  INFO
>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>>> myphp.php.domain scale-down action : false
>>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,731]  INFO
>>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling] No decision made
>>>> to either scale up or down ...  {org.apache.stratos.autoscaler.rule.RuleLog}
>>>>
>>>>
>>>> How can I remove the TID part and Stratos part when logging?
>>>>
>>>> Thanks.
>>>>
>>>>
>>>> --
>>>> Rajkumar Rajaratnam
>>>> Software Engineer | WSO2, Inc.
>>>> Mobile +94777568639 | +94783498120
>>>>
>>>
>>>
>>>
>>> --
>>> Best Regards,
>>> Nirmal
>>>
>>> Nirmal Fernando.
>>> PPMC Member & Committer of Apache Stratos,
>>> Senior Software Engineer, WSO2 Inc.
>>>
>>> Blog: http://nirmalfdo.blogspot.com/
>>>
>>
>>
>>
>> --
>> Rajkumar Rajaratnam
>> Software Engineer | WSO2, Inc.
>> Mobile +94777568639 | +94783498120
>>
>
>
>
> --
> *Sajith Kariyawasam*
>
>
> *Committer and PMC member, Apache Stratos,WSO2 Inc., http://wso2.com
> <http://wso2.com>AMIE (SL)Mobile: +94772269575*
>



-- 
Rajkumar Rajaratnam
Software Engineer | WSO2, Inc.
Mobile +94777568639 | +94783498120

Re: How we can change the logging format in Stratos?

Posted by Sajith Kariyawasam <sa...@wso2.com>.
I already did. See my reply above

On Mon, Oct 13, 2014 at 11:50 AM, Isuru Haththotuwa <is...@apache.org>
wrote:

>
>
> On Mon, Oct 13, 2014 at 11:13 AM, Isuru Perera <is...@wso2.com> wrote:
>
>> We should remove the duplicate class name from logs
>>
> +1
>
>>
>> On Mon, Oct 13, 2014 at 9:15 AM, Imesh Gunaratne <im...@apache.org>
>> wrote:
>>
>>>
>>>> in og4j.appender.CARBON_LOGFILE.layout.ConversionPattern=TID: [%T] [%S]
>>>> [%d] %P%5p *{%c}* - %x %m* {%c}*%n
>>>> %c appears twice, which lets the class name to logged twice
>>>>
>>>> This is the convention used in carbon server logs.
>>>
>>>
>>> --
>>> Imesh Gunaratne
>>>
>>> Technical Lead, WSO2
>>> Committer & PMC Member, Apache Stratos
>>>
>>
>>
>>
>> --
>> Isuru Perera
>> Senior Software Engineer | WSO2, Inc. | http://wso2.com/
>> Lean . Enterprise . Middleware
>>
>> about.me/chrishantha
>>
>> --
>> <http://about.me/chrishantha>
>> Thanks and Regards,
>>
>> Isuru H.
>> <http://about.me/chrishantha>
>> +94 716 358 048 <http://about.me/chrishantha>* <http://wso2.com/>*
>>
>>
>> * <http://wso2.com/>*
>>
>>
>>


-- 
*Sajith Kariyawasam*


*Committer and PMC member, Apache Stratos,WSO2 Inc., http://wso2.com
<http://wso2.com>AMIE (SL)Mobile: +94772269575*

Re: How we can change the logging format in Stratos?

Posted by Isuru Haththotuwa <is...@apache.org>.
On Mon, Oct 13, 2014 at 11:13 AM, Isuru Perera <is...@wso2.com> wrote:

> We should remove the duplicate class name from logs
>
+1

>
> On Mon, Oct 13, 2014 at 9:15 AM, Imesh Gunaratne <im...@apache.org> wrote:
>
>>
>>> in og4j.appender.CARBON_LOGFILE.layout.ConversionPattern=TID: [%T] [%S]
>>> [%d] %P%5p *{%c}* - %x %m* {%c}*%n
>>> %c appears twice, which lets the class name to logged twice
>>>
>>> This is the convention used in carbon server logs.
>>
>>
>> --
>> Imesh Gunaratne
>>
>> Technical Lead, WSO2
>> Committer & PMC Member, Apache Stratos
>>
>
>
>
> --
> Isuru Perera
> Senior Software Engineer | WSO2, Inc. | http://wso2.com/
> Lean . Enterprise . Middleware
>
> about.me/chrishantha
>
> --
> <http://about.me/chrishantha>
> Thanks and Regards,
>
> Isuru H.
> <http://about.me/chrishantha>
> +94 716 358 048 <http://about.me/chrishantha>* <http://wso2.com/>*
>
>
> * <http://wso2.com/>*
>
>
>

Re: How we can change the logging format in Stratos?

Posted by Isuru Perera <is...@wso2.com>.
We should remove the duplicate class name from logs

On Mon, Oct 13, 2014 at 9:15 AM, Imesh Gunaratne <im...@apache.org> wrote:

>
>> in og4j.appender.CARBON_LOGFILE.layout.ConversionPattern=TID: [%T] [%S]
>> [%d] %P%5p *{%c}* - %x %m* {%c}*%n
>> %c appears twice, which lets the class name to logged twice
>>
>> This is the convention used in carbon server logs.
>
>
> --
> Imesh Gunaratne
>
> Technical Lead, WSO2
> Committer & PMC Member, Apache Stratos
>



-- 
Isuru Perera
Senior Software Engineer | WSO2, Inc. | http://wso2.com/
Lean . Enterprise . Middleware

about.me/chrishantha

Re: How we can change the logging format in Stratos?

Posted by Imesh Gunaratne <im...@apache.org>.
>
>
> in og4j.appender.CARBON_LOGFILE.layout.ConversionPattern=TID: [%T] [%S]
> [%d] %P%5p *{%c}* - %x %m* {%c}*%n
> %c appears twice, which lets the class name to logged twice
>
> This is the convention used in carbon server logs.


-- 
Imesh Gunaratne

Technical Lead, WSO2
Committer & PMC Member, Apache Stratos

Re: How we can change the logging format in Stratos?

Posted by Sajith Kariyawasam <sa...@wso2.com>.
Hi,

Haven't noticed this until now :)

in og4j.appender.CARBON_LOGFILE.layout.ConversionPattern=TID: [%T] [%S]
[%d] %P%5p *{%c}* - %x %m* {%c}*%n
%c appears twice, which lets the class name to logged twice
I think we should remove that, thanks Raj or pointing out!

Thanks,
Sajith

On Sat, Oct 11, 2014 at 6:50 AM, Rajkumar Rajaratnam <ra...@wso2.com>
wrote:

> Hi,
>
> On Sat, Oct 11, 2014 at 6:44 AM, Nirmal Fernando <ni...@gmail.com>
> wrote:
>
>> Why do you want to remove TID part? It stands for Tenant ID.
>>
>
> I didn't meant to remove it from code base. I wanted to do it locally in
> my running setup so that I can clearly observe the scaling logs. It is very
> lengthy now. And the logging class name
> ({org.apache.stratos.autoscaler.rule.RuleLog}) printed twice at the start
> and the end.
>
>
>> All these can be configured via log4j.properties files corresponding
>> Appenders.
>>
>
> Thanks, I will check that.
>
>
>>
>> On Sat, Oct 11, 2014 at 6:41 AM, Rajkumar Rajaratnam <ra...@wso2.com>
>> wrote:
>>
>>> Hi,
>>>
>>> Can we configure the logging format?
>>>
>>> Currently we are logging in the format like below;
>>>
>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,722]  INFO
>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  Running minimum rule:
>>> [kub-cluster] KubGrp1 [cluster] myphp.php.domain
>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [min-check]  [cluster] :
>>> myphp.php.domain [Replicas] nonTerminated : 2
>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [min-check]  [cluster] :
>>> myphp.php.domain [Replicas] minReplicas : 2
>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  Running obsolete containers
>>> rule [kub-cluster] : KubGrp1 [cluster] : myphp.php.domain
>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [obsolete-check] [cluster]
>>> : myphp.php.domain [Replicas] obsoleteReplicas : 0
>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  Running scaling rule
>>> [kub-cluster] : KubGrp1 [cluster] : myphp.php.domain
>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,724]  INFO
>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>> myphp.php.domain [Replicas] nonTerminated : 2
>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,724]  INFO
>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>> myphp.php.domain [Replicas] minReplicas : 2
>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,725]  INFO
>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>> myphp.php.domain [Replicas] maxReplicas : 20
>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,725]  INFO
>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>> myphp.php.domain [RequestInFlight] resetted ? : false
>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,725]  INFO
>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>> myphp.php.domain [RequestInFlight] predicted value : 0.0
>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,726]  INFO
>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>> myphp.php.domain [RequestInFlight] upper limit : 80.0
>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,726]  INFO
>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>> myphp.php.domain [RequestInFlight] lower limit : 5.0
>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,726]  INFO
>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>> myphp.php.domain [MemoryConsumption] resetted ? : true
>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,727]  INFO
>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>> myphp.php.domain [MemoryConsumption] predicted value : 29.142266099066546
>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,727]  INFO
>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>> myphp.php.domain [MemoryConsumption] upper limit : 80.0
>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,727]  INFO
>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>> myphp.php.domain [MemoryConsumption] lower limit : 15.0
>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,728]  INFO
>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>> myphp.php.domain [LoadAverage] resetted ? : true
>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,728]  INFO
>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>> myphp.php.domain [LoadAverage] predicted value : 2.70735374011565
>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,729]  INFO
>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>> myphp.php.domain [LoadAverage] upper limit : 180.0
>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,729]  INFO
>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>> myphp.php.domain [LoadAverage] lower limit : 100.0
>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,729]  INFO
>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>> myphp.php.domain scale-up action : false
>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,730]  INFO
>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>>> myphp.php.domain scale-down action : false
>>> {org.apache.stratos.autoscaler.rule.RuleLog}
>>> TID: [0] [STRATOS] [2014-10-11 06:39:05,731]  INFO
>>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling] No decision made
>>> to either scale up or down ...  {org.apache.stratos.autoscaler.rule.RuleLog}
>>>
>>>
>>> How can I remove the TID part and Stratos part when logging?
>>>
>>> Thanks.
>>>
>>>
>>> --
>>> Rajkumar Rajaratnam
>>> Software Engineer | WSO2, Inc.
>>> Mobile +94777568639 | +94783498120
>>>
>>
>>
>>
>> --
>> Best Regards,
>> Nirmal
>>
>> Nirmal Fernando.
>> PPMC Member & Committer of Apache Stratos,
>> Senior Software Engineer, WSO2 Inc.
>>
>> Blog: http://nirmalfdo.blogspot.com/
>>
>
>
>
> --
> Rajkumar Rajaratnam
> Software Engineer | WSO2, Inc.
> Mobile +94777568639 | +94783498120
>



-- 
*Sajith Kariyawasam*


*Committer and PMC member, Apache Stratos,WSO2 Inc., http://wso2.com
<http://wso2.com>AMIE (SL)Mobile: +94772269575*

Re: How we can change the logging format in Stratos?

Posted by Rajkumar Rajaratnam <ra...@wso2.com>.
Hi,

On Sat, Oct 11, 2014 at 6:44 AM, Nirmal Fernando <ni...@gmail.com>
wrote:

> Why do you want to remove TID part? It stands for Tenant ID.
>

I didn't meant to remove it from code base. I wanted to do it locally in my
running setup so that I can clearly observe the scaling logs. It is very
lengthy now. And the logging class name
({org.apache.stratos.autoscaler.rule.RuleLog}) printed twice at the start
and the end.


> All these can be configured via log4j.properties files corresponding
> Appenders.
>

Thanks, I will check that.


>
> On Sat, Oct 11, 2014 at 6:41 AM, Rajkumar Rajaratnam <ra...@wso2.com>
> wrote:
>
>> Hi,
>>
>> Can we configure the logging format?
>>
>> Currently we are logging in the format like below;
>>
>> TID: [0] [STRATOS] [2014-10-11 06:39:05,722]  INFO
>> {org.apache.stratos.autoscaler.rule.RuleLog} -  Running minimum rule:
>> [kub-cluster] KubGrp1 [cluster] myphp.php.domain
>> {org.apache.stratos.autoscaler.rule.RuleLog}
>> TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [min-check]  [cluster] :
>> myphp.php.domain [Replicas] nonTerminated : 2
>> {org.apache.stratos.autoscaler.rule.RuleLog}
>> TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [min-check]  [cluster] :
>> myphp.php.domain [Replicas] minReplicas : 2
>> {org.apache.stratos.autoscaler.rule.RuleLog}
>> TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
>> {org.apache.stratos.autoscaler.rule.RuleLog} -  Running obsolete containers
>> rule [kub-cluster] : KubGrp1 [cluster] : myphp.php.domain
>> {org.apache.stratos.autoscaler.rule.RuleLog}
>> TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [obsolete-check] [cluster]
>> : myphp.php.domain [Replicas] obsoleteReplicas : 0
>> {org.apache.stratos.autoscaler.rule.RuleLog}
>> TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
>> {org.apache.stratos.autoscaler.rule.RuleLog} -  Running scaling rule
>> [kub-cluster] : KubGrp1 [cluster] : myphp.php.domain
>> {org.apache.stratos.autoscaler.rule.RuleLog}
>> TID: [0] [STRATOS] [2014-10-11 06:39:05,724]  INFO
>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>> myphp.php.domain [Replicas] nonTerminated : 2
>> {org.apache.stratos.autoscaler.rule.RuleLog}
>> TID: [0] [STRATOS] [2014-10-11 06:39:05,724]  INFO
>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>> myphp.php.domain [Replicas] minReplicas : 2
>> {org.apache.stratos.autoscaler.rule.RuleLog}
>> TID: [0] [STRATOS] [2014-10-11 06:39:05,725]  INFO
>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>> myphp.php.domain [Replicas] maxReplicas : 20
>> {org.apache.stratos.autoscaler.rule.RuleLog}
>> TID: [0] [STRATOS] [2014-10-11 06:39:05,725]  INFO
>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>> myphp.php.domain [RequestInFlight] resetted ? : false
>> {org.apache.stratos.autoscaler.rule.RuleLog}
>> TID: [0] [STRATOS] [2014-10-11 06:39:05,725]  INFO
>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>> myphp.php.domain [RequestInFlight] predicted value : 0.0
>> {org.apache.stratos.autoscaler.rule.RuleLog}
>> TID: [0] [STRATOS] [2014-10-11 06:39:05,726]  INFO
>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>> myphp.php.domain [RequestInFlight] upper limit : 80.0
>> {org.apache.stratos.autoscaler.rule.RuleLog}
>> TID: [0] [STRATOS] [2014-10-11 06:39:05,726]  INFO
>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>> myphp.php.domain [RequestInFlight] lower limit : 5.0
>> {org.apache.stratos.autoscaler.rule.RuleLog}
>> TID: [0] [STRATOS] [2014-10-11 06:39:05,726]  INFO
>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>> myphp.php.domain [MemoryConsumption] resetted ? : true
>> {org.apache.stratos.autoscaler.rule.RuleLog}
>> TID: [0] [STRATOS] [2014-10-11 06:39:05,727]  INFO
>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>> myphp.php.domain [MemoryConsumption] predicted value : 29.142266099066546
>> {org.apache.stratos.autoscaler.rule.RuleLog}
>> TID: [0] [STRATOS] [2014-10-11 06:39:05,727]  INFO
>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>> myphp.php.domain [MemoryConsumption] upper limit : 80.0
>> {org.apache.stratos.autoscaler.rule.RuleLog}
>> TID: [0] [STRATOS] [2014-10-11 06:39:05,727]  INFO
>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>> myphp.php.domain [MemoryConsumption] lower limit : 15.0
>> {org.apache.stratos.autoscaler.rule.RuleLog}
>> TID: [0] [STRATOS] [2014-10-11 06:39:05,728]  INFO
>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>> myphp.php.domain [LoadAverage] resetted ? : true
>> {org.apache.stratos.autoscaler.rule.RuleLog}
>> TID: [0] [STRATOS] [2014-10-11 06:39:05,728]  INFO
>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>> myphp.php.domain [LoadAverage] predicted value : 2.70735374011565
>> {org.apache.stratos.autoscaler.rule.RuleLog}
>> TID: [0] [STRATOS] [2014-10-11 06:39:05,729]  INFO
>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>> myphp.php.domain [LoadAverage] upper limit : 180.0
>> {org.apache.stratos.autoscaler.rule.RuleLog}
>> TID: [0] [STRATOS] [2014-10-11 06:39:05,729]  INFO
>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>> myphp.php.domain [LoadAverage] lower limit : 100.0
>> {org.apache.stratos.autoscaler.rule.RuleLog}
>> TID: [0] [STRATOS] [2014-10-11 06:39:05,729]  INFO
>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>> myphp.php.domain scale-up action : false
>> {org.apache.stratos.autoscaler.rule.RuleLog}
>> TID: [0] [STRATOS] [2014-10-11 06:39:05,730]  INFO
>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
>> myphp.php.domain scale-down action : false
>> {org.apache.stratos.autoscaler.rule.RuleLog}
>> TID: [0] [STRATOS] [2014-10-11 06:39:05,731]  INFO
>> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling] No decision made
>> to either scale up or down ...  {org.apache.stratos.autoscaler.rule.RuleLog}
>>
>>
>> How can I remove the TID part and Stratos part when logging?
>>
>> Thanks.
>>
>>
>> --
>> Rajkumar Rajaratnam
>> Software Engineer | WSO2, Inc.
>> Mobile +94777568639 | +94783498120
>>
>
>
>
> --
> Best Regards,
> Nirmal
>
> Nirmal Fernando.
> PPMC Member & Committer of Apache Stratos,
> Senior Software Engineer, WSO2 Inc.
>
> Blog: http://nirmalfdo.blogspot.com/
>



-- 
Rajkumar Rajaratnam
Software Engineer | WSO2, Inc.
Mobile +94777568639 | +94783498120

Re: How we can change the logging format in Stratos?

Posted by Nirmal Fernando <ni...@gmail.com>.
Why do you want to remove TID part? It stands for Tenant ID.

All these can be configured via log4j.properties files corresponding
Appenders.

On Sat, Oct 11, 2014 at 6:41 AM, Rajkumar Rajaratnam <ra...@wso2.com>
wrote:

> Hi,
>
> Can we configure the logging format?
>
> Currently we are logging in the format like below;
>
> TID: [0] [STRATOS] [2014-10-11 06:39:05,722]  INFO
> {org.apache.stratos.autoscaler.rule.RuleLog} -  Running minimum rule:
> [kub-cluster] KubGrp1 [cluster] myphp.php.domain
> {org.apache.stratos.autoscaler.rule.RuleLog}
> TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
> {org.apache.stratos.autoscaler.rule.RuleLog} -  [min-check]  [cluster] :
> myphp.php.domain [Replicas] nonTerminated : 2
> {org.apache.stratos.autoscaler.rule.RuleLog}
> TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
> {org.apache.stratos.autoscaler.rule.RuleLog} -  [min-check]  [cluster] :
> myphp.php.domain [Replicas] minReplicas : 2
> {org.apache.stratos.autoscaler.rule.RuleLog}
> TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
> {org.apache.stratos.autoscaler.rule.RuleLog} -  Running obsolete containers
> rule [kub-cluster] : KubGrp1 [cluster] : myphp.php.domain
> {org.apache.stratos.autoscaler.rule.RuleLog}
> TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
> {org.apache.stratos.autoscaler.rule.RuleLog} -  [obsolete-check] [cluster]
> : myphp.php.domain [Replicas] obsoleteReplicas : 0
> {org.apache.stratos.autoscaler.rule.RuleLog}
> TID: [0] [STRATOS] [2014-10-11 06:39:05,723]  INFO
> {org.apache.stratos.autoscaler.rule.RuleLog} -  Running scaling rule
> [kub-cluster] : KubGrp1 [cluster] : myphp.php.domain
> {org.apache.stratos.autoscaler.rule.RuleLog}
> TID: [0] [STRATOS] [2014-10-11 06:39:05,724]  INFO
> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
> myphp.php.domain [Replicas] nonTerminated : 2
> {org.apache.stratos.autoscaler.rule.RuleLog}
> TID: [0] [STRATOS] [2014-10-11 06:39:05,724]  INFO
> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
> myphp.php.domain [Replicas] minReplicas : 2
> {org.apache.stratos.autoscaler.rule.RuleLog}
> TID: [0] [STRATOS] [2014-10-11 06:39:05,725]  INFO
> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
> myphp.php.domain [Replicas] maxReplicas : 20
> {org.apache.stratos.autoscaler.rule.RuleLog}
> TID: [0] [STRATOS] [2014-10-11 06:39:05,725]  INFO
> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
> myphp.php.domain [RequestInFlight] resetted ? : false
> {org.apache.stratos.autoscaler.rule.RuleLog}
> TID: [0] [STRATOS] [2014-10-11 06:39:05,725]  INFO
> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
> myphp.php.domain [RequestInFlight] predicted value : 0.0
> {org.apache.stratos.autoscaler.rule.RuleLog}
> TID: [0] [STRATOS] [2014-10-11 06:39:05,726]  INFO
> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
> myphp.php.domain [RequestInFlight] upper limit : 80.0
> {org.apache.stratos.autoscaler.rule.RuleLog}
> TID: [0] [STRATOS] [2014-10-11 06:39:05,726]  INFO
> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
> myphp.php.domain [RequestInFlight] lower limit : 5.0
> {org.apache.stratos.autoscaler.rule.RuleLog}
> TID: [0] [STRATOS] [2014-10-11 06:39:05,726]  INFO
> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
> myphp.php.domain [MemoryConsumption] resetted ? : true
> {org.apache.stratos.autoscaler.rule.RuleLog}
> TID: [0] [STRATOS] [2014-10-11 06:39:05,727]  INFO
> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
> myphp.php.domain [MemoryConsumption] predicted value : 29.142266099066546
> {org.apache.stratos.autoscaler.rule.RuleLog}
> TID: [0] [STRATOS] [2014-10-11 06:39:05,727]  INFO
> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
> myphp.php.domain [MemoryConsumption] upper limit : 80.0
> {org.apache.stratos.autoscaler.rule.RuleLog}
> TID: [0] [STRATOS] [2014-10-11 06:39:05,727]  INFO
> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
> myphp.php.domain [MemoryConsumption] lower limit : 15.0
> {org.apache.stratos.autoscaler.rule.RuleLog}
> TID: [0] [STRATOS] [2014-10-11 06:39:05,728]  INFO
> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
> myphp.php.domain [LoadAverage] resetted ? : true
> {org.apache.stratos.autoscaler.rule.RuleLog}
> TID: [0] [STRATOS] [2014-10-11 06:39:05,728]  INFO
> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
> myphp.php.domain [LoadAverage] predicted value : 2.70735374011565
> {org.apache.stratos.autoscaler.rule.RuleLog}
> TID: [0] [STRATOS] [2014-10-11 06:39:05,729]  INFO
> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
> myphp.php.domain [LoadAverage] upper limit : 180.0
> {org.apache.stratos.autoscaler.rule.RuleLog}
> TID: [0] [STRATOS] [2014-10-11 06:39:05,729]  INFO
> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
> myphp.php.domain [LoadAverage] lower limit : 100.0
> {org.apache.stratos.autoscaler.rule.RuleLog}
> TID: [0] [STRATOS] [2014-10-11 06:39:05,729]  INFO
> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
> myphp.php.domain scale-up action : false
> {org.apache.stratos.autoscaler.rule.RuleLog}
> TID: [0] [STRATOS] [2014-10-11 06:39:05,730]  INFO
> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling]  [cluster] :
> myphp.php.domain scale-down action : false
> {org.apache.stratos.autoscaler.rule.RuleLog}
> TID: [0] [STRATOS] [2014-10-11 06:39:05,731]  INFO
> {org.apache.stratos.autoscaler.rule.RuleLog} -  [scaling] No decision made
> to either scale up or down ...  {org.apache.stratos.autoscaler.rule.RuleLog}
>
>
> How can I remove the TID part and Stratos part when logging?
>
> Thanks.
>
>
> --
> Rajkumar Rajaratnam
> Software Engineer | WSO2, Inc.
> Mobile +94777568639 | +94783498120
>



-- 
Best Regards,
Nirmal

Nirmal Fernando.
PPMC Member & Committer of Apache Stratos,
Senior Software Engineer, WSO2 Inc.

Blog: http://nirmalfdo.blogspot.com/