博客
关于我
hibernate正向生成数据库表以及配置——hibernate.cfg.xml
阅读量:572 次
发布时间:2019-03-11

本文共 1800 字,大约阅读时间需要 6 分钟。

In the provided XML configuration file, we can observe the configuration settings for a Hibernate session factory that leverages an Oracle9Dialect. The key components include:1. **Session Factory Configuration**: The root element defines a session factory, which is essential for managing database connections in Hibernate.2. **Dialect Setting**: The dialect specified here is `org.hibernate.dialect.Oracle9Dialect`, indicating that the application is optimised to interact with an Oracle 9 database environment.3. **Connection Details**: The connection information is provided under the `connection.url` property, set to `jdbc:oracle:thin:@127.0.0.1:1521:orcl`. This URL specifies the Oracle Thin driver, hostname, port number, and database name.4. **Authentication Credentials**: The `connection.username` and `connection.password` fields are set to `student`, suggesting that this application uses a simple `student` account for database authentication.5. **Session Context and Driver Settings**: The `current_session_context_class` property set to `thread` indicates that each session operates within a thread-independent context, which is a standard setup for thread-safe applications.6. **Driver Class**: The `connection.driver_class` is specified as `oracle.jdbc.OracleDriver`, ensuring that the correct native driver is used for Oracle databases.7. **Additional Configuration Properties**: The `myeclipse.connection.profile` is set to `student`, which might be used for profile management within an IDE like MyEclipse. Additionally, `show_sql` and `format_sql` are enabled, which are useful for debugging purposes.8. **Mapping Resources**: The configuration includes mappings for two entities, `Student` and `Teacher`, referencing their respective XML mapping files located at specific paths.

转载地址:http://lzutz.baihongyu.com/

你可能感兴趣的文章
Linux编程基础之创建两个子进程而不创建孙子进程
查看>>
另一个树的子树
查看>>
hadoop 分布式文件系统的计算和高可用
查看>>
2021-05-08
查看>>
【Linux】VMware Workstation 不可恢复错误: (vcpu-0)
查看>>
VS中 fatal error LNK1123: 转换到 COFF 期间失败 的解决方法
查看>>
关于Img标签在固定宽高的容器内部以图片比例缩放存在
查看>>
python3---读写文件、POST表单请求、HTML处理、列表分割遍历,进行暴力破解用户名与密码
查看>>
Android Studio基础项目-布局XML设置的实战-全屏显示登录界面,去除按钮深颜色
查看>>
pyhton---异常处理的终极语法、网页访问基本读取、网页访问异常处理
查看>>
Centos 7.3 计算本目录下的以特定名字文件夹个数
查看>>
linux下编程出现 对'sem_wait'未定义的引用解决方案
查看>>
工具研究:(三)Nginx配置错误的路由时均统一跳转到登录界面
查看>>
前端框架(react+umi+dva+ant design pro )攻克: 二、react 父子组件通信(二)
查看>>
ant design pro v5去掉右边content区域的水印
查看>>
web_求和(练习)
查看>>
JavaScript——使用iterator遍历迭代map,set集合元素
查看>>
IAR调试卡顿的解决办法
查看>>
应用程序无法启动,应用程序的并行配置不正确完美解决方法
查看>>
【IntelliJ IDEA 2019.2】idea如何开启自动编译
查看>>