简体   繁体   English

如何使用Spring Batch读写zOS(Mainframe)平面文件

[英]How to Read/write zOS(Mainframe) flat file using spring batch

I am developing spring batch application that should be executed/triggered on zOS (Mainframe). 我正在开发应在zOS(大型机)上执行/触发的Spring Batch应用程序。 I have to read/write the flat file in zos as a input file in spring batch and do some processing. 我必须在spring批处理中以zos形式读取/写入平面文件,并进行一些处理。 do we have some working examples ? 我们有一些可行的例子吗? does spring batch has the capability of reading direct Mainframe flat files ? spring batch是否具有读取直接大型机平面文件的功能? If so can you give me some working example. 如果可以的话,您能给我一些可行的例子。 Thanks in advance 提前致谢

Use the ZFile class in the z/OS SDK to read flat files (data sets). 使用z / OS SDK中的ZFile类读取平面文件(数据集)。 There's some useful samples to get your started https://github.com/zsystems/java-samples . 有一些有用的示例可以帮助您开始使用https://github.com/zsystems/java-samples It's basically a JNI wrapper over the C/C++ stdio fopen() and friends runtime library functions. 从本质上讲,它是C / C ++ stdio fopen()和朋友运行时库函数的JNI包装器。

Finally, able to solve the problem with this info. 最后,能够使用此信息解决问题。 https://jira.spring.io/browse/BATCH-497 As David said we have to ZFile and other classes from jzos provided by IBM. https://jira.spring.io/browse/BATCH-497正如David所说,我们必须使用ZFile和IBM提供的jzos中的其他类。 I am able to read the flat file from zos using spring batch. 我可以使用spring batch从zos读取平面文件。

读取inputstream时可以使用charset cp1047。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Spring Batch如何读取多个表(查询)作为Reader并将其写为平面文件写入 - Spring Batch How to read multiple table (queries) as Reader and write it as flat file write 从数据库读取批量数据(动态查询),并使用spring batch将其写入平面文件 - Read bulk data (Dynamic query) from Database and write to flat file using spring batch 使用Spring批处理读取文件并写入Map - Using Spring batch to read a file and write to a Map 如何使用 Spring Data Cassandra 从 cassandra 数据库读取超过百万条记录并使用 Spring Batch 将其写入文件? - How to read more than million records from cassandra Database using Spring Data Cassandra and write it into a file using Spring Batch? 无法在Spring批处理中写入FlatFile - 只有对象引用正在写入平面文件 - Unable to write to FlatFile in spring batch - only object reference are getting write to flat file 我应该如何使用Spring Batch编写结果文件 - How should I write a results file using Spring Batch Spring Batch:如何使用FlatFileItemReader读取CSV文件的页脚和验证 - Spring Batch : How to read footer of CSV file and validation using FlatFileItemReader 大型机ZOS机器的MAC地址 - MAC address for Mainframe ZOS machine Spring Batch等待平面文件中的行 - Spring Batch waiting for lines in flat file Spring批处理中平面文件中的空白问题 - Issue with white spaces in flat file in Spring batch
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM