# Design of Distributed Traceability System for Wheat Products Quality

Xingye Zhang, Jianqin Wang, Jianye Cui, Jie Zheng, Jing Pan, Manlin Chen

► To cite this version:

Xingye Zhang, Jianqin Wang, Jianye Cui, Jie Zheng, Jing Pan, et al.. Design of Distributed Traceability System for Wheat Products Quality. 5th Computer and Computing Technologies in Agriculture (CCTA), Oct 2011, Beijing, China. pp.498-507, 10.1007/978-3-642-27281-3_56 . hal-01351853

HAL Id: hal-01351853

https://inria.hal.science/hal-01351853

Submitted on 4 Aug 2016

HAL is a multi-disciplinary open access
archive for the deposit and dissemination of sci-
entific research documents, whether they are pub-
lished or not. The documents may come from
teaching and research institutions in France or
abroad, or from public or private research centers.

L'archive ouverte pluridisciplinaire HAL, est
destinée au dépôt et à la diffusion de documents
scientifiques de niveau recherche, publiés ou non,
émanant des établissements d'enseignement et de
recherche français ou étrangers, des laboratoires
publics ou privés.

<figure><img src="image_1.png" /></figure>

Distributed under a Creative Commons Attribution 4.0 International License
# Design of Distributed Traceability System for Wheat Products Quality

Xingye Zhang¹, Jianqin Wang¹,²,*, Jianye Cui¹, Jie Zheng², Jing Pan², Manlin Chen²

1 College of Information and Electrical Engineering, China Agricultural University, Beijing, 100083, P.R.China
2 Great Wall Computer Software & System Inc.

* Corresponding author; E-mail: wjqcau@126.com

**Abstract.** The circulation of wheat products involves a number of different types of food-related enterprises, including planting bases, grain trading companies, warehousing enterprises, food processing plants, sales companies and so on. The centralized traceability architecture cannot meet the requirements such as transaction data security. While, the distributed traceability architecture faces the difficulty and complexity of information processing for the traceability data stored and managed by different enterprises. In order to meet the requirements imposed on distributed data management and diversity of deployment requirements, an EPC (Electronic Product Code) coding scheme is proposed, in addition, based on which we design and implement a distributed wheat products quality traceability system in this paper. The test indicates that the distributed quality traceability system can track the wheat products quality information in the whole supply chain of wheat products effectively.

**Keywords:** wheat products traceability system, EPC coding scheme, ONS

## 1 Introduction

China's wheat production and consumption is huge. Wheat products safety is a serious matter for consumers as well as for companies involved in the food chain. Because of the complexity and diversity of the wheat products circulation chain, it is extremely difficult to track the details of the wheat products information in each circulating step. Hence, it is urgent for business to build a traceability system for wheat products supply chain which is suitable to China's situation.

EPC (Electronic Product Code) is designed to give each product a unique identification number in order to effectively improve supply chain management. It can be used to track the movement of physical products throughout an entire supply network based on RFID (Radio-Frequency Identification) technology and the associated computer networks[1]. RFID is a non-contact and multi-objective automatic identification technology, widely used in traceability from farm to consumer[2]. The EPCIS (EPC Information Service) provides storage and query services for the EPC-related data of physical products, using EPC as index key[3].
ONS (Object Name Service) is a global query service, using the existing DNS (Domain Name System), used to help to locate the EPCIS when retrieving the EPC-related information from EPCIS which are hosted at each supply chain participant through the traceability system, by converting the EPC to a URL (Universal Resource Locater)[4].

Up to now, many traceability systems have been proposed based on EPC and RFID, such as aquatic product traceability system[5], meat product traceability system[6], agricultural products traceability system[7], cattle breeding traceability system[8]. Bello proposed a general model of traceability system in the field of food manufacturing chain[9]. However, most of the existing traceability systems are owned by one or several enterprises and require a central server to store the trace information in the whole supply chain.

Considering the diversity and complexity of the wheat products supply chain and the granular or powdered property of the wheat products itself, we develop a distributed traceability system for wheat products to meet the requirements imposed on distributed EPC-related data management and diversity of deployment requirements. With the help of ONS, each EPCIS server can exchange data of the products details, so as to track the wheat products quality information in the whole supply chain of wheat products effectively.

## 2 Wheat Products Supply Chain Model

Taking into account the reality in China, the wheat products supply chain is illustrated by Figure 1. The circulation includes wheat production, wheat trade and processing and wheat products sales. The wheat may come from an individual farmer or a planting base. Before sales company, the wheat or wheat products may go pass several grain trading companies, warehousing enterprises and food processing plants. Similarly, the wheat products may go pass several sales companies before a certain consumer. In each transaction, an EPC is generated for a batch of wheat products and the detail information of the products is stored and associated with it as well as in every process inside these enterprises.

