When start the development server, Java will crash What is the cause?
(OS)
Mac OS X 10.6.6
(Java)
Java(TM) SE Runtime Environment (build 1.6.0_24-b07-334-10M3326)
Java HotSpot(TM) 64-Bit Server VM (build 19.1-b02-334, mixed mode)
(GAE) Version 1.4.2
(console)
admin$ ./dev_appserver.sh --port=8080 /Users/admin/projects/sample1/war/
2011-03-10 12:51:02.582 java[2542:903] [Java CocoaComponent compatibility mode]: Enabled
2011-03-10 12:51:02.583 java[2542:903] [Java CocoaComponent compatibility mode]: Setting timeout for SWT to 0.100000
2011/03/10 3:51:03 com.google.apphosting.utils.jetty.JettyLogger info
####: Logging to JettyLogger(null) via com.google.apphosting.utils.jetty.JettyLogger
2011/03/10 3:51:04 com.google.a开发者_JS百科pphosting.utils.config.AppEngineWebXmlReader readAppEngineWebXml
####: Successfully processed /Users/admin/projects/sample1/war/WEB-INF/appengine-web.xml
2011/03/10 3:51:04 com.google.apphosting.utils.config.AbstractConfigXmlReader readConfigXml
####: Successfully processed /Users/admin/projects/sample1/war/WEB-INF/web.xml
2011/03/10 3:51:04 com.google.apphosting.utils.jetty.JettyLogger info
####: jetty-6.1.x
2011/03/10 3:51:04 com.sun.jersey.api.core.PackagesResourceConfig init
####: Scanning for root resource and provider classes in the packages:
sample1.resources
jp.tryden.resources.test
2011/03/10 3:51:04 com.sun.jersey.api.core.ScanningResourceConfig logClasses
####: Root resource classes found:
class sample1.resources.CheckinsResource
class sample1.resources.UsersResource
class sample1.resources.ItemsResource
2011/03/10 3:51:04 com.sun.jersey.api.core.ScanningResourceConfig init
####: No provider classes found.
2011/03/10 3:51:05 com.sun.jersey.server.impl.application.WebApplicationImpl initiate
####: Initiating Jersey application, version 'Jersey: 1.1.5.1 03/10/2010 02:33 PM'
2011/03/10 3:51:06 com.google.apphosting.utils.jetty.JettyLogger info
####: Started SelectChannelConnector@127.0.0.1:8080
2011/03/10 3:51:06 com.google.appengine.tools.development.DevAppServerImpl start
####: The server is running at http://localhost:8080/
admin$ ( <- Stopped!! )
(crash log)
Process: java [3466]
Path: /System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home/bin/java
Identifier: java
Version: 1.0 (1.0)
Code Type: X86-64 (Native)
Parent Process: java [3465]
Date/Time: 2011-03-10 14:22:12.206 +0900
OS Version: Mac OS X 10.6.6 (10J567)
Report Version: 6
Exception Type: EXC_BAD_ACCESS (SIGSEGV)
Exception Codes: KERN_INVALID_ADDRESS at 0x0000000000000000
Crashed Thread: 10 Dispatch queue: com.apple.root.low-priority
Thread 0: Dispatch queue: com.apple.main-thread
0 ??? 0x000000010301f383 0 + 4345426819
1 ??? 0x000000010300685a 0 + 4345325658
2 ??? 0x0000000103006e8d 0 + 4345327245
3 ??? 0x00000001030069b3 0 + 4345326003
4 ??? 0x00000001030069b3 0 + 4345326003
5 ??? 0x0000000103006e8d 0 + 4345327245
6 ??? 0x000000010300685a 0 + 4345325658
7 ??? 0x000000010300685a 0 + 4345325658
8 ??? 0x000000010300685a 0 + 4345325658
...
This is a bug introduced in the Apple JDK 10.6 Update 4. Workarounds are discussed in the appengine group. A developer at Apple has also acknowledged the issue, but I couldn't find a public bug report.
If you have a backup of the previous (Update 3) installation (/Library/Java), restoring that should solve the problem. The previous version of the Apple JDK can be downloaded from http://supportdownload.apple.com/download.info.apple.com/Apple_Support_Area/Apple_Software_Updates/Mac_OS_X/downloads/061-8453.201019.Jva3w/JavaForMacOSX10.6Update3.dmg You will have to find a way (such as Pacifist) to force it to overwrite the current (more recent) installation.
See here for a full discussion including a detailed resolution:
http://code.google.com/p/googleappengine/issues/detail?id=4712
See answer #39.
精彩评论