This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 9826 - [Win2K NB Dev 132] Installing new beans requires restart NB
Summary: [Win2K NB Dev 132] Installing new beans requires restart NB
Status: CLOSED FIXED
Alias: None
Product: guibuilder
Classification: Unclassified
Component: Code (show other bugs)
Version: 3.x
Hardware: PC Windows ME/2000
: P3 blocker (vote)
Assignee: _ ttran
URL:
Keywords:
Depends on: 9900
Blocks:
  Show dependency tree
 
Reported: 2001-02-24 19:24 UTC by javaiware
Modified: 2003-06-30 18:28 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
IDE.log created as described in my latest comments (1.29 KB, application/octet-stream)
2001-07-21 01:02 UTC, javaiware
Details
One of the 2 jars I installed (820.83 KB, application/octet-stream)
2001-07-21 01:02 UTC, javaiware
Details
The other jar that I installed (190.34 KB, application/octet-stream)
2001-07-21 01:02 UTC, javaiware
Details
IDE.log created as described in my bug comments, that is marked by (I) (91.10 KB, text/plain)
2001-07-21 01:02 UTC, javaiware
Details

Note You need to log in before you can comment on or make changes to this bug.
Description javaiware 2001-02-24 19:24:12 UTC
Hi,

When I install new beans, they do not show up on the component pallette until I 
restart NB, after that they seem to be working fine all the time.

Iwan
Comment 1 Petr Suchomel 2001-02-26 09:33:45 UTC
Beans module does not used for adding and showing beans in component pallete. 
It is used for creating beans properties, methods, BeanInfo.
Comment 2 Jan Lahoda 2001-02-26 12:05:12 UTC
Product is form and assign to is for editor. Changing assigned to to form.
Comment 3 Tomas Pavek 2001-02-27 09:57:29 UTC
I tried it, but it works for me...
Iwan, could you give us more details? Thanks. For example:
When the installed beans are not shown on the palette, are they visible in 
Tools|Options->Component Palette?
Did you install the beans from a JAR, or from mounted filesystems (as class; 
using Tools->Add to Component Palette)?
Does this happen always no matter of clean build is used (no previous user 
changes in palette vs. adding e.g. to category created by user)?
Do other changes (like deleting beans) need restart too?
Comment 4 javaiware 2001-02-28 18:29:30 UTC
Created attachment 696 [details]
IDE.log created as described in my latest comments
Comment 5 javaiware 2001-02-28 18:43:19 UTC
I deleted my NB directories (install and user) and reinstalled build 132 again. 
Here're my findings:

Q: When the installed beans are not shown on the palette, are they visible in 
Tools|Options->Component Palette?
A: Only the beans that also show on the palette are visible. When I installed 
the beans I saw the following happening: First a set of icons was shown, but 
they were all '?' icons. Then the real icons of this set was shown, then the 
rest of the icons were shown, first only the '?' then the real icons. And 
because the jar-file has more beans that could be displayed, the button with 
the arrow on the right of the palette was shown, then all but the first set of 
icons (I mentioned earlier) are gone and that's it. This all happened after I 
selected all beans in the jar and hit OK.

Q: Did you install the beans from a JAR, or from mounted filesystems (as class; 
using Tools->Add to Component Palette)?
A: From a jar thru Tools|Install New Beans

Q: Does this happen always no matter of clean build is used (no previous user 
changes in palette vs. adding e.g. to category created by user)?
A: Now I used a clean build, totally clean, before I had only the install 
directly deleted and then installed 132, now I also had the user-dir deleted 
and didn't import any projects, so it would be a clean install.

Q: Do other changes (like deleting beans) need restart too?
A: Well here's something. I went thru the menu to get to Tools|Options-
>Component Palette? Selected a newly installed bean and deleted it. The bean 
was gone, but all beans that were not visible at first all of a sudden appeared.

I hope this helps. I do have the IDE.LOG for you and I will also attach the jar 
files I installed (2 in total, downloaded from www.alphaworks.ibm.com).