<figure><img src="image_2.png" /><figcaption>Fig. 1. Wheat products supply chain</figcaption></figure>

For a certain batch of wheat products, its raw materials may come from several
enterprises. We show a batch of flour chain as an example represented in Figure 2. In this case, food processing plant F which produces the batch of flour, buys the raw materials (wheat) from warehousing enterprise D and warehousing enterprise E. The batch of raw materials from warehousing enterprise D comes from farmer G and planting base B. Besides, the batch of raw materials from warehousing enterprise E comes from grain trading company C and grain trading company C buy it from planting base A. And, the batch of flour is sold to food processing plant H.

<figure><img src="image_3.png" /><figcaption>Fig. 2. A batch of flour chain</figcaption></figure>

In order to trace out all the supply chain nodes and the detail information of the wheat products, each business entity in the wheat products supply chain should record the necessary information related to quality and security and so on, which provides the basis for the traceability system.

(1) Each business entity should record the production data for each batch of wheat products. For example, planting base and farmer should record the seed information and the details of the use of chemical fertilizers and pesticides, warehousing enterprise should record the rate of mildew, food processing plant should record the rate of water and so on.

(2) Each business entity should record the information of the flow of products. For a certain batch of wheat products, the information of the correspondence between container or vehicle and itself, the details about where it comes from and where it goes to, the details of the raw materials and so on should be recorded.

(3) Each business entity should generate a unique serial number for each batch of wheat products within it. All the information related to the batch of wheat products should be established links with the unique number. The unique serial number can be an EPC. When a transaction occurs, an EPC should be generated and the EPC is associated with all the related information of the certain batch of wheat products. The EPC will be used to trace the records of all the movements within the supply chain.
## 3 Wheat Products Distributed Traceability System Architecture

The wheat products supply chain in China is complicated and diverse. Not every business entity has ability to maintain a traceability system service. However, in order to trace the whole information of the supply chain, all the business entities in the supply chain should have the ability to use the traceability system.

Taking into consideration the factors such as the diversity and complexity of the wheat products supply chain and the granular or powdered property of the wheat products, we design a distributed traceability system for wheat products to meet the requirements imposed on distributed EPC-related data management and diversity of deployment requirements. The architecture of the distributed traceability system is represented in Figure 3.

<figure><img src="image_4.png" /><figcaption>Fig. 3. Architecture of distributed traceability system</figcaption></figure>

As is shown in Figure 3, this distributed traceability system is divided into two levels. The platforms in level 1 form the backbone of the system, while the platforms in level 2 are essential parts of the whole system. In this distributed traceability system, each business entity in the wheat products supply chain has its own company prefix in EPC, while not every business entity has its own EPCIS servers. The business entity in level 1 must have an EPCIS server and has got its own company prefix from the registration center. In other words, if a business entity owns an EPCIS server and has got its own company prefix from the registration center, its EPCIS server is a member of platforms in level 1. The business entity in level 2 has to register its own company prefix in the entity which is in level 1 and it can store its EPC-related data in its own EPCIS server as well as in the EPCIS server in level 1 which is owned by the business entity which gives the company prefix to it. On the condition that the EPC-related data is stored in the servers in level 2, the parent server in level 1 serves as a proxy when
data query occurs which will transmit the requests from the servers in level 2 to other servers and send back the responses as well.

The EPCIS servers in this system are independent, equal in status with each other and connect with each other through the ONS. Each EPCIS server has complete software system to support the storage and query service, including middleware software, business support system, web services system, the local ONS service system and so on. Each local client needs to equip RFID Reader & Writer, middleware system in order to read data from and write data to RFID tags.

## 4 EPC Coding Scheme for Distributed Traceability System

EPC coding is a coding standard which is compatible with EAN/UCC coding system. EPC is a unique number used to identify a specific item in the supply chain. The general structure of EPC consisting of a fixed length (8-bits) header followed by a series of numeric fields whose overall length, structure, and function are completely determined by the header value[10]. EPC can indicate different type of encoding, such as SGTIN, SSCC, SGLN, GRAI, GIAI, and so on.

Considering the various coding schemes, we choose SGTIN-96 to identify a batch of wheat products. SGTIN (Serialized Global Trade Identification Number) is a kind of new coding schemes, based on GTIN (Global Trade Item Number) which from the general specification EAN/UCC. A single GTIN can only mark a particular object class, not to identify a specific physical object. In order to give a single object a unique symbol, a serial number is appended to GTIN. GTIN and the unique serial number are called serial GTIN (SGTIN)[11]. SGTIN-96 has ninety six bits, and consists of six fields: header, filter value, partition, company prefix, item reference and serial number. Each SGTIN shares the same Header 00110000[12]. The filter value is used to distinguish the business type of the enterprise and the partition number is used to define the count of bits that the item reference and the company prefix can take up. The company prefix is used to distinguish business entities. Each business entity must register its own company prefix in the registration center and it can assign the item reference and serial number by itself. For example, after a planting base gets its company prefix, it can assign four decimal digits (fourteen bits) in the item reference to their subsidiaries to identify them as is shown in Table 1.

<table><caption>Table 1. EPC coding scheme based on SGTIN-96</caption><thead><tr><th></th><th>Header</th><th>Filter Value</th><th>Partition</th><th>Company Prefix</th><th>Item Reference</th><th>Serial Number</th></tr></thead><tbody><tr><td>Coding Segment Bit Count</td><td>8</td><td>3</td><td>3</td><td>24</td><td>14</td><td>4</td><td>38</td></tr><tr><td>planting base A0</td><td>00110000</td><td>3</td><td>5</td><td>6901001</td><td>0000</td><td>--</td><td>--</td></tr><tr><td>planting base A1</td><td>00110000</td><td>3</td><td>5</td><td>6901001</td><td>1000</td><td>--</td><td>--</td></tr><tr><td>grain trading company A0</td><td>00110000</td><td>3</td><td>5</td><td>6901002</td><td>0000</td><td>--</td><td>--</td></tr></tbody></table>
<table><tr><td>grain trading company A1</td><td>00110000</td><td>3</td><td>5</td><td>6901002</td><td>1000</td><td>--</td><td>--</td></tr><tr><td>grain trading company A2</td><td>00110000</td><td>3</td><td>5</td><td>6901002</td><td>2000</td><td>--</td><td>--</td></tr><tr><td>warehousing enterprise A0</td><td>00110000</td><td>3</td><td>5</td><td>6901003</td><td>0000</td><td>--</td><td>--</td></tr><tr><td>food processing plant A0</td><td>00110000</td><td>1</td><td>5</td><td>6901004</td><td>0000</td><td>--</td><td>--</td></tr></table>

According to the EPC coding scheme shown in Table 1, a business entity's company prefix takes up eleven decimal digits. For example, a sequence of 96-bit binary data - `00110000 011 101 1100100011011000011101101101001010001 0000 01 00000000000000000000000000111101001` can be converted to a standard URI: `urn:epc:tag:sgtin-96:6901001.0000.1.1001, 6901001`, in which, `6901001` is a company prefix got from the register center, `0` is a company prefix from a business entity in level 1, `1` is an item reference and `1001` is a batch number of wheat products.

# 5 Details of Distributed Traceability System Process

## 5.1 Data Flow Within A Business Entity

When a bath of wheat products is passing through a RFID reader equipped on one place or a transaction occurs or some information which needs to be recorded of a batch of wheat products is generated, a series of automatic or manual operations will be done to handle and store the information. The general data flow within a business entity is represented in Figure 4.

As is shown in Figure 4, EPCIS is the core node for the data flow within a business entity. Several signals such as an EPC number from a RFID reader, a query message from the business system will trigger a data flow. For example, when a bath of wheat products is passing through a RFID reader equipped on a gateway of a warehouse, the RFID reader will read all the RFID tags adhere to containers and vehicles and all the data from the reader will be transferred to a savant, then a report about the data from the savant will be “pushed” to EPCIS. After that, EPCIS will store the data and invoke the business system to deal with the data, then a set of data from the business system will be returned to EPCIS and EPCIS will store the set of data. Besides, when the business system handles the data, it may call EPCIS to do other things.

## 5.2 Data Flow Between EPCIS Servers

To track a supply chain, a series of data will be exchanged between EPCIS servers. The communication between any two EPCIS servers is private and they should agree on communication protocols and data formats before they exchange private data. In
general, two EPCIS servers exchange data via the Internet and using HTTP or HTTPS
provided by web services.

<figure><img src="image_5.png" /><figcaption>Fig. 4. A general data flow within a business entity</figcaption></figure>

Each EPCIS server is listening for requests from other servers almost all the time. When an EPCIS server gets requests from other servers, it will handle these requests and return responses in turn. In order to trace out a supply chain, an EPCIS server needs to send several requests to other servers to query the traceability information. Before an EPCIS server sends a request to another EPCIS server, it needs to get the IP address of that server by ONS network using an EPC. The general ONS query process is represented in Figure 5.

Taking the EPC 00110000 011 101 1100100011011000011101101101001010001 0000 01 00000000000000000000000000111101001 as an example, first, the URI conversion converts it to a standard URI: urn:epc:tag:sgtin-96:6901001.0000.1.1001, then, the ONS resolver converts the URI form to a domain name: 011001.6901001.sgtin-96.tag.ons.com, finally, the ONS network return the record of the domain name: 202.205.80.215.

For each EPC query, an EPCIS server will answer a series of record related to the
EPC, including rate of mildew, rate of water and so on. Sometimes the server also
answers a list of EPCs and the EPCs include where it comes from or the source of raw
materials or where it goes to. By querying all the EPCs which come from the answer
of each query, the detailed information of a supply chain is tracked. Taking the chain
shown in Figure 2 as an example, the data flow is represented in Figure 6.
<figure><img src="image_6.png" /><figcaption>Fig. 5. The general ONS query process</figcaption></figure>

<figure><img src="image_7.png" /><figcaption>Fig. 6. A general data flow of EPC query process</figcaption></figure>

As is shown in Figure 6, a track process of an EPC includes as many times of requests as the number of the nodes involved in the supply chain. In this case, a user queries the EPC 6901003.1000.1.2 from D to track the information of the circulation of the EPC. Firstly, D finds out three EPCs 6901003.1000.1.1, 6901001.2000.1.1 and 6901001.1000.1.1 which are associated with 6901003.1000.1.2 in itself. Then, D sends the first request 1 using EPC 6901003.1000.1.1 to F and gets the reply 2 with
the information related to EPC stored in server F and one EPC 6901004.1000.1.1
which is from H. Then D sends one request 3 using EPC 6901004.1000.1.1 to H and
gets the reply 4 with the information related to EPC stored in H from H. In this way,
D sends one request using EPC 6901001.1000.1.1 to G and one request using EPC
6901001.2000.1.1 to B, and gets one reply with information related to the requested
EPC from each server. Finally, the detailed information of the circulation related to
EPC 6901001.1000.1.2 is tracked.

6 Conclusion

In this paper, we presented a distributed traceability system for wheat products based on EPC and ONS. The system allows a user to track the detailed information of the whole supply chain. The architecture of the system has been described from several points of view and it has shown to have the ability to meet the requirements imposed on distributed EPC-related data management and diversity of deployment requirements.

In the architecture described above, each node of the supply chain involved in
retrieving traceability information can be queried for detailed information. Therefore,
the system's availability depends on each node's response time and the reliability of
each node.

For this reason, our future work will cover the study of dynamic storage query and
RQC (Reliability and Quality Control).

References

1. Barchetti, U., Bucciero, A., De Blasi, M., Mainetti, L., Patrono, L.:RFID, EPC and B2B convergence towards an item-level traceability in the pharmaceutical supply chain:2010 IEEE International Conference on RFID-Technology and Applications (RFID-TA)(2010)

2. Zangroniz, R., Pastor, J. M., Dios, J. J. D., Garcia-Escribano, J., Morenas, J., Garcia, A.: RFID-based traceability system for architectural concrete. Smart Objects: Systems, Technologies and Applications (RFID Sys Tech), 2010 European Workshop.,1-8(2010)

3. Tribowski, C., Goebel, C., Gunther, O.:EPCIS-Based Supply Chain Event Management: A Quantitative Comparison of Candidate System Architectures:International Conference on Complex, Intelligent and Software Intensive Systems, 2009. CISIS '09. (2009)

4. Object Naming Service (ONS) Version 1.0.1, http://www.gs1.org/sites/default/files/docs/ons/ons_1_0-standard-20051004.pdf

5. Zhiqiang, W., Xiaoping, Y., Dongning, J., Gang, W.:An aquatic product traceability system based on RFID technology:2010 IEEE International Conference on Software Engineering and Service Sciences (ICSESS)(2010)

6. Ren, S., Xu, H., Lian, Zhou, G.:Research on RFID-based meat product track and traceability system:2010 International Conference on Computer Application and System Modeling (ICCASM)(2010)

7. Li, Y., He, D.:Design and implementation of traceability information system for agriculture product quality:2010 2nd International Conference on Advanced Computer Control (ICACC)(2010)
10. **Xingye Zhang1, Jianqin Wang1,2,*, Jianye Cui1, Jie Zheng2, Jing Pan2, Manlin Chen2**

8. Zaiqiong, W., Zetian, F., Wei, C., Jinyou, H.:A RFID-based traceability system for cattle breeding in China:2010 International Conference on Computer Application and System Modeling (ICCASM)(2010)

9. Bello, L. L., Mirabella, O., Torrisi, N.:A general approach to model traceability systems in food manufacturing chains:10th IEEE Conference on Emerging Technologies and Factory Automation, 2005. ETFA 2005. (2005)

10. Chenghai Zhang, D. Z.:Automatic Identify Technology.Wuhan University Press(2010)

11. Study on Traceability Coding of Wheat Quality and Distributed Object Name Service, http://www.ingentaconnect.com/content/asp/senlet/2011/00000009/00000003/art00022

12. EPC Tag Data Standard Version 1.5, www.gs1.org/gsmp/kc/epcglobal/tds/tds_1_5-standard-20100818.pdf