Please help: RMI and Swing/AWT issue
Hi guys, I've been having a lot of trouble trying to get a GUI application to work with RMI. I'd appreciate any help. Here's the story:
I wrote a Java application and its GUI using Netbeans. In a nutshell, the application is about performing searches. I am now at the point where I need exterior programs to use my application's search capabilities, thus needing RMI. Such exterior programs are to call methods currently implemented in my application.
I implemented RMI, and got the client --> server communication working. However, the GUI just breaks. It starts outputting exceptions, gets delayed, doesn't update properly, some parts of it stop working.... basically hysterical behavior.
Now take a look at this line within my server class:
Naming.rebind("SearchProgram", mySearchProgram);
If I take it out, RMI obviously does not work... but the application and its GUI work flawlessly. If I put it in, the RMI calls work, but the GUI's above symptoms occur again. Among the symptoms are null pointer exceptions which all look similar, are related to "AWT-EventQueue-0", and keep ocurring. Here's just snippet of the errors outputted:
Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException
at javax.swing.plaf.metal.MetalScrollBarUI.getPreferredSize(MetalScrollBarUI.java:102)
at javax.swing.JComponent.getPreferredSize(JComponent.java:1615)
at javax.swing.JScrollBar.getMinimumSize(JScrollBar.java:704)
at javax.swing.ScrollPaneLayout.minimumLayoutSize(ScrollPaneLayout.java:624)
at java.awt.Container.minimumSize(Container.java:1598)
at java.awt.Container.getMinimumSize(Container.java:1583)
at javax.swing.JComponent.getMinimumSize(JComponent.java:1697)
at java.awt.BorderLayout.minimumLayoutSize(BorderLayout.java:634)
at java.awt.Container.minimumSize(Container.java:1598)
at java.awt.Container.getMinimumSize(Container.java:1583)
at javax.swing.JComponent.getMinimumSize(JComponent.java:1697)
at java.awt.BorderLayout.minimumLayoutSize(BorderLayout.java:634)
at java.awt.Container.minimumSize(Container.java:1598)
at java.awt.Container.getMinimumSize(Container.java:1583)
at javax.swing.JComponent.getMinimumSize(JComponent.java:1697)
at javax.swing.BoxLayout.checkRequests(BoxLayout.java:433)
at javax.swing.BoxLayout.layoutContainer(BoxLayout.java:375)
at java.awt.Container.layout(Container.java:1401)
at java.awt.Container.doLayout(Container.java:1390)
at java.awt.Container.validateTree(Container.java:1473)
at java.awt.Container.validateTree(Container.java:1480)
at java.awt.Container.validateTree(Container.java:1480)
at java.awt.Container.validateTree(Container.java:1480)
at java.awt.Container.validateTree(Container.java:1480)
at java.awt.Container.validate(Container.java:1448)
at javax.swing.RepaintManager.validateInvalidComponents(RepaintManager.java:379)
at javax.swing.SystemEventQueueUtilities$ComponentWorkRequest.run(SystemEventQueueUtilities.java:113)
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:461)
at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:242)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:163)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:157)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:149)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:110)
Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException
at javax.swing.plaf.basic.BasicMenuItemUI.getPreferredMenuItemSize(BasicMenuItemUI.java:400)
at javax.swing.plaf.basic.BasicMenuItemUI.getPreferredSize(BasicMenuItemUI.java:310)
at javax.swing.JComponent.getPreferredSize(JComponent.java:1615)
at javax.swing.BoxLayout.checkRequests(BoxLayout.java:434)
at javax.swing.BoxLayout.preferredLayoutSize(BoxLayout.java:251)
at javax.swing.plaf.basic.DefaultMenuLayout.preferredLayoutSize(DefaultMenuLayout.java:38)
at java.awt.Container.preferredSize(Container.java:1558)
at java.awt.Container.getPreferredSize(Container.java:1543)
at javax.swing.JComponent.getPreferredSize(JComponent.java:1617)
at javax.swing.JRootPane$RootLayout.layoutContainer(JRootPane.java:910)
at java.awt.Container.layout(Container.java:1401)
at java.awt.Container.doLayout(Container.java:1390)
at java.awt.Container.validateTree(Container.java:1473)
at java.awt.Container.validate(Container.java:1448)
at javax.swing.RepaintManager.validateInvalidComponents(RepaintManager.java:379)
at javax.swing.SystemEventQueueUtilities$ComponentWorkRequest.run(SystemEventQueueUtilities.java:113)
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:461)
at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:242)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:163)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:157)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:149)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:110)
There are no complaints about anything within my code, it's all GUI related whenever I make a bind() or rebind() call.
Again, any help here would be great... cause this one's just beating me.
Thanks!
Maybe you want to change that worker thread to
not do RMI but anything else (dummy data) to see if it really is RMI, I doubt it, I think you are updating some structures that have to do with swing GUI and hence you will hang.
Just check this out.
Similar Messages
-
My iPod Nano 7th Generation couldn't be detected by iTunes when I plugged in. I tried resolving the issue by uninstalling the iTunes and then install it back again but yet still the same problem exist. Can you please help me to solve this issue? I have already updated to the latest version of iTunes on my Windows 8 and I cannot synchronize my iPod for the time being. Please do help me to solve this problem. Thank You.
uninstall all iTunes,5 programes,this worked for me after reinstall them
-
Can you please help me how resolved this issue.
Hi Experts
I am trying to connect LDAP by R/3 system. R/3 system connected to LDAP but when I am trying to find and pull the fileds in the "Find in the Directolry" option I am getting below error.
LDAPRC 010 another server is referenced.
Can you please help me how resolved this issue.
With Regards,
Trinadh BokkaYou may be able to solve by using
Note 1151329 - Depth of LDAP search is only one level below the base entry
Markus -
Please help me on URL mapping issue
Hi,
I am new to Oracle apps. So please help me to solve this issue. I have created new OC4J instance and changed my URL mapping to /MYApp but when i access application trough browser http://myapp.com/MYApp/../../help I am getting 404 error. If I change the URL http://myapp.com/forms/../../help it works fine. What am i doing wrong?
Please help me to get raid of this issue.
Thanks in advance
KarthikHave you attempted to backup and then clear the AIF_EBS_GL_CCID_STG table and then re-ran your data load rule with the "Full Refresh" option?
If not, you will want to do this and then check the account type in the table after the data load rule run.
Refer to the following KM Document for information on clearing the table:
ERPI Code Combinations are Out of Sync With EBS (Doc ID 1473119.1) -
Hi,
My ipad air getting close all apps automatically within seconds while connecting wifi. This issue is started after the updation of the iSO 8, Please help me to rectify this issue.
Expecting some quick solution in this regard,
Thanks
Prabhu(A) Try reset iPad
Hold down the Sleep/Wake button and the Home button at the same time for at least ten seconds, until the Apple logo appears
Note: Data will not be affected.
(B) Try reset all settings
Settings>General>Reset>Reset All Settings
Note: Data will not be affected but settings for Wi-Fi, FaceTime, Message, Home Sharing will be reset -
Help....I am trying to set up iClould on my pc....the set up was complete....when I try to sign in to set up it says the Apple ID is valid but is not an iCloud account. Please help me and tell me what I am doing wrong. Thx
Hi DesCoop,
You must initiallly activate iCloud from an IOS device or a Mac. You cannot inititally activated from a PC.
Sorry.
GB -
I just want to ask if there is any way i can fix my ipod touch 4G from watar damage and i dont think that a larg amount of water have entered and the ipod isnt working at all and i tried charging it but it didnt work so please help me, and thankyou.
Probably dead if you have tried to charge it.
You should never try to charge or turn on a wet electronic device.
You should let it dry for a week or so, then try. -
I forget answer to my qustion with rescue email adrees please help me and send the answer to my main mail. Thank you very much
We are fellow users here on these forums, you're not talking to iTunes Support.
If you don't have access to your rescue email account, or you don't have one on your iTunes account, then you will need to contact iTunes Support / Apple to get the questions reset.
Contacting Apple about account security : http://support.apple.com/kb/HT5699
When they've been reset you can then use the steps half-way down this page to add/change a rescue email address for potential future use : http://support.apple.com/kb/HT5312 -
My macbook air 13inch got shutdown 3 times by itself. I tried installing SMC package as suggested but my computer is telling the update is not required. Could you please help me on fixing this issue. Thanks.
What version of OS X are you using? Exactly which MBA model do you have?
-
my iphone4 camera shutter not opening please help me to resolve this issue , i tried a restore it still exist, my iphone4 camera shutter not opening please help me to resolve this issue , i tried a restore it still exist ,please help me
uninstall all iTunes,5 programes,this worked for me after reinstall them
-
After I update IOS6 for my iphone 3gs, while i turn on vibrate (Using side button) is not supporting. Automaticlaly turn on back to ringing mode. So please help me to resolve this issue.
No one facing this issue in 3GS? please help me.
-
I lost my iPhone 3 days ago.. it wasn't connet to internet and I don't know how find it without the connection.. please help me and give me some advices!!
Change your passwords.
-
I need to by apps but it keeps asking for my security questions ;/ but forgot the answers to my security questions and the security/rescue email too (i dont have USA number to call please help me and send my rest to my email
You need to ask Apple to reset your security questions. To do this, click here and pick a method; if that page doesn't list one for your country or you're unable to call, fill out and submit this form.
(115668) -
Hi, my name is Mira Ćenan. I from Zagreb,Croatia.
My ICloude is locked and canot use my Phone. Please help me and answer me.
Thank you!
MiraOnly the person who initiated the Activation Lock can remove it. Contact the seller/
previous owner for assistance. There is no workaround for Activation Lock. -
I have a 8GB Ipod Touch and i know its not a lot, but in the beginning it was working fine. For some time now it wont let me excede even 1GB of memory. i have no games, no apps, not many contacts, hardly anything! only 249 mb of photos and camera and 23l mb of Music. i have backed it up and restarted it and everything and i am getting annoyed! please help me!! i cant live without my ipod!!! This is urgent!
P.S: i have 2 apps on my ipod that i would not like to loose! IF theres anyway to save them in the process of fixing my ipod that will be great!
Thank you!An "other" that large usually indicates that the "other" includes corrupted files. Usually restoring from backup eliminated the corrupted files. However, sometimes restoring to factory settings/new iPod is required.
To restore from backup see:
iOS: How to back up
To restore to factory settings/new iPod see:
iTunes: Backing up, updating, and restoring iOS software
Maybe you are looking for
-
Issue with Duplicate Results and Summary Fields
My report is based on an Access Database. For the purposes of this current issue, there is the Master Table called u201CCnu201D and then a related u201CTable Au201D which includes multiple records related to the Master and also a related u201CTable B
-
HI ALL, I have a client.. She requested to configure a route for two new customer.. I configured the new route: R1, it has 22 calendar days transit time, and 3 working days transportation Lead time. Then she create an Export Order on 12/01. Indicatin
-
DSC for compact fieldpoint​(cFP)
which IO server type should be used for building DSC application for compact fieldpoint target? when i use my computer as target then i get various options for IO server type like custom VI,opc client,epics,data set marker,modbus.But when i choose co
-
Problem with orders identified - REASON FOR NO EMAIL
I think. It seems after reading on other boards about addresses not be taken the problem lies with the address validation system with the shipper. When I order it prepopulated the address field. the street name was missing the last few letters so I a
-
Human Task - Custom buttons outcomes doesn't visible
Hello, I made a simple human task with custom outcomes (Aprovar and Reprovar) in portuguese - brazil. It's equals Approve and Reprove. But my 2 buttons doesn't visible. <af:commandToolbarButton actionListener="#{invokeActionBean.setOperation}" text="