<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:media="http://search.yahoo.com/mrss/" version="2.0"><channel><title>宇码境</title><link>http://zyhtech.com.cn</link><atom:link href="http://zyhtech.com.cn/rss.xml" rel="self" type="application/rss+xml"/><description>码上成功</description><generator>Halo v2.24.2</generator><language>zh-cn</language><image><url>http://zyhtech.com.cn/upload/zyh_logo-removebg-preview.png</url><title>宇码境</title><link>http://zyhtech.com.cn</link></image><lastBuildDate>Thu, 21 May 2026 17:36:01 GMT</lastBuildDate><item><title><![CDATA[AgentScope Java连接本地LM Studio]]></title><link>http://zyhtech.com.cn/archives/agentscope-java%E8%BF%9E%E6%8E%A5%E6%9C%AC%E5%9C%B0lm-studio</link><description><![CDATA[<img src="http://zyhtech.com.cn/plugins/feed/assets/telemetry.gif?title=AgentScope%20Java%E8%BF%9E%E6%8E%A5%E6%9C%AC%E5%9C%B0LM%20Studio&amp;url=/archives/agentscope-java%E8%BF%9E%E6%8E%A5%E6%9C%AC%E5%9C%B0lm-studio" width="1" height="1" alt="" style="opacity:0;">null]]></description><guid isPermaLink="false">/archives/agentscope-java%E8%BF%9E%E6%8E%A5%E6%9C%AC%E5%9C%B0lm-studio</guid><dc:creator>zyh</dc:creator><enclosure url="http://zyhtech.com.cn/apis/api.storage.halo.run/v1alpha1/thumbnails/-/via-uri?uri=%2Fupload%2Fnetwork-6475769_150.jpg&amp;size=m" type="image/jpeg" length="103925"/><category>java</category><pubDate>Mon, 30 Mar 2026 05:09:15 GMT</pubDate></item><item><title><![CDATA[rancher2.6.3+jenkins+gitee部署springboot服务]]></title><link>http://zyhtech.com.cn/archives/rancher2.6.3%2Bjenkins%2Bgitee%E9%83%A8%E7%BD%B2springboot%E6%9C%8D%E5%8A%A1</link><description><![CDATA[<img src="http://zyhtech.com.cn/plugins/feed/assets/telemetry.gif?title=rancher2.6.3%2Bjenkins%2Bgitee%E9%83%A8%E7%BD%B2springboot%E6%9C%8D%E5%8A%A1&amp;url=/archives/rancher2.6.3%2Bjenkins%2Bgitee%E9%83%A8%E7%BD%B2springboot%E6%9C%8D%E5%8A%A1" width="1" height="1" alt="" style="opacity:0;">null]]></description><guid isPermaLink="false">/archives/rancher2.6.3%2Bjenkins%2Bgitee%E9%83%A8%E7%BD%B2springboot%E6%9C%8D%E5%8A%A1</guid><dc:creator>zyh</dc:creator><enclosure url="http://zyhtech.com.cn/apis/api.storage.halo.run/v1alpha1/thumbnails/-/via-uri?uri=%2Fupload%2Fjenkins-9.png&amp;size=m" type="image/jpeg" length="48797"/><category>java</category><pubDate>Fri, 26 Sep 2025 05:11:20 GMT</pubDate></item><item><title><![CDATA[git命令使用]]></title><link>http://zyhtech.com.cn/archives/gitming-ling-shi-yong</link><description><![CDATA[<img src="http://zyhtech.com.cn/plugins/feed/assets/telemetry.gif?title=git%E5%91%BD%E4%BB%A4%E4%BD%BF%E7%94%A8&amp;url=/archives/gitming-ling-shi-yong" width="1" height="1" alt="" style="opacity:0;"> Git命令使用主要涵盖基础配置、密钥生成、标签管理及代码同步等核心操作。信息配置阶段需全局设置用户身份，通过`git config --global user.name "姓名"`和`git config --global user.email "邮箱"`标识提交者身份。SSH密钥生成是远程仓库认证的关键，旧版Git使用`ssh-keygen -t rsa -C "邮箱"`，新版（如2.39.2及以上）推荐`ssh-keygen -t ed25519 -C "邮箱"`，密钥默认存储于`C:\Users\用户名\.ssh`目录。标签管理用于版本标记，新建标签用`git tag -a v1.0.0 -m "描述"`，推送至远程需`git push origin v1.0.0`，重命名标签则需结合本地重命名（`git tag new_tag old_tag`）、删除旧标签（本地`git tag -d old_tag`、远程`git push origin :refs/tags/old_tag`）及推送（`git push --tags`）。远程代码覆盖本地时，通过`git fetch --all`获取最新信息，`git reset --hard origin/master`重置本地分支，再`git pull`拉取更新，确保本地代码与远程同步。]]></description><guid isPermaLink="false">/archives/gitming-ling-shi-yong</guid><dc:creator>zyh</dc:creator><enclosure url="http://zyhtech.com.cn/apis/api.storage.halo.run/v1alpha1/thumbnails/-/via-uri?uri=%2Fupload%2Fcode-7522129_150.png&amp;size=m" type="image/jpeg" length="67847"/><category>git</category><pubDate>Thu, 11 Sep 2025 05:32:00 GMT</pubDate></item><item><title><![CDATA[Eclipse中项目目录结构顺序乱问题解决]]></title><link>http://zyhtech.com.cn/archives/eclipse%E4%B8%AD%E9%A1%B9%E7%9B%AE%E7%9B%AE%E5%BD%95%E7%BB%93%E6%9E%84%E9%A1%BA%E5%BA%8F%E4%B9%B1%E9%97%AE%E9%A2%98%E8%A7%A3%E5%86%B3</link><description><![CDATA[<img src="http://zyhtech.com.cn/plugins/feed/assets/telemetry.gif?title=Eclipse%E4%B8%AD%E9%A1%B9%E7%9B%AE%E7%9B%AE%E5%BD%95%E7%BB%93%E6%9E%84%E9%A1%BA%E5%BA%8F%E4%B9%B1%E9%97%AE%E9%A2%98%E8%A7%A3%E5%86%B3&amp;url=/archives/eclipse%E4%B8%AD%E9%A1%B9%E7%9B%AE%E7%9B%AE%E5%BD%95%E7%BB%93%E6%9E%84%E9%A1%BA%E5%BA%8F%E4%B9%B1%E9%97%AE%E9%A2%98%E8%A7%A3%E5%86%B3" width="1" height="1" alt="" style="opacity:0;">Eclipse中Maven项目目录结构显示顺序混乱会影响文件查找与项目管理效率。解决方法如下：右键点击项目，选择“Build Path”→“Configure Build Path...”，在弹出的属性窗口中切换至“Order and Export”标签页。该页面列出了项目中的目录结构，选中需要调整顺序的目录，通过右侧的“Up”（上移）或“Down”（下移）按钮即可重新排列顺序。根据实际需求调整后，点击“Apply and Close”保存设置，项目目录结构将按预期顺序显示。该方法通过修改构建路径的顺序配置，解决了目录结构显示混乱的问题，帮助开发者快速定位文件，提升开发效率。操作简单直观，无需额外插件，适用于Eclipse环境中各类Maven项目。]]></description><guid isPermaLink="false">/archives/eclipse%E4%B8%AD%E9%A1%B9%E7%9B%AE%E7%9B%AE%E5%BD%95%E7%BB%93%E6%9E%84%E9%A1%BA%E5%BA%8F%E4%B9%B1%E9%97%AE%E9%A2%98%E8%A7%A3%E5%86%B3</guid><dc:creator>zyh</dc:creator><enclosure url="http://zyhtech.com.cn/apis/api.storage.halo.run/v1alpha1/thumbnails/-/via-uri?uri=%2Fupload%2F3.png&amp;size=m" type="image/jpeg" length="43796"/><category>eclipse</category><pubDate>Thu, 11 Sep 2025 05:25:00 GMT</pubDate></item><item><title><![CDATA[mybatis映射postgresql数组类型字段相关查询及插入数据]]></title><link>http://zyhtech.com.cn/archives/mybatis%E6%98%A0%E5%B0%84postgresql%E6%95%B0%E7%BB%84%E7%B1%BB%E5%9E%8B%E5%AD%97%E6%AE%B5%E7%9B%B8%E5%85%B3%E6%9F%A5%E8%AF%A2%E5%8F%8A%E6%8F%92%E5%85%A5%E6%95%B0%E6%8D%AE</link><description><![CDATA[<img src="http://zyhtech.com.cn/plugins/feed/assets/telemetry.gif?title=mybatis%E6%98%A0%E5%B0%84postgresql%E6%95%B0%E7%BB%84%E7%B1%BB%E5%9E%8B%E5%AD%97%E6%AE%B5%E7%9B%B8%E5%85%B3%E6%9F%A5%E8%AF%A2%E5%8F%8A%E6%8F%92%E5%85%A5%E6%95%B0%E6%8D%AE&amp;url=/archives/mybatis%E6%98%A0%E5%B0%84postgresql%E6%95%B0%E7%BB%84%E7%B1%BB%E5%9E%8B%E5%AD%97%E6%AE%B5%E7%9B%B8%E5%85%B3%E6%9F%A5%E8%AF%A2%E5%8F%8A%E6%8F%92%E5%85%A5%E6%95%B0%E6%8D%AE" width="1" height="1" alt="" style="opacity:0;">本文设计并实现了一个基于PostgreSQL的错误码管理系统，核心解决Java数组类型与数据库数组字段的映射问题。系统通过自定义`ArrayTypeHandler`实现`String[]`类型与PostgreSQL `varchar[]`的双向转换，支持多种数组类型（如Integer、String等）的序列化与反序列化。在数据层，`MdErrorCodeMapper`接口定义了完整的CRUD操作，包括按错误码精确查询、利用PostgreSQL数组包含操作符`@&gt;`实现原错误码模糊查询、分页查询及批量插入/更新功能。MyBatis映射文件通过`resultMap`配置字段映射，并在SQL动态语句中集成自定义`typeHandler`，确保数组数据在数据库操作中的正确持久化与读取。该方案有效简化了复杂类型的数据处理，为错误码的高效管理提供了稳定的技术支撑。]]></description><guid isPermaLink="false">/archives/mybatis%E6%98%A0%E5%B0%84postgresql%E6%95%B0%E7%BB%84%E7%B1%BB%E5%9E%8B%E5%AD%97%E6%AE%B5%E7%9B%B8%E5%85%B3%E6%9F%A5%E8%AF%A2%E5%8F%8A%E6%8F%92%E5%85%A5%E6%95%B0%E6%8D%AE</guid><dc:creator>zyh</dc:creator><enclosure url="http://zyhtech.com.cn/apis/api.storage.halo.run/v1alpha1/thumbnails/-/via-uri?uri=%2Fupload%2Fmatrix-3109378_150.jpg&amp;size=m" type="image/jpeg" length="176719"/><category>java</category><pubDate>Tue, 12 Aug 2025 07:43:42 GMT</pubDate></item><item><title><![CDATA[Java设计模式之适配器模式]]></title><link>http://zyhtech.com.cn/archives/java%E8%AE%BE%E8%AE%A1%E6%A8%A1%E5%BC%8F%E4%B9%8B%E9%80%82%E9%85%8D%E5%99%A8%E6%A8%A1%E5%BC%8F</link><description><![CDATA[<img src="http://zyhtech.com.cn/plugins/feed/assets/telemetry.gif?title=Java%E8%AE%BE%E8%AE%A1%E6%A8%A1%E5%BC%8F%E4%B9%8B%E9%80%82%E9%85%8D%E5%99%A8%E6%A8%A1%E5%BC%8F&amp;url=/archives/java%E8%AE%BE%E8%AE%A1%E6%A8%A1%E5%BC%8F%E4%B9%8B%E9%80%82%E9%85%8D%E5%99%A8%E6%A8%A1%E5%BC%8F" width="1" height="1" alt="" style="opacity:0;">适配器模式是解决接口不兼容问题的结构型设计模式，通过"翻译官"式的接口转换使不兼容的类协同工作。该模式包含目标接口、适配者类和适配器三个核心角色，实现方式分为类适配器（基于继承）和对象适配器（基于组合）。在Spring Boot中广泛应用，如HandlerAdapter统一处理不同类型控制器、HttpMessageConverter转换HTTP请求响应等。其优势在于遵循单一职责原则和开闭原则，提高代码复用性和灵活性，特别适合集成第三方库或旧系统。但需注意避免过度使用，防止增加系统复杂度。适配器模式通过接口转换实现无缝协作，是解决兼容性问题的实用方案。]]></description><guid isPermaLink="false">/archives/java%E8%AE%BE%E8%AE%A1%E6%A8%A1%E5%BC%8F%E4%B9%8B%E9%80%82%E9%85%8D%E5%99%A8%E6%A8%A1%E5%BC%8F</guid><dc:creator>zyh</dc:creator><enclosure url="http://zyhtech.com.cn/apis/api.storage.halo.run/v1alpha1/thumbnails/-/via-uri?uri=%2Fupload%2Fscreenshot_2025-08-12_13-35-29.png&amp;size=m" type="image/jpeg" length="29705"/><category>java</category><pubDate>Tue, 12 Aug 2025 05:34:55 GMT</pubDate></item><item><title><![CDATA[springboot中使用工厂模式]]></title><link>http://zyhtech.com.cn/archives/springbootzhong-shi-yong-gong-han-mo-shi</link><description><![CDATA[<img src="http://zyhtech.com.cn/plugins/feed/assets/telemetry.gif?title=springboot%E4%B8%AD%E4%BD%BF%E7%94%A8%E5%B7%A5%E5%8E%82%E6%A8%A1%E5%BC%8F&amp;url=/archives/springbootzhong-shi-yong-gong-han-mo-shi" width="1" height="1" alt="" style="opacity:0;">本文基于工厂模式与Spring框架，设计了一套灵活的接口多实现动态调用机制。核心通过TestFactory类实现，利用Spring依赖注入特性，自动将所有实现TestInterface的组件（如TestImpl1、TestImpl2、TestImpl3）以@Component指定的名称为key、实例为value存入ConcurrentHashMap，实现统一管理。Controller层通过TestFactory根据请求参数key动态获取对应实现类，调用其getMsg方法完成业务逻辑处理。该设计解耦了接口与具体实现，新增实现类只需添加@Component注解即可自动集成，无需修改工厂代码，符合开闭原则。同时，ConcurrentHashMap的选用保证了线程安全，适用于高并发场景。整体架构实现了接口的动态路由与扩展，为工厂模式在Spring环境下的应用提供了典型实践。]]></description><guid isPermaLink="false">/archives/springbootzhong-shi-yong-gong-han-mo-shi</guid><dc:creator>zyh</dc:creator><enclosure url="http://zyhtech.com.cn/apis/api.storage.halo.run/v1alpha1/thumbnails/-/via-uri?uri=%2Fupload%2F%25E4%25BB%25A3%25E7%25A0%2581%25E8%2583%258C%25E6%2599%25AF.png&amp;size=m" type="image/jpeg" length="751418"/><category>java</category><pubDate>Sat, 9 Aug 2025 01:59:13 GMT</pubDate></item><item><title><![CDATA[java流式查询模式]]></title><link>http://zyhtech.com.cn/archives/java%E6%B5%81%E5%BC%8F%E6%9F%A5%E8%AF%A2%E6%A8%A1%E5%BC%8F</link><description><![CDATA[<img src="http://zyhtech.com.cn/plugins/feed/assets/telemetry.gif?title=java%E6%B5%81%E5%BC%8F%E6%9F%A5%E8%AF%A2%E6%A8%A1%E5%BC%8F&amp;url=/archives/java%E6%B5%81%E5%BC%8F%E6%9F%A5%E8%AF%A2%E6%A8%A1%E5%BC%8F" width="1" height="1" alt="" style="opacity:0;">流式查询模式是一种针对大数据量查询的优化方案，通过逐条传输数据而非一次性加载至内存，显著降低内存占用并提升查询效率。其核心优势在于避免内存溢出风险，尤其适用于海量数据处理场景。 在技术实现层面，JDBC需配置ResultSet为TYPE_FORWARD_ONLY及CONCUR_READ_ONLY，并设置fetchSize控制单次获取记录数；MyBatis通过fetchSize属性与Cursor接口实现流式遍历；Spring Boot+MyBatis可在配置文件中设置default-fetch-size，Mapper接口返回Cursor类型；Spring Data JPA则通过@Query返回Stream对象，结合@Transactional(readOnly=true)保证事务安全。 使用时需注意及时关闭资源（如Connection、Cursor、Stream），避免absolute()等失效方法，且仅适用于查询操作。性能上，其速度受网络传输与数据库负载影响，但对大数据量场景，内存优化优势远超潜在传输开销，是高效处理大规模数据的关键手段。]]></description><guid isPermaLink="false">/archives/java%E6%B5%81%E5%BC%8F%E6%9F%A5%E8%AF%A2%E6%A8%A1%E5%BC%8F</guid><dc:creator>zyh</dc:creator><enclosure url="http://zyhtech.com.cn/apis/api.storage.halo.run/v1alpha1/thumbnails/-/via-uri?uri=%2Fupload%2F87f69a3d3abd47349abf0a282417eafb_3.png&amp;size=m" type="image/jpeg" length="1255825"/><category>java</category><pubDate>Sat, 9 Aug 2025 01:50:58 GMT</pubDate></item><item><title><![CDATA[记录springboot中cucumber使用mock]]></title><link>http://zyhtech.com.cn/archives/%E8%AE%B0%E5%BD%95springboot%E4%B8%ADcucumber%E4%BD%BF%E7%94%A8mock</link><description><![CDATA[<img src="http://zyhtech.com.cn/plugins/feed/assets/telemetry.gif?title=%E8%AE%B0%E5%BD%95springboot%E4%B8%ADcucumber%E4%BD%BF%E7%94%A8mock&amp;url=/archives/%E8%AE%B0%E5%BD%95springboot%E4%B8%ADcucumber%E4%BD%BF%E7%94%A8mock" width="1" height="1" alt="" style="opacity:0;">本文记录了在Cucumber测试框架中结合Mockito对Mapper层进行mock的实践方法，旨在解决测试依赖问题，提升用例独立性。核心思路是保持Cucumber用例、步骤定义及Test Runner编写不变，引入mockito-core-1.10.19库，在Step类中完成mock逻辑。具体实现上，通过@Mock注解或Mockito.mock()创建Mapper的mock对象，使用Mockito.when()预设方法返回值（如支持参数匹配的Mockito.any()），关键步骤是通过ReflectionTestUtils将mock后的Mapper手动注入到Service层依赖字段中（需确保字段名一致）。该方法简化了测试环境搭建，无需依赖真实数据库，仅需在Step类中编写mock代码即可实现隔离测试。实践表明，该方案能满足Cucumber场景下对Mapper的mock需求，同时为类似依赖mock场景提供了可复用的参考思路。后续可探索更高效的注入方式，进一步优化测试流程。]]></description><guid isPermaLink="false">/archives/%E8%AE%B0%E5%BD%95springboot%E4%B8%ADcucumber%E4%BD%BF%E7%94%A8mock</guid><dc:creator>zyh</dc:creator><enclosure url="http://zyhtech.com.cn/apis/api.storage.halo.run/v1alpha1/thumbnails/-/via-uri?uri=%2Fupload%2F%25E4%25BB%25A3%25E7%25A0%2581%25E8%2583%258C%25E6%2599%25AF.png&amp;size=m" type="image/jpeg" length="751418"/><category>java</category><pubDate>Sat, 9 Aug 2025 01:50:58 GMT</pubDate></item><item><title><![CDATA[java8 Stream中方法简单示例]]></title><link>http://zyhtech.com.cn/archives/java8-stream%E4%B8%AD%E6%96%B9%E6%B3%95%E7%AE%80%E5%8D%95%E7%A4%BA%E4%BE%8B</link><description><![CDATA[<img src="http://zyhtech.com.cn/plugins/feed/assets/telemetry.gif?title=java8%20Stream%E4%B8%AD%E6%96%B9%E6%B3%95%E7%AE%80%E5%8D%95%E7%A4%BA%E4%BE%8B&amp;url=/archives/java8-stream%E4%B8%AD%E6%96%B9%E6%B3%95%E7%AE%80%E5%8D%95%E7%A4%BA%E4%BE%8B" width="1" height="1" alt="" style="opacity:0;">[智谱AI 摘要生成异常：Server returned HTTP response code: 429 for URL: https://open.bigmodel.cn/api/paas/v4/chat/completions | {"error":{"code":"1302","message":"您当前使用该API的并发数过高，请降低并发，或联系客服增加限额。"}}]]]></description><guid isPermaLink="false">/archives/java8-stream%E4%B8%AD%E6%96%B9%E6%B3%95%E7%AE%80%E5%8D%95%E7%A4%BA%E4%BE%8B</guid><dc:creator>zyh</dc:creator><enclosure url="http://zyhtech.com.cn/apis/api.storage.halo.run/v1alpha1/thumbnails/-/via-uri?uri=%2Fupload%2F87f69a3d3abd47349abf0a282417eafb_3.png&amp;size=m" type="image/jpeg" length="1255825"/><category>java</category><pubDate>Sat, 9 Aug 2025 01:44:51 GMT</pubDate></item><item><title><![CDATA[设计模式【单例模式】]]></title><link>http://zyhtech.com.cn/archives/wei-ming-ming-wen-zhang-NR5viwPE</link><description><![CDATA[<img src="http://zyhtech.com.cn/plugins/feed/assets/telemetry.gif?title=%E8%AE%BE%E8%AE%A1%E6%A8%A1%E5%BC%8F%E3%80%90%E5%8D%95%E4%BE%8B%E6%A8%A1%E5%BC%8F%E3%80%91&amp;url=/archives/wei-ming-ming-wen-zhang-NR5viwPE" width="1" height="1" alt="" style="opacity:0;">[智谱AI 摘要生成异常：Server returned HTTP response code: 429 for URL: https://open.bigmodel.cn/api/paas/v4/chat/completions | {"error":{"code":"1302","message":"您当前使用该API的并发数过高，请降低并发，或联系客服增加限额。"}}]]]></description><guid isPermaLink="false">/archives/wei-ming-ming-wen-zhang-NR5viwPE</guid><dc:creator>zyh</dc:creator><enclosure url="http://zyhtech.com.cn/apis/api.storage.halo.run/v1alpha1/thumbnails/-/via-uri?uri=%2Fupload%2FIMG_20250809_110159.jpg&amp;size=m" type="image/jpeg" length="55325"/><category>java</category><pubDate>Fri, 8 Aug 2025 12:33:00 GMT</pubDate></item></channel></rss>