aist-oceanworks / mudrod

Mining and Utilizing Dataset Relevancy from Oceanographic Datasets to Improve Data Discovery and Access, online demo: https://mudrod.jpl.nasa.gov/#/
https://mudrod.github.io/
15 stars 15 forks source link

Failed to start service with updated code #18

Closed Yongyao closed 8 years ago

Yongyao commented 8 years ago

Both @quintinali and I failed to start the service after updating the code, already spent several hours on it, but still didn't get any clue. @lewismc , can you help take a look? This might be related to some changes recently committed.

It saysSLF4J cannot be found, but I didn't see anyone change the maven dependency.

?? 28, 2016 5:44:35 ?? org.apache.catalina.core.StandardContext listenerStart SEVERE: Exception sending context initialized event to listener instance of class esiptestbed.mudrod.webservlet.MudrodWebListener java.lang.NoClassDefFoundError: org/slf4j/LoggerFactory

lewismc commented 8 years ago

How are you trying to start the service? It is impossible for me to debug unless you give me instructions on how you are attempting to set it up. Only then can I debug what is going on. Thanks n advance.

Yongyao commented 8 years ago

In eclipse, right click project -> run on server, -> then the error would appear. I didn't find the slf4j in any pom though.

If you can't duplicate it, I will just show you tomorrow.

lewismc commented 8 years ago

Thanks, I'll scope it out right now.

lewismc commented 8 years ago

Hi @Yongyao I cannot reproduce this issue, I can only assume it has to do again with your local environment. When I start the .war file from within Tomcat, in Eclipse, all goes to plan. As evidence, I've included screenshots of Mudrod UI running inside of Eclipse at localhost:8080/mudrod-service, I've also included the Servlet Container log

Jul 28, 2016 3:53:31 PM org.apache.catalina.core.AprLifecycleListener init
INFO: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: /Users/lmcgibbn/Library/Java/Extensions:/Library/Java/Extensions:/Network/Library/Java/Extensions:/System/Library/Java/Extensions:/usr/lib/java:.
Jul 28, 2016 3:53:31 PM org.apache.catalina.startup.SetAllPropertiesRule begin
WARNING: [SetAllPropertiesRule]{Server/Service/Connector} Setting property 'maxSpareThreads' to '75' did not find a matching property.
Jul 28, 2016 3:53:31 PM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["http-bio-8080"]
Jul 28, 2016 3:53:31 PM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["ajp-bio-8009"]
Jul 28, 2016 3:53:31 PM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 510 ms
Jul 28, 2016 3:53:31 PM org.apache.catalina.core.StandardService startInternal
INFO: Starting service Catalina
Jul 28, 2016 3:53:31 PM org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet Engine: Apache Tomcat/7.0.54
Jul 28, 2016 3:53:31 PM org.apache.catalina.startup.HostConfig deployDescriptor
INFO: Deploying configuration descriptor /usr/local/apache-tomcat-7.0.54/conf/Catalina/localhost/labkey.xml
Jul 28, 2016 3:53:31 PM org.apache.catalina.startup.SetContextPropertiesRule begin
WARNING: [SetContextPropertiesRule]{Context} Setting property 'debug' to '0' did not find a matching property.
Jul 28, 2016 3:53:31 PM org.apache.tomcat.util.digester.SetPropertiesRule begin
WARNING: [SetPropertiesRule]{Context/Loader} Setting property 'useSystemClassLoaderAsParent' to 'false' did not find a matching property.
Jul 28, 2016 3:53:31 PM sun.reflect.NativeMethodAccessorImpl invoke0
INFO: Deploying resources from exploded modules to web app directory...
Jul 28, 2016 3:53:31 PM sun.reflect.NativeMethodAccessorImpl invoke0
INFO: Module extraction and deployment complete.
Jul 28, 2016 3:53:31 PM sun.reflect.NativeMethodAccessorImpl invoke0
INFO: Cleaning up web app directory...
Jul 28, 2016 3:53:31 PM sun.reflect.NativeMethodAccessorImpl invoke0
INFO: Deleting unused file in web app directory: /usr/local/labkey/labkeywebapp/WEB-INF/attachments
Jul 28, 2016 3:53:31 PM sun.reflect.NativeMethodAccessorImpl invoke0
INFO: Web app directory cleanup complete.
Jul 28, 2016 3:53:40 PM org.apache.catalina.startup.TaglibUriRule body
INFO: TLD skipped. URI: http://www.springframework.org/tags is already defined
Jul 28, 2016 3:53:40 PM org.apache.catalina.startup.TaglibUriRule body
INFO: TLD skipped. URI: http://www.springframework.org/tags/form is already defined
Jul 28, 2016 3:53:40 PM org.apache.catalina.core.ApplicationContext log
INFO: No Spring WebApplicationInitializer types detected on classpath
Jul 28, 2016 3:53:40 PM org.apache.catalina.core.ApplicationContext log
INFO: Initializing Spring root WebApplicationContext
Jul 28, 2016 3:53:45 PM org.apache.catalina.startup.HostConfig deployDescriptor
INFO: Deployment of configuration descriptor /usr/local/apache-tomcat-7.0.54/conf/Catalina/localhost/labkey.xml has finished in 13,608 ms
Jul 28, 2016 3:53:45 PM org.apache.catalina.startup.HostConfig deployWAR
INFO: Deploying web application archive /usr/local/apache-tomcat-7.0.54/webapps/mudrod-service-0.0.1-SNAPSHOT.war
Jul 28, 2016 3:53:45 PM org.apache.catalina.loader.WebappClassLoader validateJarFile
INFO: validateJarFile(/usr/local/apache-tomcat-7.0.54/webapps/mudrod-service-0.0.1-SNAPSHOT/WEB-INF/lib/javax.servlet-3.0.0.v201112011016.jar) - jar not loaded. See Servlet Spec 3.0, section 10.7.2. Offending class: javax/servlet/Servlet.class
Jul 28, 2016 3:53:45 PM org.apache.catalina.loader.WebappClassLoader validateJarFile
INFO: validateJarFile(/usr/local/apache-tomcat-7.0.54/webapps/mudrod-service-0.0.1-SNAPSHOT/WEB-INF/lib/javax.servlet-3.1.jar) - jar not loaded. See Servlet Spec 3.0, section 10.7.2. Offending class: javax/servlet/Servlet.class
Jul 28, 2016 3:53:45 PM org.apache.catalina.loader.WebappClassLoader validateJarFile
INFO: validateJarFile(/usr/local/apache-tomcat-7.0.54/webapps/mudrod-service-0.0.1-SNAPSHOT/WEB-INF/lib/javax.servlet-api-3.1.0.jar) - jar not loaded. See Servlet Spec 3.0, section 10.7.2. Offending class: javax/servlet/Servlet.class
userHistoryMatrix : ./src/main/java/esiptestbed/tmp/UserHistoryMatrix.csv
clickstreamMatrix : ./src/main/java/esiptestbed/tmp/ClickstreamMatrix.csv
timegap : 600
raw_metadataType : RawMetadata
oceanTriples : ./src/main/java/esiptestbed/tmp/Ocean_triples.csv
SessionPort : 443
Cleanup_type_prefix : cleanupLog
downloadWeight : 3
metadataMatrix : ./src/main/java/esiptestbed/tmp/MetadataMatrix.csv
HTTP_type_prefix : rawhttp
metadataSVDMatrix_tmp : ./src/main/java/esiptestbed/tmp/metadataSVDMatrix_tmp.csv
viewf : 200
metadataurl : null
ftpPrefix : vsftpd.log.
clusterName : cody
commentType : comment
SessionStats_prefix : sessionstats
metadata_w : 1
downloadf : 100
ontologyLinkageType : SWEETLinkage
metadataSVDDimension : 50
clickStream_w : 2
indexName : mudrod
userHistory_w : 2
ontologyInputDir : ./src/main/java/esiptestbed/tmp/SWEET_ocean/
searchf : 100
sendingrate : 30
httpPrefix : access_log.
raw_metadataPath : ./src/main/java/esiptestbed/tmp/RawMetadata
mini_userHistory : 5
ontology_w : 2
clickstreamSVDDimension : 50
metadataLinkageType : MetadataLinkage
clickstreamSVDMatrix_tmp : ./src/main/java/esiptestbed/tmp/clickstreamSVDMatrix_tmp.csv
loglevel : 1
userHistoryLinkageType : UserHistoryLinkage
FTP_type_prefix : rawftp
logDir : C:/AIST LOG FILES/
clickStreamLinkageType : ClickStreamLinkage
log4j:WARN No appenders could be found for logger (org.elasticsearch.node).
log4j:WARN Please initialize the log4j system properly.
log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info.
Using Spark's default log4j profile: org/apache/spark/log4j-defaults.properties
16/07/28 15:54:27 INFO SparkContext: Running Spark version 1.4.0
16/07/28 15:54:27 WARN NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable
16/07/28 15:54:27 WARN Utils: Your hostname, LMC-032857 resolves to a loopback address: 127.0.0.1; using 10.99.144.62 instead (on interface en0)
16/07/28 15:54:27 WARN Utils: Set SPARK_LOCAL_IP if you need to bind to another address
16/07/28 15:54:27 INFO SecurityManager: Changing view acls to: lmcgibbn
16/07/28 15:54:27 INFO SecurityManager: Changing modify acls to: lmcgibbn
16/07/28 15:54:27 INFO SecurityManager: SecurityManager: authentication disabled; ui acls disabled; users with view permissions: Set(lmcgibbn); users with modify permissions: Set(lmcgibbn)
16/07/28 15:54:27 INFO Slf4jLogger: Slf4jLogger started
16/07/28 15:54:27 INFO Remoting: Starting remoting
16/07/28 15:54:27 INFO Remoting: Remoting started; listening on addresses :[akka.tcp://sparkDriver@10.99.144.62:52224]
16/07/28 15:54:27 INFO Utils: Successfully started service 'sparkDriver' on port 52224.
16/07/28 15:54:27 INFO SparkEnv: Registering MapOutputTracker
16/07/28 15:54:28 INFO SparkEnv: Registering BlockManagerMaster
16/07/28 15:54:28 INFO DiskBlockManager: Created local directory at /usr/local/apache-tomcat-7.0.54/temp/spark-d41997d7-75fa-47bd-87d1-382054788635/blockmgr-f91a20b1-15ca-4bc0-bc25-34ee007d6321
16/07/28 15:54:28 INFO MemoryStore: MemoryStore started with capacity 1966.1 MB
16/07/28 15:54:28 INFO HttpFileServer: HTTP File server directory is /usr/local/apache-tomcat-7.0.54/temp/spark-d41997d7-75fa-47bd-87d1-382054788635/httpd-267eb2a3-8867-47a4-9b72-370f457cc09a
16/07/28 15:54:28 INFO HttpServer: Starting HTTP Server
16/07/28 15:54:28 INFO Utils: Successfully started service 'HTTP file server' on port 52225.
16/07/28 15:54:28 INFO SparkEnv: Registering OutputCommitCoordinator
16/07/28 15:54:28 INFO Utils: Successfully started service 'SparkUI' on port 4040.
16/07/28 15:54:28 INFO SparkUI: Started SparkUI at http://10.99.144.62:4040
16/07/28 15:54:28 INFO Executor: Starting executor ID driver on host localhost
16/07/28 15:54:28 INFO Utils: Successfully started service 'org.apache.spark.network.netty.NettyBlockTransferService' on port 52226.
16/07/28 15:54:28 INFO NettyBlockTransferService: Server created on 52226
16/07/28 15:54:28 INFO BlockManagerMaster: Trying to register BlockManager
16/07/28 15:54:28 INFO BlockManagerMasterEndpoint: Registering block manager localhost:52226 with 1966.1 MB RAM, BlockManagerId(driver, localhost, 52226)
16/07/28 15:54:28 INFO BlockManagerMaster: Registered BlockManager

screen shot 2016-07-28 at 3 56 37 pm 2

lewismc commented 8 years ago

I can also access the Spark UI running on http://10.99.144.62:4040/jobs/

Yongyao commented 8 years ago

Hi @lewismc .Based on the printed logs, I can see the code you just executed is not the latest code for sure. You may need to sync with the remote repo.

Yongyao commented 8 years ago

This is the code weeks ago.

Yongyao commented 8 years ago

Problem solved. Update maven project to sync Eclipse project settings.

lewismc commented 8 years ago

Mvn eclipse:eclipse right?

On Thursday, July 28, 2016, Yongyao Jiang notifications@github.com wrote:

Closed #18 https://github.com/mudrod/mudrod/issues/18.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/mudrod/mudrod/issues/18#event-738650631, or mute the thread https://github.com/notifications/unsubscribe-auth/ABHJl9pZnatqCpWnOS0C4cNqkUl_nCpqks5qaVPBgaJpZM4JXrgG .

Lewis Dr. Lewis J. McGibbney Ph.D, B.Sc Director Phone: +1(626)498-3090 Skype: lewis.john.mcgibbney Email: lewis.mcgibbney@gmail.com

Yongyao commented 8 years ago

Mvn eclipse:eclipse is something I have done before project is imported into eclipse. It turns out that it is not enough if I want to run service, I need to right click on mudrod-service, and click maven -> update project. But I have no idea why it is necessary and what are their differences.

lewismc commented 8 years ago

Because eclipse does not automatically update to the newly configured project. You should ALWAYS refresh yourproject in eclipse.

On Jul 28, 2016 7:26 PM, "Yongyao Jiang" notifications@github.com wrote:

Mvn eclipse:eclipse is something I have done before project is imported into eclipse. It turns out that it is not enough if I want to run service, I need to right click on mudrod-service, and click maven -> update project. But I have no idea why it is necessary and what are their differences.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/mudrod/mudrod/issues/18#issuecomment-236079056, or mute the thread https://github.com/notifications/unsubscribe-auth/ABHJlxt3z1BG-Zy0dxb3Gkt3-W2FEn_xks5qaWTsgaJpZM4JXrgG .

Yongyao commented 8 years ago

Program solved. For the record, fixing this problem needs to delete some meta configuration of workspace.