9.20 Hangzhou Yunqi CloudLab: environment preparation-Alibaba Cloud Developer Community

from: Alibaba cloud storage service 2018-09-18 1926

introduction: CloudLab scenario introduction with the development of information technology, enterprises produce various structured and semi-structured data every day. How to store and process these data efficiently and at low cost and how to give full play to the value of the data are common challenges faced by enterprises. In today's CloudLab, we will deploy a recommended message system to let you experience that a TableStore model based on table store (Timeline) can quickly develop an enterprise internal message system.
+ Follow to continue viewing

with the development of informatization, enterprises produce various structured and semi-structured data every day. How to store and process these data efficiently and at low cost and how to give full play to the value of the data are common challenges faced by enterprises. Today's CloudLab will help you deploy a simple messaging system. You can experience the TableStore model based on table store (Timeline) to quickly develop an enterprise internal messaging system. At the same time, table store (TableStore) will release GlobalIndex and SearchIndex functions at this cloud conference. Based on powerful retrieval empowerment, table store (TableStore) it can efficiently store large amounts of data and provide convenient query and retrieval functions. Let's experience the complete steps of CloudLab together.

  1. bring your own development notebook, or use an Alibaba Cloud account to purchase an ECS instance and prepare the java8 environment. (Note: If you are using ECS, open port 8081)

    1. to create an ECS instance, perform the following operations in the console:

    1. you can download Java8 here.

      1. Mac
      2. Linux 64 wei
      3. Windows 64 wei
  2. create an instance in the table store console. (We recommend that you use a table store instance and VPC address in the same region to access ecs instances.)

enter your own instance name, which must be unique in the region. We recommend that you select a personalized instance name to avoid conflicts with existing instances. Our program automatically creates tables. You do not need to manually create tables here. You can also create tables in the console and read and write data.

  1. View the accesskey of an Alibaba cloud account.
  2. Use binary to download the demo. binary address http://danieldoc.oss-cn-hangzhou.aliyuncs.com/im-demo.jar
  3. deploy and start the message system with one click. Replace the following instance information with the created instance and accesskey.
  java -jar im-demo.jar  \
   --aliyun.tablestore.endpoint="xxxxx" \
   --aliyun.tablestore.AccessKeyID="xxxxx" \
   --aliyun.tablestore.AccessKeySecret="xxxxx" \
   --aliyun.tablestore.instanceName="xxxxx" 
  1. Through the web page. http:// localhost:8081 or http:// ecs public network address: 8081 to access our IM chat page. After sending and receiving messages on the web page, you can go back to the table store console to query data.
  2. Go to the console of the region where the instance is located, and click View instance details.
  3. Go to the data management page of the table in the instance to query data. According to the introduction in the Lab, there are mainly two data tables in our demo. One is im_demo_timeline_SyncTable, which is used for message distribution synchronization, the other one is im_demo_timeline_StoreTable, which is a full message table. We can perform a data query to see how data is organized under Timeline model. Click data management.

im_demo_timeline_StoreTable, we can see that the primary key has two columns. The first column is timelineid, which is a person's outbox, that is, all his sent messages. The second column is an auto-increment column. Our client can use this auto-increment id to pull messages in sequence. Because the new message generates a larger ID number on the TableStore server. The message content in our model is free. Users can encrypt and store it here, serialize and store it, or directly store the original text string of the message. Here, for the convenience of demonstration, we use plaintext string to store. im_demo_timeline_SyncTable is also a table of the timeline model, but this table is a table after the message is written and spread. Each timeline represents a user's message inbox. The auto-increment column is also used, the client can pull new messages without losing the order.

  1. In addition to the basic data query function, we demonstrate a new SearchIndex function released at this Yunqi Conference, which is to flexibly query data through Index building. For more information about new features, see here.

In addition to flexible attribute retrieval and full-text message content retrieval, indexes can also help us to do some rapid statistics, such as the number of messages: these features have been officially released in Yunqi this time. You can apply for an invitation test. After you apply for an invitational test, you can experience the full functions in your console.

If you fail to complete the entire process in time, you can use the following address to directly experience the process: http:// 101.132.45.75:8081/

postscript

if you are interested, you can download the demo source code here to learn more about how to develop a message system based on table store.

Of course, you are welcome to scan the code and join the group for all table storage problems. We will provide expert services for R & D.

Storage elastic Computing NoSQL big data Linux
linux data storage linux storage data recovery big data storage and computing store log data official data storage
developer Community> alibaba Cloud storage service
Selected, One-Stop Store for Enterprise Applications
Support various scenarios to meet companies' needs at different stages of development

Start Building Today with a Free Trial to 50+ Products

Learn and experience the power of Alibaba Cloud.

Sign Up Now