Iwan
Comment 6 javaiware 2001-02-28 18:50:35 UTC
Created attachment 697 [details]
One of the 2 jars I installed
Comment 7 javaiware 2001-02-28 18:52:05 UTC
Created attachment 698 [details]
The other jar that I installed
Comment 8 Jan Chalupa 2001-03-12 10:40:08 UTC
Version: 'Dev' -> 3.2
Comment 9 Jaroslav Tulach 2001-03-27 10:12:28 UTC
Ok, I have fixed the problem in 9900, but you should still try to install all
beans in FileSystem.runAtomic, it will be faster.
Comment 10 _ ttran 2001-03-27 17:55:00 UTC
Bug #9900 which this one depends on has been fixed, so I mark this as FIXED. 
Please verify
Comment 11 javaiware 2001-03-28 18:26:08 UTC
I just checked in NB 3.2.13 and it still doesn't work.
When I install hte new jar with multiple beans (I used the same jars as I 
attached earlier) I only get some beans on display in the component palette. 
Then I go into the settings and check there, and the same beans I see on the 
component palette appear.
Then I close NB and start it up again. Now the beans don't even show up, but 
all beans are shown in the settings, but with that funny '?' icon instead of 
the correct icon.
I restarted NB again and have the same results.
I tried with NB 3.2.14 as well, but that didn't behave any different from the 
NB 3.2.13.
If you need me to test with another build or need more info, please let me know.
Comment 12 javaiware 2001-03-28 19:04:41 UTC
Some additional informatoin I found [Win2K NB 3.2.14]:
- When I install a jar with beans (1 of the attached), they do not show up on 
the palette, but they are in the settings, with the right icons, only after 
restart of NB the icons are gone and I see the '?' icons.
- The file <USER_DIR>/beans/installed.properties does not get updated, it only 
contains the entry for 'TimerBean.jar=true' in it.
- The files <USER_DIR>/beans/installed.properties and 
<USER_DIR>/beans/libs.properties are not updated when I delete beans in the 
settings.
- I have the beans installed in a directory that is not in my classpath, nor 
known to NB other than that <USER_DIR>/beans/libs.properties contains the path 
to it for each jar file with beans I installed
Comment 13 _ ttran 2001-04-02 16:25:19 UTC
Iwan, you're correct.  It does not work.  On my machine it's even worse: the
beans do not show up even after restart.  This is a bug in core/openide.  I'll
reopen #9900.

The files under <user_dir>/beans are not used.  This is correct, no need to
worry about them.
Comment 14 javaiware 2001-04-02 16:40:58 UTC
When the files in <user-dir>/beans are not used, than that dir shouldn't be 
there, IMHO. It is confusing.

Iwan
Comment 15 _ ttran 2001-04-02 17:32:30 UTC
we'll change the way beans are installed in 3.3.  The way it works now is a
little bit ugly (the code I mean) and thus fragile.  Why do you think it's
confusing?  The user need not to look inside the directory 
Comment 16 javaiware 2001-04-02 19:30:29 UTC
It's confusing because installing beans suggests a user-specific setting, 
that's what I would like it to be. Also, I've been looking at the wrong place 
and probably gave some wrong information while reporting a bug. But if 3.3 re-
does the beans handling, that should be no problem.
Comment 17 _ ttran 2001-04-04 10:20:48 UTC
should be fixed now, please verify.
Comment 18 javaiware 2001-04-04 15:58:28 UTC
Still the same result, but now when installing the jar none of the beans are 
shown in the tab but they are , with the correct icons in the settings. After 
restart of NB, the icons in settings are gone as well.
I tried it with the jars in my classpath as well, but that didn't help.

