You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@stratos.apache.org by Udara Liyanage <ud...@wso2.com> on 2014/10/07 13:20:32 UTC

NPE while deploying an application

Hi,

I got the following error when I deployed the below app. It's coming from a
debug log. I will debug and check for the issue. Additionally instances are
not getting spawned.

@Isuru/Reka am I missing something in application definition?


{
    "applicationId": "test_app_1",
    "alias": "mytestapp1",
    "components": {
        "subscribables": [
            {
                "type": "tomcat",
                "alias": "mytomcat"
            }
        ]
    },
    "subscribableInfo": [
        {
            "dependencyAliases":"mysql",
            "alias": "mytomcat",
            "deploymentPolicy": "economyDeploymentPolicyOpenstack",
            "autoscalingPolicy": "simpleAutoscalePolicy",
            "repoURL": "www.mygit.com/tomcat.git",
            "privateRepo": "false",
            "repoUsername": "admin",
            "repoPassword": "yyyy"
        }
    ]
}


[2014-10-07 16:44:53,791]  INFO
{org.apache.stratos.cloud.controller.application.parser.DefaultApplicationParser}
-  Application with id test_app_1 parsed successfully
[2014-10-07 16:44:53,792]  INFO
{org.apache.stratos.cloud.controller.topology.TopologyBuilder} -  Added
Cluster Cluster [serviceName=tomcat, clusterId=mytomcat.tomcat.domain,
autoscalePolicyName=simpleAutoscalePolicy,
deploymentPolicyName=economyDeploymentPolicyOpenstack, hostNames=[
mytomcat.apachestratos.org], tenantRange=*, isLbCluster=false,
properties=null] to Topology for Application with id: test_app_1
[2014-10-07 16:44:53,862]  INFO
{org.apache.stratos.cloud.controller.topology.TopologyBuilder} -
 Application with id [ test_app_1 ] added to Topology successfully
[2014-10-07 16:44:53,863]  INFO
{org.apache.stratos.cloud.controller.topology.TopologyEventPublisher} -
 Publishing Application created event:
org.apache.stratos.messaging.domain.topology.Application@37b57669
[2014-10-07 16:44:53,877]  WARN
{org.apache.stratos.messaging.message.processor.topology.ApplicationCreatedMessageProcessor}
-  Application with id [ test_app_1 ] already exists in Topology
[2014-10-07 16:44:53,882]  WARN
{org.apache.stratos.messaging.message.processor.topology.ApplicationCreatedMessageProcessor}
-  Application with id [ test_app_1 ] already exists in Topology
[2014-10-07 16:44:53,884]  INFO
{org.apache.stratos.autoscaler.message.receiver.topology.AutoscalerTopologyEventReceiver}
-  [ApplicationCreatedEvent] Received: class
org.apache.stratos.messaging.event.topology.ApplicationCreatedEvent
*Exception in thread "Thread-65" java.lang.NullPointerException*
* at
org.apache.stratos.autoscaler.message.receiver.topology.AutoscalerTopologyEventReceiver$ApplicationMonitorAdder.run(AutoscalerTopologyEventReceiver.java:600)*
* at java.lang.Thread.run(Thread.java:662)*
[2014-10-07 16:45:18,905]  WARN
{org.apache.stratos.messaging.message.processor.topology.ApplicationCreatedMessageProcessor}
-  Application with id [ test_app_1 ] already exists in Topology
[2014-10-07 16:45:18,907]  INFO
{org.apache.stratos.manager.topology.receiver.StratosManagerTopologyEventReceiver}
-  [ApplicationCreatedEventListener] Received: class
org.apache.stratos.messaging.event.topology.ApplicationCreatedEvent


-- 

Udara Liyanage
Software Engineer
WSO2, Inc.: http://wso2.com
lean. enterprise. middleware

web: http://udaraliyanage.wordpress.com
phone: +94 71 443 6897

Re: NPE while deploying an application

Posted by Udara Liyanage <ud...@wso2.com>.
Hi Manula,

This occurs when an Application (in grouping) is deployed, not subscribed
to a cartridge.

On Thu, Oct 9, 2014 at 2:43 PM, Manula Chathurika Thantriwatte <
manulac@wso2.com> wrote:

