Work-light: Issue with setting up the environment

1.7k Views Asked by At

I have started learning IBM worklight recently.I have set the environment.

Now, I am trying to test a simple helloWorklight demo app but i am not able to do deploy and build the app.Although i am following this link: http://www.ibm.com/developerworks/mobile/worklight/getting-started.html

The error what i am getting is.. when trying to run on worklight development server:

Listening for transport dt_socket at address: 10777
Launching worklight (WebSphere Application Server 8.5.5.0/wlp-1.0.3.20130524-0951) on Java HotSpot(TM) Client VM, version 1.6.0_01-b06 (en_US)
[AUDIT   ] CWWKE0001I: The server worklight has been launched.
[AUDIT   ] CWWKZ0058I: Monitoring dropins for applications. 
[ERROR   ] CWWKZ0002E: An exception occurred while starting the application _MobileBrowserSimulator. The exception message was: com.ibm.ws.container.service.metadata.MetaDataException: java.util.regex.PatternSyntaxException: Unclosed character class near index 25
\\E\[\^/\]\+\\Q\\E\[\^/\]\+\\Q
                         ^
[AUDIT   ] CWWKT0016I: Web application available (default_host): http://duczsl29.zylog-blr.com:10080/FirstDemoApp/
[ERROR   ] SRVE0293E: [Servlet Error]-[Failed to load listener: com.worklight.server.bundle.project.JeeProjectActivator]: java.lang.NoClassDefFoundError: com/worklight/server/bundle/api/WorklightBundles
    at java.lang.ClassLoader.defineClass1(Native Method)
    at java.lang.ClassLoader.defineClass(ClassLoader.java:620)
    at com.ibm.ws.classloading.internal.AppClassLoader.internalFindClass(AppClassLoader.java:214)
    at [internal classes]

[ERROR   ] SRVE0279E: Error occured while processing global listeners for the application {0}: {1}
java.lang.NullPointerException
[ERROR   ] SRVE0321E: The [authenticationFilter] filter did not load during start up.
Filter [authenticationFilter]: Could not find required filter class - com.worklight.core.auth.impl.AuthenticationFilter.class
[AUDIT   ] CWWKZ0001I: Application FirstDemoApp started in 1.958 seconds.[ERROR   ] SRVE0315E: An execption occurred: com.ibm.ws.webcontainer.webapp.WebAppErrorReport: javax.servlet.ServletException: Filter [authenticationFilter]: Could not find required filter class - com.worklight.core.auth.impl.AuthenticationFilter.class
    at com.ibm.ws.webcontainer.filter.WebAppFilterManager._loadFilter(WebAppFilterManager.java:557)
    at [internal classes]
Caused by: javax.servlet.ServletException: Filter [authenticationFilter]: Could not find required filter class - com.worklight.core.auth.impl.AuthenticationFilter.class
    ... 3 more
Caused by: java.lang.ClassNotFoundException: com.worklight.core.auth.impl.AuthenticationFilter
    at com.ibm.ws.classloading.internal.UnifiedClassLoader.findClass(UnifiedClassLoader.java:78)
    ... 1 more


[AUDIT   ] CWWKF0011I: The server worklight is ready to run a smarter planet.
[ERROR   ] SRVE0315E: An execption occurred: com.ibm.ws.webcontainer.webapp.WebAppErrorReport: javax.servlet.ServletException: Filter [authenticationFilter]: Could not find required filter class - com.worklight.core.auth.impl.AuthenticationFilter.class
    at com.ibm.ws.webcontainer.filter.WebAppFilterManager._loadFilter(WebAppFilterManager.java:557)
    at [internal classes]
Caused by: javax.servlet.ServletException: Filter [authenticationFilter]: Could not find required filter class - com.worklight.core.auth.impl.AuthenticationFilter.class
    ... 3 more
Caused by: java.lang.ClassNotFoundException: com.worklight.core.auth.impl.AuthenticationFilter
    at com.ibm.ws.classloading.internal.UnifiedClassLoader.findClass(UnifiedClassLoader.java:78)
    ... 1 more

Also my worklight console is not opening, error is:

Failed to deploy the application to Worklight server: Internal Server Error; Error 500: javax.servlet.ServletException: Filter [authenticationFilter]: 
Could not find required filter class - com.worklight.core.auth.impl.AuthenticationFilter.class 
2

There are 2 best solutions below

0
Sachin Thapa On

Verify server.xml file of Worklight Development Server.

Check all <library> tags make sure they are pointing to correct path.

Cheers !!

0
Francisco Oseguera G. On

Wise advise on validating all tags. To begin with, where is 'shared.resource.dir' declared? Wherever it is, the path to it supposedly is '/usr/shared/resources', where we can crawl into the subdirectories and find the corresponding libraries. I found out that a db2 library contained in db2 directory right below resources does work, whereas that in db2 directory below worklight subdirectory, albeit more recent, does not work. Therefore, I copied and replaced the ailing one with the good one... :-) and, well, at least the error message became different. :-D