Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .asf.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
# All configurations could be found here: https://github.com/apache/infrastructure-asfyaml/

github:
description: "Fast. Easy. Done. Processing Excels without worrying about large files causing OOM."
description: "Fast. Easy. Done. Processing spreadsheets without worrying about large files causing OOM."
homepage: https://fesod.apache.org
labels:
- java
Expand Down
18 changes: 9 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,23 +39,23 @@

## Introduction

**Apache Fesod (Incubating)** is a high-performance and memory-efficient Java library for reading and writing Excel
**Apache Fesod (Incubating)** is a high-performance and memory-efficient Java library for reading and writing spreadsheet
files, designed to simplify development and ensure reliability.

Apache Fesod (Incubating) can provide developers and enterprises with great freedom and flexibility. We plan to
introduce more new features in the future to continually enhance user experience and tool usability. Apache Fesod (
Incubating) is committed to being your best choice for handling Excel files.
Incubating) is committed to being your best choice for handling spreadsheet files.

The name fesod(pronounced `/ˈfɛsɒd/`), an acronym for "fast easy spreadsheet and other documents" expresses the
project's origin, background and vision.

### Features

- **High-performance Reading and Writing**: Apache Fesod (Incubating) focuses on performance optimization, capable of
efficiently handling large-scale Excel data. Compared to some traditional Excel processing libraries, it can
efficiently handling large-scale spreadsheet data. Compared to some traditional spreadsheet processing libraries, it can
significantly reduce memory consumption.
- **Simplicity and Ease of Use**: The library offers a simple and intuitive API, allowing developers to easily integrate
it into projects, whether for simple Excel operations or complex data processing.
it into projects, whether for simple spreadsheet operations or complex data processing.
- **Stream Operations**: Apache Fesod (Incubating) supports stream reading, minimizing the problem of loading large
amounts of data at once. This design is especially important when dealing with hundreds of thousands or even millions
of rows of data.
Expand Down Expand Up @@ -101,7 +101,7 @@ dependencies {

### Read

Below is an example of reading an Excel document:
Below is an example of reading a spreadsheet document:

```java
// Implement the ReadListener interface to set up operations for reading data
Expand All @@ -120,14 +120,14 @@ public class DemoDataListener implements ReadListener<DemoData> {

public static void main(String[] args) {
String fileName = "demo.xlsx";
// Read Excel file
Fesod.read(fileName, DemoData.class, new DemoDataListener()).sheet().doRead();
// Read spreadsheet file
FesodSheet.read(fileName, DemoData.class, new DemoDataListener()).sheet().doRead();
}
```

### Write

Below is a simple example of creating an Excel document:
Below is a simple example of creating a spreadsheet document:

```java
// Sample data class
Expand Down Expand Up @@ -162,7 +162,7 @@ private static List<DemoData> data() {
public static void main(String[] args) {
String fileName = "demo.xlsx";
// Create a "Template" sheet and write data
Fesod.write(fileName, DemoData.class).sheet("Template").doWrite(data());
FesodSheet.write(fileName, DemoData.class).sheet("Template").doWrite(data());
}
```

Expand Down
18 changes: 9 additions & 9 deletions README_CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,16 +38,16 @@

## 简介

**Apache Fesod (Incubating)** 是一个高性能、内存高效的 Java 库,用于读写 Excel 文件,旨在简化开发并确保可靠性。
**Apache Fesod (Incubating)** 是一个高性能、内存高效的 Java 库,用于读写电子表格文件,旨在简化开发并确保可靠性。

Apache Fesod (Incubating) 可以为开发者和企业提供极大的自由度和灵活性。我们计划在未来引入更多新功能,以持续提升用户体验和工具可用性。Apache Fesod (Incubating) 致力于成为您处理 Excel 文件的最佳选择
Apache Fesod (Incubating) 可以为开发者和企业提供极大的自由度和灵活性。我们计划在未来引入更多新功能,以持续提升用户体验和工具可用性。Apache Fesod (Incubating) 致力于成为您处理电子表格文件的最佳选择

名称 fesod(发音为 `/ˈfɛsɒd/`),是 "fast easy spreadsheet and other documents"(快速简单的电子表格和其他文档)的首字母缩写,表达了项目的起源、背景和愿景。

### 特性

- **高性能读写**:Apache Fesod (Incubating) 专注于性能优化,能够高效处理大规模 Excel 数据。与一些传统的 Excel 处理库相比,它可以显著减少内存消耗。
- **简单易用**:该库提供了简单直观的 API,使开发者能够轻松将其集成到项目中,无论是简单的 Excel 操作还是复杂的数据处理
- **高性能读写**:Apache Fesod (Incubating) 专注于性能优化,能够高效处理大规模电子表格数据。与一些传统的电子表格处理库相比,它可以显著减少内存消耗。
- **简单易用**:该库提供了简单直观的 API,使开发者能够轻松将其集成到项目中,无论是简单的电子表格操作还是复杂的数据处理
- **流式操作**:Apache Fesod (Incubating) 支持流式读取,最大程度地减少一次性加载大量数据的问题。这一设计在处理数十万甚至数百万行数据时尤其重要。

## 安装
Expand Down Expand Up @@ -85,7 +85,7 @@ dependencies {

### 读取

以下是读取 Excel 文档的示例
以下是读取电子表格文档的示例

```java
// 实现 ReadListener 接口以设置读取数据的操作
Expand All @@ -104,14 +104,14 @@ public class DemoDataListener implements ReadListener<DemoData> {

public static void main(String[] args) {
String fileName = "demo.xlsx";
// 读取 Excel 文件
Fesod.read(fileName, DemoData.class, new DemoDataListener()).sheet().doRead();
// 读取电子表格文件
FesodSheet.read(fileName, DemoData.class, new DemoDataListener()).sheet().doRead();
}
```

### 写入

以下是创建 Excel 文档的简单示例
以下是创建电子表格文档的简单示例

```java
// 示例数据类
Expand Down Expand Up @@ -146,7 +146,7 @@ private static List<DemoData> data() {
public static void main(String[] args) {
String fileName = "demo.xlsx";
// 创建一个名为 "Template" 的工作表并写入数据
Fesod.write(fileName, DemoData.class).sheet("Template").doWrite(data());
FesodSheet.write(fileName, DemoData.class).sheet("Template").doWrite(data());
}
```

Expand Down
2 changes: 1 addition & 1 deletion website/docs/introduce.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ public class DemoDataListener implements ReadListener<DemoData> {
public static void main(String[] args) {
String fileName = "demo.xlsx";
// Read file
Fesod.read(fileName, DemoData.class, new DemoDataListener()).sheet().doRead();
FesodSheet.read(fileName, DemoData.class, new DemoDataListener()).sheet().doRead();
}
```

Expand Down
16 changes: 8 additions & 8 deletions website/docs/sheet/help/large-data.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,14 @@ When reading files larger than 10 MB, Microsoft Excel 03 is unable to handle the
memory. Microsoft Excel 2007 introduces the concept
of [Shared Strings](https://learn.microsoft.com/en-us/office/open-xml/spreadsheet/working-with-the-shared-string-table),
which can consume a significant amount of memory.
If all shared strings are loaded into memory, the memory usage can be approximately 3 to 10 times the size of the Excel
If all shared strings are loaded into memory, the memory usage can be approximately 3 to 10 times the size of the spreadsheet
file. Therefore, FesodSheet uses a strategy of first storing the file and then deserialising it to read the data,
thereby
saving memory. Of course, after deserialising the file, efficiency will decrease by approximately 30-50% (this is not
fixed and depends on the hit rate, which may exceed 100%).

If the read efficiency is acceptable, use the default setting. The permanent memory usage (for the entire process of
reading a single Excel file) generally does not exceed 50MB (most likely around 30MB), and the remaining temporary
reading a single spreadsheet file) generally does not exceed 50MB (most likely around 30MB), and the remaining temporary
memory is quickly recycled by the garbage collector.

### Default Policy
Expand All @@ -34,18 +34,18 @@ read an extremely large file.
### Configure Memory

If you want to customise the settings, first determine how much memory you are willing to allocate for reading a very
large Excel file.
For example, if you want the Excel file to occupy a maximum of 100MB of memory during the reading process (this is the
large spreadsheet file.
For example, if you want the spreadsheet file to occupy a maximum of 100MB of memory during the reading process (this is the
permanent memory usage during reading, not including memory immediately reclaimed by the young generation), then set the
size of the shared string stored in the file to 20MB (less than 20MB is stored in memory, more than 20MB is stored in a
temporary file), and then set the memory size occupied by the temporary shared string when stored in the file to
approximately 90MB.

If the maximum number of file entries is only a few hundred thousand, and the Excel file is only a few dozen megabytes,
If the maximum number of file entries is only a few hundred thousand, and the spreadsheet file is only a few dozen megabytes,
and there is no high concurrency, and memory is sufficient,

```java
// Force memory storage, so a 20M Excel file will use 150M of memory (many temporary objects, so 100M will be constantly GC'd).
// Force memory storage, so a 20M spreadsheet file will use 150M of memory (many temporary objects, so 100M will be constantly GC'd).
// This will be much more efficient than the complex strategy above.
// Just to clarify, all I did was add the readCache(new MapCache()) parameter. For the rest, refer to other examples.
FesodSheet.read().
Expand All @@ -58,7 +58,7 @@ High concurrency requirements, and often involve extremely large files.
```java
// The first parameter specifies how many MB of shared string data will be stored in the file (default is 5 MB).
// The second parameter specifies how many MB of cache data will be stored in memory when using file storage (default is 20 MB).
// For example, if you want to use 100 MB of memory (this refers to permanent memory usage during parsing, excluding temporary objects) to parse an Excel file, the calculation shows it to be approximately 20 MB + 90 MB, so set the parameters to: 20 and 90.
// For example, if you want to use 100 MB of memory (this refers to permanent memory usage during parsing, excluding temporary objects) to parse a spreadsheet file, the calculation shows it to be approximately 20 MB + 90 MB, so set the parameters to: 20 and 90.
// Here's a clarification: the only addition is the readCacheSelector(new SimpleReadCacheSelector(5, 20)) parameter; the rest follows the examples provided.
FesodSheet.read().

Expand All @@ -68,7 +68,7 @@ readCacheSelector(new SimpleReadCacheSelector(5, 20));
### About maxCacheActivateSize

When using file storage, FesodSheet splits the shared string into batches of **1000** items and then stores them in file
storage. Excel typically reads shared strings in sequential order, so by default, 1000 entries (approximately 20MB) are
storage. Spreadsheets typically read shared strings in sequential order, so by default, 1000 entries (approximately 20MB) are
kept in memory. If a match is found, the data is returned directly; if not, the file is read. Therefore, the size should
not be set too small, as this makes it difficult to find a match and results in constant file reads. Conversely, setting
it too large can consume excessive memory.
Expand Down
2 changes: 1 addition & 1 deletion website/docs/sheet/write/sheet.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ title: 'Sheet'

This chapter introduces how to configure Sheets to write data.

> **Note:** Excel limits sheet names to 31 characters. Longer names are automatically trimmed with a warning logged.
> **Note:** Microsoft Excel limits sheet names to 31 characters. Longer names are automatically trimmed with a warning logged.

## Writing to the Same Sheet

Expand Down
6 changes: 3 additions & 3 deletions website/i18n/en/code.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"site.description": {
"message": "A high-performance and memory-efficient Java library for reading and writing Excel files, designed to simplify development and ensure reliability."
"message": "A high-performance and memory-efficient Java library for reading and writing spreadsheet files, designed to simplify development and ensure reliability."
},
"quickstart": {
"message": "Get Start"
Expand All @@ -12,13 +12,13 @@
"message": "High-performance"
},
"homepage.feature.quick.description": {
"message": "Focuses on performance optimization, capable of efficiently handling large-scale Excel data.\n Compared to some traditional Excel processing libraries, it can significantly reduce memory consumption."
"message": "Focuses on performance optimization, capable of efficiently handling large-scale spreadsheet data.\n Compared to some traditional spreadsheet processing libraries, it can significantly reduce memory consumption."
},
"homepage.feature.simple.title": {
"message": "Simplicity and Ease of Use"
},
"homepage.feature.simple.description": {
"message": "The library offers a simple and intuitive API, allowing developers to easily integrate it into projects, whether for simple Excel operations or complex data processing."
"message": "The library offers a simple and intuitive API, allowing developers to easily integrate it into projects, whether for simple spreadsheet operations or complex data processing."
},
"homepage.feature.bigdata": {
"message": "Stream Operations"
Expand Down
2 changes: 1 addition & 1 deletion website/src/pages/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ export default function Home() {
return (
<Layout
title=""
description="Apache Fesod (Incubating) Official Documentation | Fast, concise, Java tool for processing Excel files that solves memory overflow issues with large files <head />">
description="Apache Fesod (Incubating) Official Documentation | Fast, concise, Java tool for processing spreadsheet files that solves memory overflow issues with large files <head />">
<HomepageHeader/>
<main>
<HomepageFeatures/>
Expand Down
Loading