> Hi Udara,
>
> Would you be able to solve the problem ? If you are using OpenStack please
> set assignFloatingIp property as true and redeploy and subscribe.
>
> Thanks !
>
> On Tue, Oct 7, 2014 at 4:50 PM, Udara Liyanage <ud...@wso2.com> wrote:
>
>> Hi,
>>
>> I got the following error when I deployed the below app. It's coming from
>> a debug log. I will debug and check for the issue. Additionally instances
>> are not getting spawned.
>>
>> @Isuru/Reka am I missing something in application definition?
>>
>>
>> {
>>     "applicationId": "test_app_1",
>>     "alias": "mytestapp1",
>>     "components": {
>>         "subscribables": [
>>             {
>>                 "type": "tomcat",
>>                 "alias": "mytomcat"
>>             }
>>         ]
>>     },
>>     "subscribableInfo": [
>>         {
>>             "dependencyAliases":"mysql",
>>             "alias": "mytomcat",
>>             "deploymentPolicy": "economyDeploymentPolicyOpenstack",
>>             "autoscalingPolicy": "simpleAutoscalePolicy",
>>             "repoURL": "www.mygit.com/tomcat.git",
>>             "privateRepo": "false",
>>             "repoUsername": "admin",
>>             "repoPassword": "yyyy"
>>         }
>>     ]
>> }
>>
>>
>> [2014-10-07 16:44:53,791]  INFO
>> {org.apache.stratos.cloud.controller.application.parser.DefaultApplicationParser}
>> -  Application with id test_app_1 parsed successfully
>> [2014-10-07 16:44:53,792]  INFO
>> {org.apache.stratos.cloud.controller.topology.TopologyBuilder} -  Added
>> Cluster Cluster [serviceName=tomcat, clusterId=mytomcat.tomcat.domain,
>> autoscalePolicyName=simpleAutoscalePolicy,
>> deploymentPolicyName=economyDeploymentPolicyOpenstack, hostNames=[
>> mytomcat.apachestratos.org], tenantRange=*, isLbCluster=false,
>> properties=null] to Topology for Application with id: test_app_1
>> [2014-10-07 16:44:53,862]  INFO
>> {org.apache.stratos.cloud.controller.topology.TopologyBuilder} -
>>  Application with id [ test_app_1 ] added to Topology successfully
>> [2014-10-07 16:44:53,863]  INFO
>> {org.apache.stratos.cloud.controller.topology.TopologyEventPublisher} -
>>  Publishing Application created event:
>> org.apache.stratos.messaging.domain.topology.Application@37b57669
>> [2014-10-07 16:44:53,877]  WARN
>> {org.apache.stratos.messaging.message.processor.topology.ApplicationCreatedMessageProcessor}
>> -  Application with id [ test_app_1 ] already exists in Topology
>> [2014-10-07 16:44:53,882]  WARN
>> {org.apache.stratos.messaging.message.processor.topology.ApplicationCreatedMessageProcessor}
>> -  Application with id [ test_app_1 ] already exists in Topology
>> [2014-10-07 16:44:53,884]  INFO
>> {org.apache.stratos.autoscaler.message.receiver.topology.AutoscalerTopologyEventReceiver}
>> -  [ApplicationCreatedEvent] Received: class
>> org.apache.stratos.messaging.event.topology.ApplicationCreatedEvent
>> *Exception in thread "Thread-65" java.lang.NullPointerException*
>> * at
>> org.apache.stratos.autoscaler.message.receiver.topology.AutoscalerTopologyEventReceiver$ApplicationMonitorAdder.run(AutoscalerTopologyEventReceiver.java:600)*
>> * at java.lang.Thread.run(Thread.java:662)*
>> [2014-10-07 16:45:18,905]  WARN
>> {org.apache.stratos.messaging.message.processor.topology.ApplicationCreatedMessageProcessor}
>> -  Application with id [ test_app_1 ] already exists in Topology
>> [2014-10-07 16:45:18,907]  INFO
>> {org.apache.stratos.manager.topology.receiver.StratosManagerTopologyEventReceiver}
>> -  [ApplicationCreatedEventListener] Received: class
>> org.apache.stratos.messaging.event.topology.ApplicationCreatedEvent
>>
>>
>> --
>>
>> Udara Liyanage
>> Software Engineer
>> WSO2, Inc.: http://wso2.com
>> lean. enterprise. middleware
>>
>> web: http://udaraliyanage.wordpress.com
>> phone: +94 71 443 6897
>>
>
>
>
> --
> Regards,
> Manula Chathurika Thantriwatte
> Software Engineer
> WSO2 Inc. : http://wso2.com
> lean . enterprise . middleware
>
> email : manulac@wso2.com / manula@apache.org
> phone : +94 772492511
> blog : http://manulachathurika.blogspot.com/
>
>
>
>


-- 

Udara Liyanage
Software Engineer
WSO2, Inc.: http://wso2.com
lean. enterprise. middleware

web: http://udaraliyanage.wordpress.com
phone: +94 71 443 6897

