We recently updated the updated Java Updated 21 7 25 and swing Utijkaisiiant Dispecthred (a) RMI thread Is called because AppContext.getAppContext () is returning null.
java.awt.EventQueue.isDispatchThread on java.lang.NullPointerException javax.swing.SwingUtilities.isEventDispatchThread at sun.awt.SunToolkit.getSystemEventQueueImplPP on sun.awt.SunToolkit.getSystemEventQueueImplPP (Unknown Source) (unknown source) (unknown source on JavakawtkToolkitkgetEventQueue (unknown source) at SunkawtkSunToolkitkgetSystemEventQueueImpl (unknown source)) (unknown source ...) ... sun.reflect.NativeMethodAccessorImpl. on Invoke0 SunkreflectkNativeMethodAccessorImplkinvoke (Native method) (unknown source) (unknown source sun.reflect.DelegatingMethodAccessorImpl.invoke) on java.lang. Reflect on Sun.rmi.server.UnicastServerRef.dispatch (Un). Method. Known source) sun.rmi on java.security.AccessController.doPrivileged (Native Method sun.rmi.transport.Transport $ 1.run (sun.rmi.transport.Transport $ 1.run (Unknown Source Unknown Source) )) In. On transport.Transport.serviceCall sun.rmi.transport on sun.rmi.transport.tcp.TCPTransport $ ConnectionHandler.run0 (sun.rmi.transport.tcp.TCPTransport.handleMessages (Unknown Source) at an undisclosed source) (unknown source). JavakutilkconcurrentkThreadPoolExecutorkrunWorker (Unknown Source java.util.concurrent.ThreadPoolExecutor $ Worker.run (Unknown Source) at JavaklangkThreadkrun) on tcp.TCPTransport $ ConnectionHandler.run (Unknown Source) ( Unknown source)
This error is only available from the beginning of the web, when we run our application through an IDE, then it is fine.
Is anyone else running this? Any idea about what changed the latest update to AppContext
It seems that there are some related issues with AppContext after the update:
I had a problem running Java as a web browser like Java. I have found another solution, you have to prepare the invoclator processor along with the queue of the runways. This thread should be extended and run-nuns should be selected and executed in the run method:
Public class InvokeLaterProcessor Thread {Private Blockquiz & lt; Runnable & gt; Queue = new arrawlocking quatule & lt; Runnabel & gt; (1); Public Invitation Publisher Processor (string name) {super (name); } Public Zero InvokeLater (runnable runner) {try {queue.put (runnable); } Grip (blocked predefined) {log. Warn ("invokeLater interrupted"); }} Public Zero Run (Runner) Runnab runner = empty; Do {try {runnable = queue.take ()); SwingUtilities.invokeLater (runnable); } Grip (interrupted predecessor) {runnable = null; }} While (runnable = null); }}
Whatever you have to do is made more stable in some class which is built in the main thread:
stable {invokeLaterProcessor = New InvokeLaterProcessor ("MyInvokeLater"); InvokeLaterProcessor.start (); }
and runnables process by this code:
invokeLaterProcessor.invokeLater (runner);
You do not need ownership
sun.awt.SunToolkit.invokeLaterOnAppContext (evtContext, rn)
No comments:
Post a Comment