Download:Distributed transaction practices address data consistency

There are more and more applications of distributed system based on microservice architecture, but there has not been a simple and unified implementation scheme for transactions under distributed system. This course introduces distributed systems, the Spring Cloud framework and its use, as well as several implementation modes of distributed transactions, starting from local transactions. The course also provides a large number of examples, so that students in the actual combat process, to master the distributed transaction implementation methods and ideas.

Suits the crowd

A mid-level Java developer, an aspiring young man committed to becoming an architect

Technical reserve requirements

Java Web development basics, Spring Framework basics, basic concepts of transactions

Understand the basic concepts of distributed systems

import time from selenium import webdriver from selenium.webdriver.common.action_chains import ActionChains from selenium.webdriver.support.wait import WebDriverWait from selenium.webdriver.support import expected_conditions as EC The from selenium.webdriver.com mon. By the import by # start Chromedriver, Webdriver.chrome () driver.maximize_window() driver.get("http://www.baidu.com") ActionChains AC = ActionChains(driver) Ele = driver.find_element_by_xpath('//span[@id="s-usersetting-top"]]') # Perform the corresponding operation ac.move_to_element(ele) # hover operation # 4 Wait = WebDriverWait(driver, 10) loc = (by.xpath, 10) loc = (by.xpath, 10) '//a[@class="setpref"]') wait.until(EC.visibility_of_element_located(loc)) driver.find_element(*loc).click() Time. Sleep (2) driver. Quit ()def move_to(): print()def click(): Print (' click ') actions = [] actions. Append (move_to) actions. Append (click) for action in actions: # perform # action = move_to action()import time from selenium import webdriver from selenium.webdriver.common.keys Import Keys # start Chromedriver Driver = webdriver.chrome () driver.maximize_window() driver.get("http://www.baidu.com") Driver.find_element_by_id ('kw').send_keys("selenium") # Driver.find_element_by_id ('kw').send_keys(keys.control,'a') # select all and type new python driver.find_element_by_id('kw').send_keys('python', Sleep (2) # driver.find_element_by_id('kw').send_keys('python') # Driver.find_element_by_id ('kw').send_keys(keys.enter) # Return time.sleep(2) driver.quit()< HTML > <head> <meta Charset ="UTF-8"> <title> Dropdown demo </title> </head> <body> <select ID ="province"> <option value="sj"> Shenzhen </option> <option Value ="gd"> Gd </option> <option value="sh"> Shanghai </option> <option value=" BJ "> Beijing </option> </select> <option Value ="sj"> Shenzhen </option> <option value="gz"> Guangzhou </option> <option value="sh"> Shanghai </option> <option Value ="bj"> bJ </option> </select> </body> import time from selenium import webdriver from selenium.webdriver.support.wait import WebDriverWait from The selenium. Webdriver. Support. The UI # import the Select start the Chromedriver, Driver = webdriver.chrome () driver.maximize_window() driver.get(r"D:\learn\test.html") wait = WebDriverWait(driver, Ele = driver.find_element_by_id(' type ') S.selt_by_value ('gd') # select value time.sleep(2) # select value time.sleep(2) Sleep (2) driver.quit()import time import datetime from Selenium import webdriver from selenium.webdriver.support import expected_conditions as EC from selenium.webdriver.support.wait import WebDriverWait from selenium.webdriver.common.by import By from selenium.webdriver.common.keys import Keys # Start the Chromedriver, Chrome() # driver.maximize_window() driver.get("https://www.12306.cn/") wait = WebDriverWait(driver, 30) loc = (By.XPATH, '//input[@id="train_date"]') wait.until(EC.visibility_of_element_located(loc)) js = 'document.getElementById("train_date").readOnly=false; 'driver.execute_script(js) time.sleep(2) # clear calendar, Driver.find_element (*loc).clear() today = datetime.date.today() tomorrow = today + datetime.timedelta(days=1) driver.find_element_by_id('train_date').send_keys(str(tomorrow)) time.sleep(2) driver.quit()Copy the code