Re: NPE while deploying an application

Posted by Manula Chathurika Thantriwatte <ma...@wso2.com>.
Hi Udara,

Would you be able to solve the problem ? If you are using OpenStack please
set assignFloatingIp property as true and redeploy and subscribe.

Thanks !

On Tue, Oct 7, 2014 at 4:50 PM, Udara Liyanage <ud...@wso2.com> wrote:

> Hi,
>
> I got the following error when I deployed the below app. It's coming from
> a debug log. I will debug and check for the issue. Additionally instances
> are not getting spawned.
>
> @Isuru/Reka am I missing something in application definition?
>
>
> {
>     "applicationId": "test_app_1",
>     "alias": "mytestapp1",
>     "components": {
>         "subscribables": [
>             {
>                 "type": "tomcat",
>                 "alias": "mytomcat"
>             }
>         ]
>     },
>     "subscribableInfo": [
>         {
>             "dependencyAliases":"mysql",
>             "alias": "mytomcat",
>             "deploymentPolicy": "economyDeploymentPolicyOpenstack",
>             "autoscalingPolicy": "simpleAutoscalePolicy",
>             "repoURL": "www.mygit.com/tomcat.git",
>             "privateRepo": "false",
>             "repoUsername": "admin",
>             "repoPassword": "yyyy"
>         }
>     ]
> }
>
>
> [2014-10-07 16:44:53,791]  INFO
> {org.apache.stratos.cloud.controller.application.parser.DefaultApplicationParser}
> -  Application with id test_app_1 parsed successfully
> [2014-10-07 16:44:53,792]  INFO
> {org.apache.stratos.cloud.controller.topology.TopologyBuilder} -  Added
> Cluster Cluster [serviceName=tomcat, clusterId=mytomcat.tomcat.domain,
> autoscalePolicyName=simpleAutoscalePolicy,
> deploymentPolicyName=economyDeploymentPolicyOpenstack, hostNames=[
> mytomcat.apachestratos.org], tenantRange=*, isLbCluster=false,
> properties=null] to Topology for Application with id: test_app_1
> [2014-10-07 16:44:53,862]  INFO
> {org.apache.stratos.cloud.controller.topology.TopologyBuilder} -
>  Application with id [ test_app_1 ] added to Topology successfully
> [2014-10-07 16:44:53,863]  INFO
> {org.apache.stratos.cloud.controller.topology.TopologyEventPublisher} -
>  Publishing Application created event:
> org.apache.stratos.messaging.domain.topology.Application@37b57669
> [2014-10-07 16:44:53,877]  WARN
> {org.apache.stratos.messaging.message.processor.topology.ApplicationCreatedMessageProcessor}
> -  Application with id [ test_app_1 ] already exists in Topology
> [2014-10-07 16:44:53,882]  WARN
> {org.apache.stratos.messaging.message.processor.topology.ApplicationCreatedMessageProcessor}
> -  Application with id [ test_app_1 ] already exists in Topology
> [2014-10-07 16:44:53,884]  INFO
> {org.apache.stratos.autoscaler.message.receiver.topology.AutoscalerTopologyEventReceiver}
> -  [ApplicationCreatedEvent] Received: class
> org.apache.stratos.messaging.event.topology.ApplicationCreatedEvent
> *Exception in thread "Thread-65" java.lang.NullPointerException*
> * at
> org.apache.stratos.autoscaler.message.receiver.topology.AutoscalerTopologyEventReceiver$ApplicationMonitorAdder.run(AutoscalerTopologyEventReceiver.java:600)*
> * at java.lang.Thread.run(Thread.java:662)*
> [2014-10-07 16:45:18,905]  WARN
> {org.apache.stratos.messaging.message.processor.topology.ApplicationCreatedMessageProcessor}
> -  Application with id [ test_app_1 ] already exists in Topology
> [2014-10-07 16:45:18,907]  INFO
> {org.apache.stratos.manager.topology.receiver.StratosManagerTopologyEventReceiver}
> -  [ApplicationCreatedEventListener] Received: class
> org.apache.stratos.messaging.event.topology.ApplicationCreatedEvent
>
>
> --
>
> Udara Liyanage
> Software Engineer
> WSO2, Inc.: http://wso2.com
> lean. enterprise. middleware
>
> web: http://udaraliyanage.wordpress.com
> phone: +94 71 443 6897
>



-- 
Regards,
Manula Chathurika Thantriwatte
Software Engineer
WSO2 Inc. : http://wso2.com
lean . enterprise . middleware

email : manulac@wso2.com / manula@apache.org
phone : +94 772492511
blog : http://manulachathurika.blogspot.com/