MagSafe: Not So Safe?
I was recently using my charger to, obviously, charge my computer. I left it on the table i normally leave it on, and go to pull out my chair. This is when things get bad.
My chair catches the wire of the MagSafe adapter, and rather than the MagSafe unplugging from my computer like it should, it brings the whole entire computer crashing to the floor. Im not if anything is wrong at the moment, it was working fine when i turned it back on, but a friend of mine said his MacBook worked and then shut off one day on him due to a similar situation.
I'm rather angry at the fact this happen, any one else ever have a similar problem? Is this covered by Apple Care? I thought the MagSafe was made to avoid situations like this
Welcome to Apple Discussions!
Sorry to hear about your mishap. Since you say everything is functioning at the moment, now is the time to backup your data in event anything does go downhill*:
http://www.macmaps.com/backup.html
What you say could only happen if something caused the magnet of the magsafe to be stronger than it is suggested it is designed, or some food or water might have dried on the Magsafe port and caused it to stick in the port. Call the AppleCare and have them look at the magnet to make sure it is functioning normally both on the power adapter and the outlet of the machine.
Since this is only a user to user forum, we can't predict how they will react.
If you are unhappy with their reaction, ask for a case number, and to be transfered to customer relations.
You have this page on your side:
http://www.apple.com/macbookpro/features.html
Even the power cord is a feature.
The MacBook Pro power adapter with MagSafe connector is a magnetic connection instead of a physical one. So, if you happen to trip over the power cord, you won’t send MacBook Pro flying. The cord simply disconnects, without damage to either the cord or the notebook.
Good luck!
- * Links to my pages may give me compensation.
Message was edited by: a brody
Similar Messages
-
Some programs crash but not in safe mode or for guest user
Hoping that some talented and kind Mac wizard will help me solve a bizarre problem: Some but not all of my programs have started crashing immediately upon launch, but not in safe mode, nor when I log in as a guest user.
The problem began on February 5th, right after I installed an update to my OS (bringing it up to version 10.7.3), which included an update to the firmware for my computer, a Mac mini from mid-2010. The programs that began crashing upon launch *may* be those that were open at that time, but I can’t be sure. They include Adobe Reader, Picasa, Word for Mac, and a sweet little utility called uCalendarX.
Specifically what happens with, say, uCalendarX, is this: After I launch it, nothing appears on screen for a few seconds, and then comes a message that it is trying restore its windows, with a choice of whether to attempt restoring them or not. After a few more seconds comes the news that it has quit unexpectedly. The first several dozen lines of the crash log appear at the end of this posting.
So far my troubleshooting has revealed the following:
(a) When I reboot in safe mode, the programs that crash now work normally.
(b) When I boot the usual way but log on a guest user, the programs that crash now work normally.
(c) Fully emptying the trash made no difference.
(d) The problem was not solved by restoring my hard drive (via Time Machine) to its state the day before I downloaded that update to the OS and the firmware. (This was a drastic step, the intervention of last resort, and I was sure it would work. But no. Perhaps I did not go back far enough for the restoration.)
(e) Deleting the plist files and plist.lockfiles made no difference.
(f) Deleting the files for the app under Saved Application States made no difference.
(g) Disabing the user’s font cache (as happens in safe mode) made no difference.
(h) Uninstalling Adobe Reader, emptying the trash, downloading the latest version, and installing that made no difference – this latest version newly installed continues to crash (but not for a guest user, nor for me, the administrator, in safe mode).
(i ) Repairing permissions on the hard drive made no difference.
I will be mighty grateful for a solution to this perplexing, vexing problem!
B.t.w., I don’t know Unix but was able to do all those (fruitless) interventions listed above.
Gordon Bear
Ramsey NJ U S A
The log from one of the many crashes of uCalendarX begins as follows:
Process: uCalendarX [750]
Path: /Applications/uCalendarX 3.2.3/uCalendarX 3-2-3.app/Contents/MacOS/uCalendarX
Identifier: com.riuz.ucalendarx
Version: 3.2.3 (3.2.3)
Code Type: X86 (Native)
Parent Process: launchd [289]
Date/Time: 2012-02-20 00:38:48.931 -0500
OS Version: Mac OS X 10.7.3 (11D50b)
Report Version: 9
Interval Since Last Report: 2463 sec
Crashes Since Last Report: 3
Per-App Interval Since Last Report: 30 sec
Per-App Crashes Since Last Report: 3
Anonymous UUID: 0CA8DA26-8927-4AC3-B35F-3B2E9FD65A8E
Crashed Thread: 4
Exception Type: EXC_BAD_ACCESS (SIGSEGV)
Exception Codes: KERN_INVALID_ADDRESS at 0x000000008bcc45ab
External Modification Warnings:
Thread creation by external task.
VM Regions Near 0x8bcc45ab:
CoreServices 0000000004fd0000-00000000051ee000 [ 2168K] rw-/rwx SM=COW
-->
__TEXT 000000008fe52000-000000008fe85000 [ 204K] r-x/rwx SM=COW /usr/lib/dyld
Application Specific Information:
objc[750]: garbage collection is OFF
Thread 0:: Dispatch queue: com.apple.main-thread
0 libsystem_kernel.dylib 0x920136e6 __open + 10
1 libFontParser.dylib 0x9cc5b403 TFileDescriptorContext::TFileDescriptorContext(char const*) + 77
2 libFontParser.dylib 0x9cc5b1c5 TFileDataReference::TFileDataReference(char const*) + 65
3 libFontParser.dylib 0x9cc5b056 TFileDataSurrogate::TFileDataSurrogate(char const*, bool) + 136
4 libFontParser.dylib 0x9cc59af3 TFont::CreateFontEntitiesForFile(char const*, bool, TSimpleArray<TFont*>&, bool, short, char const*) + 2581
5 libFontParser.dylib 0x9cc58a7a FPFontCreateFontsWithPath + 193
6 libCGXType.A.dylib 0x950164b0 create_private_data_with_path + 26
7 com.apple.CoreGraphics 0x95349ecf CGFontCreateFontsWithPath + 33
8 com.apple.CoreGraphics 0x95349b09 CGFontCreateFontsWithURL + 442
9 com.apple.CoreText 0x90e1c1aa TCGFont::TCGFont(__CFURL const*, bool) + 90
10 com.apple.CoreText 0x90e1bfb2 TCGFontCache::CopyFont(__CFURL const*) const + 92
11 com.apple.CoreText 0x90e1be6c TBaseFont::CopyNativeFont() const + 50
12 com.apple.CoreText 0x90e1bd6f TTableStore::CopyTable(unsigned int, TCFRetained<__CFData const*>&) + 81
13 com.apple.CoreText 0x90e1bade TBaseFont::CopyTable(unsigned int) const + 72
14 com.apple.CoreText 0x90e1ba0f TcmapTable::TcmapTable(TBaseFont const&) + 31
15 com.apple.CoreText 0x90e1b8fd TBaseFont::GetGlyphsForCharacterRange(CFRange, unsigned short*) const + 27
16 com.apple.CoreText 0x90e1b79b TASCIIDataCache::TASCIIDataCache(TBaseFont const*) + 83
17 com.apple.CoreText 0x90e1b70f TBaseFont::CreateASCIIDataCache() const + 47
18 com.apple.CoreText 0x90e1b690 TFont::InitAdvanceCache() const + 42
19 com.apple.CoreText 0x90e1b4ad TASCIIEncoder::Encode() + 45
20 com.apple.CoreText 0x90e4433f TGlyphEncoder::EncodeChars(CFRange, TAttributes const&, TGlyphList<TDeletedGlyphIndex>&, TGlyphEncoder::Fallbacks) + 925
21 com.apple.CoreText 0x90e19ff6 TTypesetterAttrString::Initialize(__CFAttributedString const*) + 322
22 com.apple.CoreText 0x90e19b9d CTLineCreateWithAttributedString + 47
23 com.apple.HIToolbox 0x963d2b2d TCoreTextEngine::LayoutSingleLine(THIThemeTextInfo*, float) + 23
24 com.apple.HIToolbox 0x963d2a9a TCoreTextEngine::Layout(THIThemeTextInfo*, float, float, TextLayoutType) + 64
25 com.apple.HIToolbox 0x963ad2c9 TCoreTextEngine::VerifyLayout(THIThemeTextInfo*, float, float, LayoutIntent) + 309
26 com.apple.HIToolbox 0x96410b0a TCoreTextEngine::GetThemeTextDimensions(float, THIThemeTextInfo*, float*, float*, float*) + 54
27 com.apple.HIToolbox 0x9640fc51 DataEngine::GetTextDimensions(void const*, float, HIThemeTextInfo*, float*, float*, float*) + 283
28 com.apple.HIToolbox 0x963d1fc5 HIThemeGetTextDimensions + 187
29 com.apple.HIToolbox 0x963d1ca3 HIMenuBarView::MeasureMenuTitle(MenuData*, unsigned char, float*, int, unsigned char*) + 451
30 com.apple.HIToolbox 0x963d1a49 HIMenuBarView::MeasureAppMenus() + 261
31 com.apple.HIToolbox 0x963abb5d HIMenuBarView::EnsureBarLayout() + 489
32 com.apple.HIToolbox 0x963ab152 HIMenuBarView::DrawSelf(short, __HIShape const*, CGContext*) + 520
33 com.apple.HIToolbox 0x963aac22 HIView::DrawCacheOrSelf(short, __HIShape const*, CGContext*) + 86
34 com.apple.HIToolbox 0x963aaa42 HIView::SendDraw(short, OpaqueGrafPtr*, __HIShape const*, CGContext*) + 124
35 com.apple.HIToolbox 0x964395c7 HIView::RecursiveDrawComposited(__HIShape const*, __HIShape const*, unsigned long, HIView*, CGContext*, unsigned char, float) + 755
36 com.apple.HIToolbox 0x964398b9 HIView::RecursiveDrawComposited(__HIShape const*, __HIShape const*, unsigned long, HIView*, CGContext*, unsigned char, float) + 1509
37 com.apple.HIToolbox 0x9643a86b HIView::DrawComposited(short, OpaqueGrafPtr*, __HIShape const*, unsigned long, HIView*, CGContext*) + 1227
38 com.apple.HIToolbox 0x9643a9b3 HIView::Draw(short, OpaqueGrafPtr*, unsigned long) + 81
39 com.apple.HIToolbox 0x9643ad7b HIView::Render(unsigned long, CGContext*) + 45
40 com.apple.HIToolbox 0x963d084f WindowData::PrepareForVisibility() + 137
41 com.apple.HIToolbox 0x963cf893 _ShowHideWindows + 355
42 com.apple.HIToolbox 0x963cf728 ShowHide + 44
43 com.apple.HIToolbox 0x96399b09 _GetMenuBarWindow + 872
44 com.apple.HIToolbox 0x96399765 GetMenuBarView(MenuData*, unsigned char) + 74
45 com.apple.HIToolbox 0x963a2f3a MBarMenuRgn + 26
46 com.apple.HIToolbox 0x963a2d27 _ZL7ShowBar21MenuBarAnimationStylehhh + 281
47 com.apple.HIToolbox 0x963cd42a _ZL21UpdateAggregateUIMode21MenuBarAnimationStylehh + 772
48 com.apple.HIToolbox 0x963e38e5 ShowMenuBar + 163
49 com.apple.AppKit 0x001a9cad -[NSApplication finishLaunching] + 1331
50 com.apple.AppKit 0x001a9374 -[NSApplication run] + 142
51 com.apple.AppKit 0x0043d261 NSApplicationMain + 1054
52 com.riuz.ucalendarx 0x00001eea _start + 216
53 com.riuz.ucalendarx 0x00001e11 start + 4Thanks for thinking about my problem. I've already experimented with creating a new user, a co-administrator. The programs don't crash when that account is running, just as they don't crash when the guest-user's account runs. So it seems that the problem is limited to the default user's account, which is the one that was running when I installed the updates to the OS and the firmware. Another clue is that the programs that crash as soon as they are launched are *probably* the ones that were open at that time in that account. Yet deleting Saved Application States does not keep the programs from crashing when next launched.
So the mystery continues, but these additional facts will help with the diagnosis, I hope.
Thanks again for your suggestion.
Gordon -
Cant' open Firefox at all, not in safe mode either, tried creating new profile, cant' get in to do that, tried uninstalling and reinstalling, switching off and on, nothing works. Get error: "The instruction at "0x00000000" referenced memory at "0x00000000". The memory could not be read."
== This happened ==
Every time Firefox opened
== today. ==
== User Agent ==
Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0)The solution is easy.
Install "Malwarebytes' Anti-Malware" free edition and use it. This program found malware in your pc. After that clean this malware. Finally instal Firefox again and enyoy it because this installation is correct and clean. Regards. -
Native library NOT thread safe - how to use it via JNI?
Hello,
has anybody ever tried to use a native library from JNI, when the library is not thread safe?
The library (Windows DLL) was up to now used in an MFC App and thus was only used by one user - that meant one thread - at a time.
Now we would like to use the library like a "server": many Java clients connect the same time to the library via JNI. That would mean each client makes its calls to the library in its own thread. Because the library is not thread safe, this would cause problems.
Now we discussed to load the library several times - separately for each client (for each thread).
Is this possible at all? How can we do that?
And do you think we can solve the problem in this way?
Are there other ways to use the library, though it is not thread safe?
Any ideas welcome.
Thanks for any contributions to the discussion, Ina(1)
has anybody ever tried to use a native library from
JNI, when the library (Windows DLL) is not thread safe?
Now we want many Java clients.
That would mean each client makes its calls
to the library in its own thread. Because the library
is not thread safe, this would cause problems.Right. And therefore you have to encapsulate the DLL behind a properly synchronized interface class.
Now the details of how you have to do that depends: (a) does the DLL contain state information other than TLS? (b) do you know which methods are not thread-safe?
Depending on (a), (b) two extremes are both possible:
One extreme would be to get an instance of the interface to the DLL from a factory method you'll have to write, where the factory method will block until it can give you "the DLL". Every client thread would obtain "the DLL", then use it, then release it. That would make the whole thing a "client-driven" "dedicated" server. If a client forgets to release the DLL, everybody else is going to be locked out. :-(
The other extreme would be just to mirror the DLL methods, and mark the relevant ones as synchronized. That should be doable if (a) is false, and (b) is true.
(2)
Now we discussed to load the library several times -
separately for each client (for each thread).
Is this possible at all? How can we do that?
And do you think we can solve the problem in this
way?The DLL is going to be mapped into the process address space on first usage. More Java threads just means adding more references to the same DLL instance.
That would not result in thread-safe behavior. -
Coherence SimpleParser class is not thread safe?
Coherense has very convinent XML utility class, which we use it a lot within our Coherence related applications.
But we encounter some mysterious lock up (maybe deadlock?) issue and identified that it might be that the com.tangosol.run.xml.SimpleParser class is not thread safe.
We are using tomcat 6 and spring 2.0.6.
One of the webapp has 2 bean which implements InitializingBean interface.
Bean A's afterPropertiesSet() method will use com.tangosol.run.xml.XmlHelper.loadXml method to parse a XML file.
Bean B's afterPropertiesSet() method will acts as a tcp extend client and retrieve some data from a coherence cluster. Which I believe coherence will also use it's XML utility class when parsing the configuration files.
We encounter tomcat lockup (which never finish startup webapp deployment porcess) randomly like 1 out of 2 or 3 tries.
Use jconsole and connect to tomcat we can see that the main thread stuck in SimpleParser class. Here is the thread dump.
Name: main
State: RUNNABLE
Total blocked: 156 Total waited: 0
Stack trace:
com.tangosol.run.xml.SimpleParser.instantiateDocument(SimpleParser.java:150)
com.tangosol.run.xml.SimpleParser.parseXml(SimpleParser.java:115)
- locked com.tangosol.run.xml.SimpleParser@f10c77
com.tangosol.run.xml.SimpleParser.parseXml(SimpleParser.java:71)
com.tangosol.run.xml.SimpleParser.parseXml(SimpleParser.java:84)
com.tangosol.run.xml.XmlHelper.loadXml(XmlHelper.java:109)
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1201)
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1171)
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:425)
org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:251)
org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:156)
- locked java.util.concurrent.ConcurrentHashMap@dee55c
org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:248)
org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:160)
org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:287)
org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:352)
- locked java.lang.Object@d21555
org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:244)
org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:187)
org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:49)
org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3830)
org.apache.catalina.core.StandardContext.start(StandardContext.java:4337)
- locked org.apache.catalina.core.StandardContext@1c64ed8
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:791)
- locked java.util.HashMap@76a6d9
org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:771)
org.apache.catalina.core.StandardHost.addChild(StandardHost.java:525)
org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:825)
org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:714)
org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:490)
org.apache.catalina.startup.HostConfig.start(HostConfig.java:1138)
org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:311)
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117)
org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1053)
- locked org.apache.catalina.core.StandardHost@1c42c4b
org.apache.catalina.core.StandardHost.start(StandardHost.java:719)
- locked org.apache.catalina.core.StandardHost@1c42c4b
org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)
- locked org.apache.catalina.core.StandardEngine@37fd24
org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)
org.apache.catalina.core.StandardService.start(StandardService.java:516)
- locked org.apache.catalina.core.StandardEngine@37fd24
org.apache.catalina.core.StandardServer.start(StandardServer.java:710)
- locked [Lorg.apache.catalina.Service;@1cc55fb
org.apache.catalina.startup.Catalina.start(Catalina.java:566)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
java.lang.reflect.Method.invoke(Unknown Source)
org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288)
org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)
After we add the depends-on tag to enforce bean B wait on bean A to finish initialization, we no longer encounter the lockup during tomcat startup.
We suspect that maybe SimpleParser class is not thread safe and will cause potential deadlock issue.
Edited by: user639604 on Jun 22, 2009 10:36 AMWhile it doesn't show up as deadlock, I believe it probably is, as evidenced by these two threads:
"Timer-0" prio=10 tid=0xcb9a2800 nid=0x454b in Object.wait() [0xcb6e0000..0xcb6e10a0]
java.lang.Thread.State: RUNNABLE
at com.tangosol.run.xml.SimpleParser.instantiateDocument(SimpleParser.java:150)
at com.tangosol.run.xml.SimpleParser.parseXml(SimpleParser.java:115)
- locked <0xf44e52f0> (a com.tangosol.run.xml.SimpleParser)
at com.tangosol.run.xml.SimpleParser.parseXml(SimpleParser.java:71)
at com.tangosol.run.xml.SimpleParser.parseXml(SimpleParser.java:99)
at com.tangosol.run.xml.XmlHelper.loadXml(XmlHelper.java:129)
at com.tangosol.run.xml.XmlHelper.loadXml(XmlHelper.java:95)
at com.tangosol.run.xml.XmlHelper.loadXml(XmlHelper.java:72)
at com.tangosol.util.ExternalizableHelper.<clinit>(ExternalizableHelper.java:4466)
at com.evidentsoft.opcache.coherence.OPCacheCoherenceStorage.retrieve(OPCacheCoherenceStorage.java:341)
at com.evidentsoft.opcache.coherence.OPCacheCoherenceStorage.retrieve(OPCacheCoherenceStorage.java:420)
at com.evidentsoft.opcache.OPCacheManager.find(OPCacheManager.java:68)
at com.evidentsoft.logserver.coherence.ClusterDetector.detectNewClusters(ClusterDetector.java:97)
at com.evidentsoft.logserver.coherence.ClusterDetector.access$000(ClusterDetector.java:19)
at com.evidentsoft.logserver.coherence.ClusterDetector$1.run(ClusterDetector.java:67)
at java.util.TimerThread.mainLoop(Unknown Source)
at java.util.TimerThread.run(Unknown Source)
"main" prio=10 tid=0x08059000 nid=0x4539 in Object.wait() [0xf7fd0000..0xf7fd11f8]
java.lang.Thread.State: RUNNABLE
at com.tangosol.run.xml.SimpleParser.instantiateDocument(SimpleParser.java:150)
at com.tangosol.run.xml.SimpleParser.parseXml(SimpleParser.java:115)
- locked <0xf44ecd90> (a com.tangosol.run.xml.SimpleParser)
at com.tangosol.run.xml.SimpleParser.parseXml(SimpleParser.java:71)
at com.tangosol.run.xml.SimpleParser.parseXml(SimpleParser.java:84)
at com.tangosol.run.xml.XmlHelper.loadXml(XmlHelper.java:109)
at com.evidentsoft.coherence.util.ClusterConfigurator.generateConfigFile(ClusterConfigurator.java:319)
at com.evidentsoft.coherence.util.ClusterConfiguratorProxy.afterPropertiesSet(ClusterConfiguratorProxy.java:51)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1201)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1171)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:425)
at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:251)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:156)
- locked <0xd65efb88> (a java.util.concurrent.ConcurrentHashMap)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:248)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:160)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:287)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:352)
- locked <0xd65efc28> (a java.lang.Object)
at org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:244)
at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:187)
at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:49)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3830)
at org.apache.catalina.core.StandardContext.start(StandardContext.java:4337)
- locked <0xd6092f60> (a org.apache.catalina.core.StandardContext)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:791)
- locked <0xd54ff278> (a java.util.HashMap)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:771)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:525)
at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:825)
at org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:714)
at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:490)
at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1138)
at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:311)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1053)
- locked <0xd54ff1e8> (a org.apache.catalina.core.StandardHost)
at org.apache.catalina.core.StandardHost.start(StandardHost.java:719)
- locked <0xd54ff1e8> (a org.apache.catalina.core.StandardHost)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)
- locked <0xd4fa60b8> (a org.apache.catalina.core.StandardEngine)
at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)
at org.apache.catalina.core.StandardService.start(StandardService.java:516)
- locked <0xd4fa60b8> (a org.apache.catalina.core.StandardEngine)
at org.apache.catalina.core.StandardServer.start(StandardServer.java:710)
- locked <0xd4f17ea0> (a [Lorg.apache.catalina.Service;)
at org.apache.catalina.startup.Catalina.start(Catalina.java:566)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)The reason it isn't showing up as a deadlock in the thread dump is that the ExternalizableHelper static initializer isn't completing, so the other thread (blocking it) is waiting indefinitely on that class to become available.
Peace,
Cameron Purdy | Oracle Coherence -
HTTP request/response object not thread safe.
According to the serlvet spec. Http Request/Response
are not thread safe. Quoting from the Spec:
" Implementations of the request and response objects are not guaranteed to be thread safe. This means that they should only be used within the scope of the request handling thread. References to the request and response objects must not be given to objects executing in other threads as the resulting behavior may be nondeterministic."
This has prompt me to ask the following question.
For Example I have a servlet which does the following
request.setAttribute("myVar","Hello");
The request and response is dispatched(using RequestDispatch.include(request,response)) to another
servlet which retrieve this attribute i.e request.getAttribute("myVar");
Is this safe?
The Spec only said "The Container Provider must ensure that the dispatch of the request to a target
servlet occurs in the same thread of the same VM as the original request." I take this meaning that the targeting servlet does not have to run in the same thread(only dispatch), otherwise it would be safe.To put it another way, you can only have onle thing working on a request at a time. For instance, the ServletContext is available to all servlets running on a server. If you tried to save a particular request to the ServletContext, it would potentially be available to many concurrently running servlets. They could all change whatever in it at the same time. Each servlet is in its own running thread. Hope that helps some.
-
JTextArea: Not thread safe
I am working on a lobby system with a chat are using Networking, and recently I noticed that occasionally my JTextArea does not append the data I give it, even if I have a System.out.println() directly before which shows me what it is being passed, and it is being passed correct Strings, it is just not appending them.
Thread updateText = new Thread() {
public void run()
for(;;)
try {
for (int x = 0; x < texts.size(); x++) {
System.out.println("ADDED: "+texts.get(x));
textArea.append(texts.get(x));
texts.clear();
scrollToEnd(textArea);
Thread.sleep(100);
} catch (InterruptedException ex) {
Logger.getLogger(Main.class.getName()).log(Level.SEVERE, null, ex);
};I have an ArrayList texts, which keeps track of what is being typed into the Chat Area. This code displays correctly What I want it to, i.e. "ADDED: Hello guys, etc.", however the JTextArea does not update. Is there something to make the JTextArea thread-safe because I have heard on several sites that JTextAreas are not thread-safe.
Any help would be greatly appreciated.I changed my code to this: and now it does not work at all, i.e., the JTextArea never updates:
Thread updateText = new Thread() {
public void run()
for(;;)
try {
SwingUtilities.invokeAndWait(update);
} catch (InterruptedException ex) {
Logger.getLogger(Main.class.getName()).log(Level.SEVERE, null, ex);
} catch (InvocationTargetException ex) {
Logger.getLogger(Main.class.getName()).log(Level.SEVERE, null, ex);
Runnable update = new Runnable() {
public void run()
try {
texts.clear();
scrollToEnd(textArea);
for (int x = 0; x < texts.size(); x++) {
System.out.println("ADDED: " + texts.get(x));
textArea.append(texts.get(x));
Thread.sleep(100);
} catch (InterruptedException ex) {
Logger.getLogger(Main.class.getName()).log(Level.SEVERE, null, ex);
}; -
In Which case Vo extension is not upgrade safe
Hi all,
In Which case Vo extension is not upgrade safe
kumarHi Anand,
The extended VO with extra parameters or validation is going to substitute the seeded VO after the deployment.
So how does it matter after upgrade if any changes in the seeded VO causing VO extension to stop working?
If this is the case, what is the best practice to customize a seeded VO.
I am very new to OAF and started working on extending a seeded VO.
Any pointers will be much appreciated.
Thanks,
-Mukesh. -
Java.util.zip.ZipFile is not thread-safe?
I didn't find any notes in its javadoc.
Actually I want to know whether ZipFile.getInputStream(ZipEntry) method is thread-safe. As I mentioned there is no information in the javadoc but I suppose that ZipFile is not thread-safe.
Am I right?More classes are safe if you don't attempt to change
anything. However if you change the ZIP file while
attempting to read it, forget it.I doubt that you can read any 'file' without 'changing' something.
Low level file io almost always uses buffers. I am not even sure if modern operating systems allow byte access to files on the hard drive anymore. And buffers are modified when they are read. -
Running Mac 10.5.8 Updated to FF 8.0 - keeps crashing whenever FF opens - can not launch safe mode either - looks like many people here are having same issue - solutions all keep saying it has something to do with roboform 7.6.2 (which is for windows) or the profile. I have created new profile and updated the mac roboform - still no luck - have sent in MANY crash reports with no response ( one was Crash ID: bp-0eea6eb2-aba3-478a-bfb1-8f00d2111110 ) - anyone else find solution other than roboform or profile, or how do i get back to prior version?
Any suggestions?
My mail is still not functioning and crashes everytime I open it or check archived messages. -
What does, "swing is not thread safe." mean?
can anyone explain what that means in detail?
[Google can|http://letmegooglethatforyou.com/?q=swing+is+not+thread+safe+tutorial]
For better response, you may wish to ask a specific question that's answerable without having to write a book chapter. -
Repaint() is not thread-safe?
I saw a description that says repaint() is thread-safe in an old swing tutorial, but not in the current tutorial and its javadoc. So can I assume repaint() is not thread-safe and I should call it from EDT? ... Or if they are thread-safe, why does Sun not document it?
repaint() calls paint() on EDT... but it calculates dirty region on the current thread and does not get AWTTreeLock.I don't think so.
repaint() is a java.awt.Component method and doesn't know about Swing's RepaintManager and dirty regions. There may be somthing similar at the AWT level that escaped me, but looking at the JDK1.6 source code, java.awt.Component.repaint() just repaints the whole component.
Now repaint(long, int, int, int, int) has two versions.
At the AWT level, it just posts a paint event for the specified region. No race condition, and no risk that he region be wrong, but possibility to invoke multiple paint(Graphics) that overlap, that is, to paint several times the same area - it may be an optimization problem, but it doesn't jeopardize the consistency of the drawing.
At the Swing level, it does compute dirty regions. In Repaint manageer, the call to extendDirtyRegion(...) is protected within a synchronized block, but the code before that is not. From a quick look, that code is:
1) walking up the component hierarchy to find the root, which may not be thread-safe, but a well-behaved application shouldn't change the hierarchy from outside the EDT.
2) walking up a chain of "delegate" RepaintManager, which I knew nothing about... Apparently it's a sun's implementation specific construct, each JComponent can be assigne d a delegate RepaintManager. Again I would claim that such things should not happen outside of the EDT, but I haven't found documentation about this.
Edited by: jduprez on Jul 20, 2009 2:37 PM
so no, technically, I can't prove repaint(long, int,int,int,int) is thread-safe.
But a well-behaved application that updates its widgets on the EDT shouldn't worry (that is, repaint(...) calls can still be invoked outside of the EDT).
Edited by: jduprez on Jul 21, 2009 7:04 PM - typos -
Bootcamp windows 8 will not enter safe mode
My bootcamp windows 8 will not enter safe mode. I've tried press Fn + F8 multiple times.
http://windows.microsoft.com/en-US/windows-8/windows-startup-settings-including- safe-mode
-
There used to be a small padlock feature in the lower right hand corner. When I upgraded to the latest Firefox, it disappeared. Now I do not feel safe using my credit card. What happened to it? How can I get the feature back so I can know it is a secure site?
In Firefox 4 you no longer have the Status bar that showed the padlock in previous Firefox versions.<br />
The padlock only shows that there is a secure connection and doesn't guarantee that you are connected to the right server.<br />
So you might still be connected to the wrong server if you make a typo in the URL and someone has claimed that mistyped URL.<br />
The functionality of the padlock has been replaced by the [[Site Identity Button]] on the left end of the location bar.<br />
See also:
* http://www.dria.org/wordpress/archives/2008/05/06/635/
You can click the [[Site Identity Button]] on the left end of the location bar to see the padlock if there is a secure connection.
A click on the "More Information" button will show more details about the connection.
The background color of the "Site Identity Button" on the left end of the location bar will change color (blue or green) and show the domain in case of a secure HTTPS connection.
* Hover the [[Site Identity Button]] then to see "Verified by xxxx"
* Click the "Site Identity Button" on the left end of the location bar to see the padlock
* Click the "More Information" button in that pop-up to see additional information about the connection.
You can use this extension to get a padlock on the location bar.
*Padlock: https://addons.mozilla.org/firefox/addon/padlock-icon/ -
I have macbook without a firewire port, I have usb 2.0 port, now my os is not working I can not get through apple logo loading , I can not enter safe mode, I can only enter one user mode, how can I backup my data, I have very important data in my hdd
Here is what worked for me:
My usb hub, being usb2, was too fast. I moved the wire to a usb port directory on my pc. That is a usb1 port which is slow enough to run your snyc.
Maybe you are looking for
-
Help send file with axis webservice to another langague client
Please anyone know if i can send any file from any client (in any language) to my webservice (axis)?// sorry my english.. tks
-
Internet constantly disconnects. Need expert advice
Hello and thank you for reading this. The problem I have been having with my home internet for the past year is that it is constantly losing connection. Sometimes it's as often as once an hour, sometimes only a few times a day. I have logged onto rou
-
Can't get search results on External Hard Drive..??
Hi guy's, I recently bought a brand new external Acomdata 160 gig Firewire hard drive in order to back up all my important stuff off of my G4 1ghz iMac due to Kernel Panics and a couple of other frustrating issues. I loaded the external hard drive, d
-
The Top of this screen reads "Ask a Question | Firefox help "File Edit View History Bookmarks Tools Help" "Ask a Question | Firefox Help |+| ( the "+" is in a grey square) When I click on the |+| sign in its grey square, it Opens up a New Tab, good,
-
I need to get a running report of how much load each process is putting on the CPU. Is there a way to get a report that will show four to eight hours giving each process and how much CPU it is using?