worklight-development-server-does-not-start timeout - ibm-mobilefirst

Listening for transport dt_socket at address: 10777
Launching worklight (WebSphere Application Server 8.5.5.1/wlp-1.0.4.cl50120131011-1639) on Java HotSpot(TM) 64-Bit Server VM, version 1.7.0_60-ea-b15 (en_US)
[AUDIT ] CWWKE0001I: The server worklight has been launched.
[AUDIT ] CWWKT0016I: Web application available (default_host): http://Lalit:10080/IBMJMXConnectorREST/
[AUDIT ] CWWKZ0058I: Monitoring dropins for applications.
[AUDIT ] CWWKF0011I: The server worklight is ready to run a smarter planet.
[ERROR ] CWWKZ0005E: The application WorklightServices cannot start because the server is not configured to handle applications of type war.
[AUDIT ] CWWKT0017I: Web application removed (default_host): http://Lalit:10080/IBMJMXConnectorREST/
[ERROR ] CWWKZ0005E: The application WorklightConsole cannot start because the server is not configured to handle applications of type war.
[AUDIT ] CWWKE0036I: The server worklight stopped after 3 minutes, 2.429 seconds.

Same question: Worklight Development Server does not start
Verify you have Oracle Java installed and that Eclipse is configured to use it in Preferences > Java > Installed JREs
This seems to solve the problem. See if it solves yours as well.
Also consider upgrading to the latest available 6.2.0.0 iFix, currently dated August 18th.
You can get it either from IBM Fix Central website or by updating your Worklight Studio installation from Eclipse marketplace.

Related

IBM MobileFirst Platform Foundation 7.1 deployment topology with Tomcat

In developerworks paper IBM MobileFirst Platform Foundation "Scalability and Hardware Sizing", There is a typical deployment with WebSphere Application Server.
Scalability and Hardware Sizing
But if choosing Tomcat as application server for MFP server farm deployment, which load balance software will been used? Are there any MFP performance report about the comparison between WebSphere application server and tomcat as MFP application server?
Thanks in advance
But if choosing Tomcat as application server for MFP server farm deployment, which load balance software will been used?
You can use whichever software you'd like. There is no enforcement in place.
Are there any MFP performance report about the comparison between WebSphere application server and tomcat as MFP application server?
Performance tests were not run on Tomcat.

Application Authenticity is not getting enabled

I am using Worklight 6.2 consumer edition. When I deploy my app, following warning flashes on server console:
[WARNING ] FWLSE0259W: Application authenticity protection is not being performed within the Worklight Development Server. In order to fully test Application authenticity protection, deploy the application to a non-development Worklight Server (i.e. external Worklight Server). [project MyProject].
I am using Web Sphere Liberty Profile 8.5.5.1 server. Pls advise how to make this warning make go away?
As the message says, if you are trying to test Application Authenticity Protection in Worklight Studio (the Eclipse development environment of Worklight), Authenticity protection is not supposed to work.
To test Application Authenticity in Worklight 6.2, you must deploy Worklight using IBM Installation Manager to your Application Server (WAS, Liberty, Tomcat), as well as your .war, .wlapp, .adapters, etc... and set it up in Worklight Console belonging to this instance of Worklight.
Only then should it work.

IBM Worklight - load a properties file from an adapter

I need to access some properties from a Javascript adapter.
I know that i can access to worklight.properties file using
WL.Server.configuration.propertyName
but seems that when the property file change a server restart is needed
From Eclipse console after saving a new version of worklight.properties:
[AUDIT ] CWWKG0016I: Starting server configuration update.
[AUDIT ] CWWKG0017I: The server configuration was successfully updated in 0.005 seconds.
[AUDIT ] CWWKT0017I: Web application removed (default_host): http://hostname:hostport/ProjectName/
[AUDIT ] CWWKZ0009I: The application ProjectName has stopped successfully.
[AUDIT ] CWWKG0016I: Starting server configuration update.
[AUDIT ] CWWKG0017I: The server configuration was successfully updated in 0.007 seconds.
[AUDIT ] CWWKT0016I: Web application available (default_host): http://hostname:hostport/ProjectName/
[AUDIT ] CWWKZ0001I: Application ProjectName started in 1.868 seconds.
There is a way to avoid server restart, or use a different WL mechanism to read Server side properties?
My env:
Eclipse Java EE IDE for Web Developers. Version: Kepler Service Release 2
IBM Worklight Studio 6.1
if you really want to avoid the server restart and access properties from file. You can follow the below work around.
From Adapter you can access JAVA code
From JAVA code try to access properties file
Am not sure why you are looking for some other mechanism above mentioned is just a workaround which am using in my project.
In your question you do not explain why this server restart bothers you.
In the development environment - the Worklight Studio plug-in for Eclipse, what you say is correct - whenever you change any file that resides in the server folder of your Worklight project, the embedded WAS Liberty profile server will restart.
This is the expected behavior and is unavoidable.
In addition, there is no other mechanism AFAIK to read server properties.

Where in my application do I define the worklightServerRootURL element for my Worklight 6.1 Server running on PureApplication System?

I migrated my application from Worklight 5.0.6 to 6.1. I tested the application in Worklight Studio 6.1 in the local Liberty Test server and Mobile Browser Simulator and the application works fine. I have now deployed my Worklight Server 6.1 on PureApplication System using Mobile Application Platform Pattern 6.1.
In Worklight 6.1 the worklightServerRootURL element that existed in application-descriptor.xml has been removed. In Worklight 5.0.6 I defined the IP address of my Worklight Server running on PureApplication System in the worklightServerRootURL element. With this element removed in 6.1 where do I define the IP address of my worklight server runing on PureApplication System in my application so my application can talk to the Worklight server on PureApplication System ?
Run As -> Build Settings and Deploy Target; Then add a new server other than the localhost.
http://pic.dhe.ibm.com/infocenter/wrklight/v6r1m0/index.jsp?topic=%2Fcom.ibm.worklight.dev.doc%2Fdev%2Fc_building_and_deploying_build_settings_deploy_target.html

IBM Worklight 6.0 - WebSphere Application Server -> SRVE0293E : javax.servlet.ServletException: Worklight Project not initialized

I installed a worklight .war on my Websphere Application server, following this tutorial :
http://pic.dhe.ibm.com/infocenter/wrklight/v6r0m0/index.jsp?topic=%2Fcom.ibm.worklight.help.doc%2Fdevref%2Fc_dev_test_server_and_console.html
After starting my application, when I try to reach it using the following URL : http://<ip address>:9080/<context root>/console
I have this error in my Websphere SystemOut.log :
com.ibm.ws.webcontainer.webapp.WebApp logError SRVE0293E: [Servlet Error]-[Worklight Project not initialized]: javax.servlet.ServletException: Worklight Project not initialized
at com.worklight.core.auth.impl.AuthenticationFilter.doFilter(AuthenticationFilter.java:110)
at com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java:188)
at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:116)
at com.ibm.ws.webcontainer.filter.WebAppFilterChain._doFilter(WebAppFilterChain.java:77)
environment config :
Windows Server 2008 R2 - Entreprise
WebSphere Application server V7
Worklight server V6
DataBase Derby (default install trough worklight server install)
The same user asked the same question also in: IBM Worklight 6.0 - Custom authentication - custom java code doesn't seem to be found
His solution was:
I [re] Installed a Websphere Application server 8.5 and a DB2 with the
worklight server V6, and now everything is working great!