答应了ralasafe的汪总,要写份ralasafe的技术文档,趁有空先弄点东西出来。ralasafe是开源的权限管理中间件,提供可视化工具来进行权限管理,权限控制的粒度达到数据项及数据内容级别,当然集成了菜单权限的管理。具体的介绍请上官网查看:http://www.ralasafe.org/。 我写的这些文章,主要是讲解SSH和ralsafe的集成应用,以及扩展ralasafe的应用。
首先,要准备好SSH环境,关于SSH的集成在这里我就不细讲了。到官网,把ralasafe下载下来后,按下面的结构来配置运行ralasafe。
[img]http://dl.iteye.com/upload/attachment/538769/3e15a33f-fd2f-3fc3-b0d9-f9e7e941fffc.jpg[/img]
Web.xml
<!-- ralasafe -->
<servlet>
<servlet-name>ralasafe/RalasafeService</servlet-name>
<servlet-class>org.ralasafe.ui.server.RalasafeServiceImpl</servlet-class>
</servlet>
<servlet>
<servlet-name>ralasafe/DesignerServlet</servlet-name>
<servlet-class>org.ralasafe.servlet.DesignerServlet</servlet-class>
</servlet>
<servlet>
<servlet-name>ralasafe/UserTypeMngServlet</servlet-name>
<servlet-class>org.ralasafe.servlet.UserTypeMngServlet</servlet-class>
</servlet>
<servlet>
<servlet-name>ralasafe/UserTypeInstallServlet</servlet-name>
<servlet-class>org.ralasafe.servlet.UserTypeInstallServlet</servlet-class>
</servlet>
<servlet>
<servlet-name>ralasafe/StartupServlet</servlet-name>
<servlet-class>org.ralasafe.servlet.StartupServlet</servlet-class>
<init-param>
<param-name>repositoryDir</param-name>
<param-value>E:/workspace/framework/Web/xml/</param-value>
</init-param>
<init-param>
<param-name>secured</param-name>
<param-value>false</param-value>
</init-param>
<load-on-startup>4</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>ralasafe/RalasafeService</servlet-name>
<url-pattern>/ralasafe/RalasafeService</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>ralasafe/DesignerServlet</servlet-name>
<url-pattern>/ralasafe/designer</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>ralasafe/UserTypeMngServlet</servlet-name>
<url-pattern>/ralasafe/userTypeMng</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>ralasafe/UserTypeInstallServlet</servlet-name>
<url-pattern>/ralasafe/userTypeInstall</url-pattern>
</servlet-mapping>
注意此处XML文件夹路径可以使用相对路径,同时也要避免使用中文路径和空格的出现。
例如: ../webapps/gmis/xml/
首先,要准备好SSH环境,关于SSH的集成在这里我就不细讲了。到官网,把ralasafe下载下来后,按下面的结构来配置运行ralasafe。
[img]http://dl.iteye.com/upload/attachment/538769/3e15a33f-fd2f-3fc3-b0d9-f9e7e941fffc.jpg[/img]
Web.xml
<!-- ralasafe -->
<servlet>
<servlet-name>ralasafe/RalasafeService</servlet-name>
<servlet-class>org.ralasafe.ui.server.RalasafeServiceImpl</servlet-class>
</servlet>
<servlet>
<servlet-name>ralasafe/DesignerServlet</servlet-name>
<servlet-class>org.ralasafe.servlet.DesignerServlet</servlet-class>
</servlet>
<servlet>
<servlet-name>ralasafe/UserTypeMngServlet</servlet-name>
<servlet-class>org.ralasafe.servlet.UserTypeMngServlet</servlet-class>
</servlet>
<servlet>
<servlet-name>ralasafe/UserTypeInstallServlet</servlet-name>
<servlet-class>org.ralasafe.servlet.UserTypeInstallServlet</servlet-class>
</servlet>
<servlet>
<servlet-name>ralasafe/StartupServlet</servlet-name>
<servlet-class>org.ralasafe.servlet.StartupServlet</servlet-class>
<init-param>
<param-name>repositoryDir</param-name>
<param-value>E:/workspace/framework/Web/xml/</param-value>
</init-param>
<init-param>
<param-name>secured</param-name>
<param-value>false</param-value>
</init-param>
<load-on-startup>4</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>ralasafe/RalasafeService</servlet-name>
<url-pattern>/ralasafe/RalasafeService</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>ralasafe/DesignerServlet</servlet-name>
<url-pattern>/ralasafe/designer</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>ralasafe/UserTypeMngServlet</servlet-name>
<url-pattern>/ralasafe/userTypeMng</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>ralasafe/UserTypeInstallServlet</servlet-name>
<url-pattern>/ralasafe/userTypeInstall</url-pattern>
</servlet-mapping>
注意此处XML文件夹路径可以使用相对路径,同时也要避免使用中文路径和空格的出现。
例如: ../webapps/gmis/xml/