现在大家使用bas咯
jspchina.com里面也有

解决方案 »

  1.   

    一.开发环境配置
    1.工欲善其事,必先利其器。确认你已经安装了jb4或jb5(开发工具),确认你已经安装了ias4.1和weblogic5.1(假定装在了C盘)。在jb的Tools\Enterprise setup菜单下选中Application Server属性页,将ias4.1路经设为C:\Inprise\AppServer;weblogic的路径设为C:\weblogic。重起jb。2.将你的系统TEMP和TMP环境变量设为没有空格的路径。方法鼠标右键单击桌面上“我的电脑”图标,选中“属性”菜单项,选“高级”,修改其中环境变量中的TEMP和TMP,比如改为“C:\temp”。因为jb在编译EJB程序时会把临时生成的类文件放在系统临时路径下,却因无法识别有空格的路径而无法再将放入的类文件取出,导致编译错误(哈哈,真弱智)。3.在系统autoexe.bat文件中加入下列代码(假设你的jdk装在了C盘):
    set PATH=c:\jdk1.3\bin
    set CLASSPATH=c:\jdk1.3\lib\tools.jar
    set JAVA_HOME=c:\jdk1.3
    如果不设,生成的EJB程序在执行时会出现莫名其妙的错误。(血的教训啊)。4.拷贝\\zlliu\share\lib下的两个文件到你的weblogic\lib下;用\\zlliu\share\lisence下的两个文件覆盖你weblogic\lisence下的两个文件;用\\zlliu\share下的startWeblogic文将覆盖你的weblogic下的同名文件,如果你的weblogic不是装在C盘跟目录下,用ultraEdit打开该文件,修改第78行中的路径信息,将其中的“c:\weblogic”字段改为你的weblogic安装路径。(至于为什么要设这些,大家心照不宣啦)重起你的机器,让我们开始EJB的开发。 
      

  2.   


    历历给的是在win98下安装配置wls5.1的问题,如果是6.0就不一样了。下面还有一份资料让你在jb4下配置wls6.0:如何在Jbuilder4结合WebLogic 6.0  
     
    The basic steps are as follows: Create a subdirectory under $WL_HOME and touch a file to satisfy an internal JBuilder 4 check for the WebLogic 5.1 AppServer. Enable the JBuilder 4 Enterprise features. Define/Add a new Application Server to JBuilder known list of Appservers. Create your JBuilder project and, using the Object Gallery, select the EJB you wish to create and set that projects Enterprise property to the newly defined/added Application from JBuilder's known list of Appservers. NOTE: In these instructions you will see parameters like WL_HOME. These parameters refer to various WebLogic path values, "WL_HOME" referring to the WebLogic home directory. You will need to fill in the values for these parameters as appropriate. NOTE: DO NOT USE ENVIRONMENT VARIABLES WHEN FILLING IN JBUILDER SETUP DIALOG BOXES. Complete Steps: When JBuilder 4 looks for the WebLogic server it assumes version 5.1 will be found and uses the presence of a certain file to insure itself that everything is where it should be. To satisfy that check when using WebLogic 6.0 you need to create that file in the location that JBuilder expects to find it. From an MKS shell change directory to the $WL_HOME and create a subdirectory tree called classes/weblogic. Next create a file in that sub-subdirectory called Server.class, for example: cd d:/bea/weblogic mkdir -p classes/weblogic touch classes/weblogic/Server.class To enable the JBuilder 4 Enterprise features you need to setup the Inprise and Weblogic Application Servers plus VisiBroker: Install JBuilder. Install Inprise Application Server (IAS) 4.1. In some versions of JBuilder VisiBroker 4.0 is included on your JBuilder CD. Do NOT install this version of VisiBroker. IAS 4.1 includes a different version of VisiBroker. After the installation of IAS, you need to setup the JBuilder VisiBroker Configuration: Run JBuilder and go to the Tools | Enterprise Setup dialog and select the CORBA tab. Select VisiBroker from the list of CORBA Configurations and click the Edit button. For the path to the ORB tools, enter the location of the IAS 4.1 tools e.g. D:/Inprise/appserver/bin Create a Required Library by pressing the "Set..." button next to the "Select or create a library..." combobox. Enter a name for this Required Library such as "IAS 4.1". Click Add button and find your IAS 4.1 installation directory. Goto the /lib directory and select all the jars. Choosing all jars will allow you to develop and run/debug EJBs and CORBA applications. Click OK to save the Required Library. Click OK to save the VisiBroker Configuration. While still in the Tools | Enterprise Setup dialog go to the APPLICATION SERVER tab. Select IAS and fill in the text box for IAS installation directory, e.g. D:/Inprise/AppServer Select WebLogic 5.1 and fill in the text box for the Weblogic installation directory, e.g. D:/bea/wlserver6.0 Click OK to save your Application Server configurations. When JBuilder associates the WebLogic AppServer with your EJB project it uses the AppServer definition to derive path and setup information with the expectation of finding Weblogic 5.1. You can take advantage of this expectation and define/add a new WebLogic 6.0 AppServer to the list of JBuilder 4 AppServers. MUCH OF THIS INFORMATION MUST BE ENTERED EXACTLY AS DESCRIBED BELOW FOR THIS TO WORK. In the file appserver.properties which is found under the user's .jbuilder4 directory add an entry to the front of the appserver.names property called "wlserver6.0", e.g appserver.names=wlserver6.0;Inprise Application Server 4.1;EJB 1.1;WebLogic Application Server 5.1 Go the Project | Project Properties dialog and select the ENTERPRISE tab. Click on the "Application Server" elipsis button on the left. There will be a blank entry in the list of AppServers. Select the blank entry and click the "Edit" button. An Application Server Properties dialog should appear. Enter the information exactly as listed below, with the only substitute being your values for the paths where you have your WebLogic installed : Name: wlserver6.0 Version: 6.0 Main Class: weblogic.Server VM parameters: -classic -ms64m -mx64m -Dweblogic.system.home=d:/bea/wlserver6.0 -Dbea.home=d:/bea -Djava.security.manager -Djava.security.policy==d:/bea/wlserver6.0/lib/weblogic.policy -Dweblogic.Domain=mydomain -Dweblogic.Name=myserver  Server parameter: (leave blank) Next enter the path that represents your BEA_HOME (not WL_HOME) directory, e.g. D:/bea Lastly, with the CLASS tab selected in the bottom of the dialog, ADD the path to both weblogic_sp.jar and weblogic.jar, which are in the WebLogic Server 6.0 /lib directory. Final Steps: Create a JBuilder project the same way you normally would. Select Project | Project Properties and click on the Enterprise tab. Click on the Application Server elipsis button and choose the WebLogic AppServer named wlserver6.0 (the WebLogic Appserver you defined/added previously). Click OK to save your AppServer selection. While still in the Project Properties dialog, select the PATHS tab and set the Working directory to your BEA_HOME path, e.g. D:/bea While still in the Project Properties dialog, select the RUN tab and then the EJB tab. De-select the 2 check boxes at the bottom of the dialog. Also make sure that the VM parameters are the same as the ones you specified for your WebLogic Server above. Select File | New to bring up the Object Gallery dialog. Select the Enterprise tab, select the Enterprise Javabean icon and click ok. Choose a name for your EJB group in the EJB Wizard step 1-of-3. Note: select the HELP button here if you want some more explamation on EJB groups and deployment descriptors from the JBuilder 4 online Help. Fill in the EJB Wizard step 2-of-3 dialog with names and types. If you just want to test your setup use a stateless session bean. Click Next and fill in the EJB wizard step 3-of-3 with your interface names. If you just want to test your setup simply accept the defaults given and click Finish. Build your project. If your setup is correct your project should build correctly. DISCLAIMER: these suggestions are not supported by Borland, use them at your own risk. 
      

  3.   

    为什么不买一张jbuilder5的盘呢??
      

  4.   

    Weblogic6.0与 Jbuilder5的集成 一、 安装和配置 
    先安装Jbuilder5 Enterprise,然后安装Jbuilder5 Person, license key 用Enterprise的。 
    或其他方法,只要确保Jbuilder5 Enterprise,能运行。 
    安装完Jbuilder5,BAS4.5和weblolgic6.0后,就可以开始配置了。 
    (1) 系统环境变量的修改: 
    把系统环境变量TMP、TEMP改为不带有空格的目录;     
    在JB5里菜单    Project ??> Default Project Properties ??>Paths 中把所有带空格的目录改为不带空格的目录;为什么要这样设置呢?因为整合后的 weblogic 和JB5在开发过程中JB5会调用 weblogic 的包来制作EJB,而weblogic对那些有空格的不能很好地识别,工作时会出错,即是说weblogic要接触到的目录,目录名最好不是中文名、带空格。 在使用JB5编辑时会发现光标与实际位置不对齐的问题, 其实只需要在Tools ??>Editor Opntion ??>Color中 把 Reserved Word 设置成不使用粗体和斜体就可以了。 
    (2) jbuilder5 的配置: 
    A、 Tools ??>Configure Libraries 下确定有WebLogic6.0包,其中class中应该加入如下class和路径: 
    C:\bea\wlserver6.0\lib\ cr_wls60f.jar(是Weblogic6.0的crack包) 
    C:\bea\wlserver6.0\lib\weblogic_sp.jar 
    C:\bea\wlserver6.0\lib\weblogic.jar B、Tools Menu ??>Enterprise Setup ??>CORBA     
    ?新增一个weblogic的项,   在Path for ORB tools下,加入Weblogic的目录   
    ?  在Library for projects下,加入 Weblogic6.0 的 库,具体方法是:点“..”,然后选择 Weblogic6.0包;     
    ?在 compiler command 填上 idlj.exe     
    ? 在Command option for output directory 填上一个目录路径,但是要注意的是,不能是中文、带空格。   
      
    C、Tools Menu ??>Enterprise Setup ??>Application Server ??>BAS4.5。1 
    填上 AppServer 安装的目录。 并选上 Enable Integrate.   
    Tools Menu ??>Enterprise Setup ??>Application Server ??>Weblogic6.0     
    填上 Weblogic 安装的目录。 D、配置Default Project Properties 
    Project ??>Default Project Properties ??>Path ??>Required Libraries     
    选择Weblogic6.0;     Project ??>Default Project Properties ??>Build ??>IDL     
    在 IDL compiler 选择Weblogic; 
    在weblogic 页上,什么都不选。   
      Project ??>Default Project Properties ??>Run ??>Application   
    ? 选择main class 为 weblogic.Server (当你正确设定Weblogic6.0包后,可以找到该类。)   ? 把Complile before running 和 Complile before debugging 的钩子去掉,否则即使你运行一次EJB客户端都好都会重新制作一次EJB包。 
    Project ??>Default Project Properties ??>Enterprise  点“..”这这里选择 Application Server ,当然又是选Weblogic6.0。  选中 Weblogic6.0后点 Edit: 
    ? 在Require Libraries添加 Weblogic6.0包,把其他删除; 
    ? 在class 中删除所有的类的路径; 
    ? 修改VM Parameters:我机器上是 
    -ms64m -mx64m -Djava.library.path=C:\bea\wlserver6.0\bin -Dbea.home=C:\bea -Dweblogic.Domain=Suzhou -Dweblogic.Name=test -Djava.security.policy==C:\bea\wlserver6.0\lib\weblogic.policy   -classpath C:\bea\wlserver6.0\lib\cr_wls60f.jar;C:\bea\wlserver6.0\lib\weblogic_sp.jar;C:\bea\wlserver6.0\lib\weblogic.jar;.  -Dweblogic.management.password=testsystem