流淌Wow
作者流淌Wow·2015-05-22 10:18
软件开发工程师·德邦物流

Framework Manager入门教程(十二) - FM逆向工程(MotioPI)

字数 3404阅读 2676评论 2赞 1

在搞Java的时候,Java是可以根据class文件逆向生成代码的;Cognos呢,居然也可以,在网上找到了一些资料,现分享一下。

有的时候会遇到,本地的FM被删掉或者其他的情况,想要将已经发布的Package逆向生成模型,这种场景还是很常见的。

1. 官方解决方案

How to recover a corrupted or lost Framework Manager model.

[java] view plaincopy在CODE上查看代码片派生到我的代码片

  1. Cognos 10.x.x :  
  2. Steps :  
  3. 1. Backup <Cognos_Root_Installation>/configuration/CQEConfig.xml.sample  
  4. 2. Rename CQEConfig.xml.sample to CQEConfig.xml:  
  5. 3. Under XML tag : <component name="CQE"> add content :  
  6.   
  7. <section name="General Options">  
  8. <entry name="KeepModelXML" value="1" />  
  9. </section>  
  10.   
  11. 4. Save file and stop Cognos service  
  12. 5. Rename the directory <Cognos_Root_Installation>/data/cqe/RTModels to "ORIGINAL_RTModels" .  
  13. 6. Restart the Cognos Service.  
  14. 7. Launch Cognos Report Studio and create a new report using the package you wish to recover and run it, noting the time.  
  15. 8. Verify that a new <Cognos_Root_Installation>/data/cqe/RTModels directory has been created and an xml file with a creation time matching the run time of the report exists.  
  16. 9. Rename CQEConfig.xml created to CQEConfig.xml.recoversave or delete it.  
  17. 10. Move the newly created <Cognos_Root_Installation>/data/cqe/RTModels directory to a working location.  
  18. 11. Rename <Cognos_Root_Installation>/data/cqe/ORIGINAL_RTModels directory back to "RTModels".  
  19. 12. Restart the Cognos Service.  
  20. 13. Open Framework Manager, create and save a new empty project.  
  21. 14. Close Framework Manager.  
  22. 15. Locate the empty Framework Manager project directory and rename the model.xml file to model.xml.origin  
  23. 16. Copy the the xml file created in steps 8 into the empty Framework Manager project directory and rename the file "model.xml".  
  24. 17. It should now be possible to open the model in Framework Manager   

官方的这里看上去复杂点,以后有机会在尝试吧。

2. 使用MotioPI工具

这个略坑啊,官网上找了半天没找到下载地址,在经过一系列的波折后终于下载到了,大笑

官方的使用教程:http://info.motio.com/Blog/bid/70358/Recover-a-Lost-Cognos-Framework-Manager-Model-in-60-seconds-or-less

官方教程:http://www.motio.com/products/pi/gettingStarted.do

工具下载:

http://download.csdn.net/detail/jolingogo/7785129

这里就分享下我的使用过程吧:

2.1 安装

。。。。。。后面就不贴了,没什么特别的,一路安装就可以了。

我们打开使用:

。。。刚刚使用了下,看上去很强大啊,我们继续

2.2 使用

打开后的界面


在这里,我们需要输入服务器的Dispatch,Gateway,NameSpace,namespace的话可以自动带出来,如果有权限认证的话,需要填上账号,然后登陆即可。

我们暂时找到需要逆向工程的菜单


好了,到这里,就可以导出model.xml了,最后我们新建个项目,把model.xml文件覆盖一下就可以了。

如果觉得我的文章对您有用,请点赞。您的支持将鼓励我继续创作!

1

添加新评论2 条评论

鹿野鹿野数据仓库工程师大连诚高科技股份有限公司
2016-03-23 08:51
学习一下
kingwangkingwang商业智能工程师前景科技有限公司
2015-11-10 15:02
这个在东西很有帮助哦,小伙伴们看过来
Ctrl+Enter 发表

作者其他文章

相关问题

相关资料

X社区推广