Iwan
Comment 19 Tomas Pavek 2001-04-05 08:44:38 UTC
Iwan, could you please try 3.2 beta build 21? I've just tried several times and 
it works well for me - all items are added (after a while ;), but at once), 
both to palette and settings, and they're there also after restart. I'd say no 
problems now...
Comment 20 javaiware 2001-04-05 15:26:15 UTC
It seemed to work, but after installing both jars in one go, I  had all beans 
available (I have created a tab on the component palette 
called 'Authentication' on which I install the authentication.jar beans, the 
other beans I install on 'Beans'. I could use all beans as well, or at least 
put them on a form.
After a restart, I only had 1 of the 4 authentication beans' icons, the other 3 
where the '?' icon. When I tried to use them, I got an exception saying it 
couldn't instantiate the bean. I restarted again, but same result.
Then I tried to delete those 3 beans and re-install them. I had them on the 
palette again and could use them, but after a restart (I), all new beans where 
gone, and in settings I had the '?' again. 
Now there is a difference in installation: The first time I installed while a 
new 3.2.20 project was open, the second installation was in a project that I 
had since 3.2.1 and keep on using. I believe the beans are not installed in the 
user-dir, so it shouldn't matter.
I tried to install the beans after opening the 3.2.20 project and the icons 
show up in settings, but not on the palette. Well this is true for the 
authentication.jar, the other jar becomes visible right away.
I have marked a restart with (I) in this text. The IDE.LOG I attach is the one 
generated after the restart marked with (I).

Iwan
Comment 21 javaiware 2001-04-05 15:28:28 UTC
Created attachment 1014 [details]
IDE.log created as described in my bug comments, that is marked by (I)
Comment 22 Tomas Pavek 2001-04-06 18:28:42 UTC
Iwan, it seems that the problem is not in form editor. It looks like there's 
something with projects - importing from earlier builds, mixing them, etc. The 
exceptions in attachment show that classes of beans were not found - it means 
only that the jar filesystem mounted by form editor was not restored after 
restart. You can look to Project Settings > Filesystems if the jar is there.
I'm not sure if we can fully reproduce and analyze what's happening with 
project on your computer ;-).
Could you try (again, I know, but probably at last ;) install beans on clean 
new build with no imported project?

As for the beans in options but not on palette - this sometimes happens if 
there is some invalid bean (class not found) in the category. Such category 
doesn't reflect any cahnges (no idea why). Deleting invalid beans and 
restarting helps. Is this the case?

BTW I'm really looking forward to rewriting beans handling completely...
Comment 23 javaiware 2001-04-07 07:44:56 UTC
Using NB 3.2.23 now and the beans in the uicontrolsswing.jar are showing up 
nicely and I can all use them, but again only 1 of the 4 beans from 
authentication.jar is shown after a restart of NB. After installation they all 
show and all can be used, but after the restart of NB, only 1 is shown and can 
be used, the rest are '?' icons.

As you suggested, I tried a full 'virgin' install, no old user-dir and no 
imported projects, just the simple default project, but the same 
results...something funny is going on...

I'm looking forward to your refactoring of the beans-installation as well :) If 
I can help, let me know, I'm willing to do some extensive testing.

Iwan
Comment 24 _ ttran 2001-04-09 10:05:16 UTC
Iwan, there's something wrong with your beans in authentication.jar (the second
jar you attached to the bug report).  Class
com.ibm.authentication.LoginInfoSaver refers another class
javax.security.auth.login.AppConfigurationEntry.LoginModuleControlFlag, which
does not exists in my version of JDK (1.3.1 beta on Linux).  I vaguely recalls
there is something called javax.security package, but it certainly does not
exist in the standard JDK.  I conclude that either your beans are wrong or this
is a totally different bug in the IDE.  In the latter case please investigate
and file a new bug.  (It may be worth testing the beans with the reference BeanBox).

Closing the bug as FIXED
Comment 25 Marian Mirilovic 2001-04-09 17:15:00 UTC
verified [nb_r32](23), [pilsen](010407)
Comment 26 javaiware 2001-04-14 21:47:37 UTC
Build 3.2.29 (NB 3.2 RC2) has the old problem again with the same bean-jars.

Iwan
Comment 27 javaiware 2001-04-14 23:54:14 UTC
I just found out that cpoying the jars into <NETBEANS>/Beans makes everything 
accessible and it works...I didn't check the FAQ and docs, but I think you 
should make this VERY clear, considering the amount of time we spend on this 
matter <g>
So I changed it back to FIXED.

Iwan
Comment 28 Marian Mirilovic 2001-04-18 16:22:06 UTC
verified in [nb_r32](rc3_31), [nb_dev](169), [pilsen](010417_2)
Comment 29 Jan Chalupa 2001-05-05 22:24:29 UTC
Target milestone -> 3.2
Comment 30 Quality Engineering 2003-06-30 18:28:36 UTC
Resolved for 3.3.x or earlier, no new info since then -> closing.