加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 百科 > 正文

FB4.5 模型驱动开发环境配置

发布时间:2020-12-15 06:49:01 所属栏目:百科 来源:网络整理
导读:? LCDS3.1中的模型驱动(Model Driven)开发方式,非常方便。 服务端不需要编写一行代码,crud的操作全由LCDS中的组件FIBER代劳,动态生成的代码都在内存中,也无需手工配置服务,是不是很诱惑
?

LCDS3.1中的模型驱动(Model Driven)开发方式,非常方便。

服务端不需要编写一行代码,crud的操作全由LCDS中的组件FIBER代劳,动态生成的代码都在内存中,也无需手工配置服务,是不是很诱惑啊。呵呵

但是介绍环境配置的文章不多,这里简单把我查到的资料和配置过程记录下来。


使用的软件:
FlashBuilder4.5,LCDS3.1,Tomcat6.0,MySQL5.0

?
Application_Modeling_plugin下载地址:
https://www.adobe.com/cfusion/entitlement/index.cfm?e=lc_app_model

Installing the Modeler on Mac or Windows

  1. Open Flash Builder 4.5. On Windows 7,you must run Flash Builder as admininstrator.
  2. Open the Help > Install New Software… menu.
  3. Click on the Add button.
  4. Click on the Archive button
  5. Navigate to the directory that contains the FB4.5_Adobe_Application_Modeling_plugin_3.1.1.zip file.
  6. Select the FB4.5_Adobe_Application_Modeling_plugin_3.1.1.zip file.
  7. Click Open.
  8. Click OK.
  9. Check the checkbox next to Adobe Data Model Components for Flash Builder.
  10. Click Next.
    ???? Flash Builder has some of the components already,so the request is modified so that these components will be updated instead.
  11. Click Next again.
  12. Accept the License Agreement.
  13. Click Finish.
  14. If prompted with a security warning about unsigned software,click OK to continue with the installation.
  15. When prompted,restart Flash Builder.

Configuring RDS in Flash Builder

  1. Start Flash Builder.
  2. Open up the preferences screen from the menu option.
    ???? Windows: Help > Preferences
    ?? Mac: Flash Builder > Preferences
  3. Navigate to Adobe > RDS Configuration in the left-hand tree.
  4. Select the LCDS (localhost) RDS Server under Currently Configured RDS Servers.
  5. Change the context root to be lcds-samples or whatever web app you are using.
  6. Click the Test Connection button. If RDS is set up correctly,you should see a dialog that says "Test connection was successful".

Known Issues

  • The fiber.swc file in LiveCycle Data Services 3.1 is incompatible with Modeler 3.11.

    By default,new Flex projects for LiveCycle Data Services in Flash Builder use the fiber.swc file in the WEB-INFflexlibs directory of the target web application. This version of the fiber.swc file is missing a new method that is required for ActionScript code generation when working with Modeler 3.11. This version of the fiber.swc file is missing a new method that is required for using the model-driven form. When you try to use the model-driven form in an application,you will get an error that contains the following text:

    Method marked override must override another method.?

    To work around this issue,replace the the fiber.swc file in the WEB-INFflexlibs directory with a copy of the fiber.swc file from the FB_INSTALL_DIReclipsepluginscom.adobe.flexbuilder.project_4.5.0.30 8971fiberSwcs4.5libs directory.

  • Deploying a model that contains one of the following? objects results in an XML parsing error from the LiveCycle Data Services server,and the model cannot be deployed:
    • A service? that contains a function with parameters (arguments); this includes? a service? generated from an introspected remoting destination
    • An entity that contains a method with parameters


    配置JTA,否则无法使用LCDS的DataService服务。

    1,下载 jotm
    2,将压缩包内的JAR文件直接解压缩到tomcat的lib目录下 或者
    ? ? 为了是lib目录下不过于紊乱,可以建立一个目录,比如jotm-2.0.11(以2.0.11版为例)
    ? ? 然后修改<catalina_home>/conf/catalina.properties中common.loader的值,红色为增加的部分。

    common.loader=${catalina.base}/lib,${catalina.base}/lib/*.jar,${catalina.home}/lib,
    ${catalina.home}/lib/*.jar ,${catalina.home}/lib/jotm-2.0.11/*.jar

    这样,tomcat都能加载到jotm。
    ? ?
    配置RDS,让tomcat启动rds服务
    ?
    打开<catalina.home>/webapps/lcds/WEB-INF/web.xml?
    定位到
    <!-- begin rds
    ? ? ? <servlet>
    ? ? ? ? ? ? ? <servlet-name>RDSDispatchServlet</servlet-name>
    ? ? <display-name>RDSDispatchServlet</display-name>
    ? ? ? ? ? ? ? <servlet-class>flex.rds.server.servlet.FrontEndServlet</servlet-class>
    ? ? <init-param>
    ? ? ? <param-name>useAppserverSecurity</param-name>
    ? ? ? <param-value> true</param-value>
    ? ? </init-param>? ? ? ? ? ? ?
    ? ? ? ? ? ? ? <load-on-startup>10</load-on-startup>
    ? ? ? </servlet>
    ? ? ? <servlet-mapping id="RDS_DISPATCH_MAPPING">
    ? ? ? ? ? ? ? <servlet-name>RDSDispatchServlet</servlet-name>
    ? ? ? ? ? ? ? <url-pattern>/CFIDE/main/ide.cfm</url-pattern>
    ? ? ? </servlet-mapping>? ? ?
    end rds -->
    把开头和结尾的两行注释掉,
    把true换成false,目的是在FB开发环境中登录rds时不需要提供用户名/口令。
    ?
    配置web应用的context,以使用JTA(jotm)
    ?
    打开<catalina_home>/conf/catalina/localhost/<application>.xml?
    (<application>要换成具体的应用,如lcds_sample)
    ?
    <Context privileged="true" antiResourceLocking="false" antiJARLocking="false" reloadable="true">
    ? ? ? <Resource name="jdbc/<数据库名>" auth="Container" type="javax.sql.DataSource"
    ? ? ? ? ? ? ? maxActive="100" maxIdle="30" maxWait="10000"
    ? ? ? ? ? ? ? username="root" password="root"
    ? ? ? ? ? ? ? driverClassName="com.mysql.jdbc.Driver"
    ? ? ? ? ? ? ? url="jdbc:mysql://localhost:3306/<数据库名>?autoReconnect=true" />
    ? ? ? <!-- JOTM? -->
    ??? <Transaction factory="org.objectweb.jotm.UserTransactionFactory"
    ????????????? jotm.timeout="60" />
    </Context>
    ?
    (首发在新浪博客上 http://blog.sina.com.cn/s/blog_66349acf0100u3m5.html)

    (编辑:李大同)

    【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

      推荐文章
        热点阅读