# at 22452867 #180925 11:44:02 server id 8 end_log_pos 22452944 CRC32 0xc23d3641 Table_map: `base`.`by_renew_history` mapped to number 182 # at 22452944 #180925 11:44:02 server id 8 end_log_pos 22453106 CRC32 0x7a809e4e Update_rows: table id 182 flags: STMT_END_F
BINLOG ' Aq+pWxMIAAAATQAAANCaVgEAALYAAAAAAAEABGJhc2UAEGJ5X3JlbmV3X2hpc3RvcnkACwMPAw8S ARIDEgMDB5YAWgAAAAD+B0E2PcI= Aq+pWx8IAAAAogAAAHKbVgEAALYAAAAAAAEAAgAL/////wD+igAAAA4yMDE4MDcyNTE2MzcyNugD AAAQMTExMTExMTExMDExMTExNJmgcwlbAZmgcwlbAwAAAJmgcwlaAP6KAAAADjIwMTgwNzI1MTYz NzI26AMAABAxMTExMTExMTEwMTExMTEzmaBzCVsBmaBzCVsDAAAAmaBzCVpOnoB6 '/*!*/; # at 22453106 #180925 11:44:02 server id 8 end_log_pos 22453137 CRC32 0x3787881e Xid = 8121164 COMMIT/*!*/; SET @@SESSION.GTID_NEXT= 'AUTOMATIC' /* added by mysqlbinlog */ /*!*/; DELIMITER ; # End of log file /*!50003 SET COMPLETION_TYPE=@OLD_COMPLETION_TYPE*/; /*!50530 SET @@SESSION.PSEUDO_SLAVE_MODE=0*/;
// 定义的拖拽方法 public void drag(Component c) { // c 表示要接受拖拽的控件 new DropTarget(c, DnDConstants.ACTION_COPY_OR_MOVE, new DropTargetAdapter() { @Override public void drop(DropTargetDropEvent dtde)// 重写适配器的drop方法 { try { if (dtde.isDataFlavorSupported(DataFlavor.javaFileListFlavor))// 如果拖入的文件格式受支持 { dtde.acceptDrop(DnDConstants.ACTION_COPY_OR_MOVE);// 接收拖拽来的数据
@SuppressWarnings("unchecked") List<File> list = (List<File>) (dtde.getTransferable() .getTransferData(DataFlavor.javaFileListFlavor));
if (list.size() > 1) { JOptionPane.showMessageDialog(null, "一次拖一个文件,靓仔"); return; }
...... Name: Apache Maven Source Plugin Description: The Maven Source Plugin creates a JAR archive of the source files of the current project. Group Id: org.apache.maven.plugins Artifact Id: maven-source-plugin Version: 3.0.1 Goal Prefix: source
This plugin has 7 goals:
source:aggregate Description: Aggregate sources for all modules in an aggregator project.
source:generated-test-jar Description: This plugin bundles all the test sources into a jar archive.
source:help Description: Display help information on maven-source-plugin. Call mvn source:help -Ddetail=true -Dgoal=<goal-name> to display parameter details.
source:jar Description: This plugin bundles all the sources into a jar archive.
source:jar-no-fork Description: This goal bundles all the sources into a jar archive. This goal functions the same as the jar goal but does not fork the build and is suitable for attaching to the build lifecycle.
source:test-jar Description: This plugin bundles all the test sources into a jar archive.
source:test-jar-no-fork Description: This goal bundles all the test sources into a jar archive. This goal functions the same as the test-jar goal but does not fork the build, and is suitable for attaching to the build lifecycle.
For more information, run 'mvn help:describe [...] -Ddetail' ......
./install_server.sh Welcome to the redis service installer This script will help you easily set up a running redis server
Please select the redis port for this instance: [6379] Selecting default: 6379 Please select the redis config file name [/etc/redis/6379.conf] /usr/local/redis/redis.conf Please select the redis log file name [/var/log/redis_6379.log] Selected default - /var/log/redis_6379.log Please select the data directory for this instance [/var/lib/redis/6379] /data/redis Please select the redis executable path [] /usr/local/redis/bin/redis-server Selected config: Port : 6379 Config file : /usr/local/redis/redis.conf Log file : /var/log/redis_6379.log Data dir : /data/redis Executable : /usr/local/redis/bin/redis-server Cli Executable : /usr/local/redis/bin/redis-cli Is this ok? Then press ENTER to go on or Ctrl-C to abort. Copied /tmp/6379.conf => /etc/init.d/redis_6379 Installing service... Successfully added to chkconfig! Successfully added to runlevels 345! Starting Redis server... Installation successful!
InterProcessMutex lock = new InterProcessMutex(client, lockPath); if ( lock.acquire(maxWait, waitUnit) ) { try { // do some work inside of the critical section here } finally { lock.release(); } }
领导选举
1 2 3 4 5 6 7 8 9 10 11 12 13
LeaderSelectorListener listener = new LeaderSelectorListenerAdapter() { public void takeLeadership(CuratorFramework client) throws Exception { // this callback will get called when you are the leader // do whatever leader work you need to and only exit // this method when you want to relinquish leadership } }
LeaderSelector selector = new LeaderSelector(client, path, listener); selector.autoRequeue(); // not required, but this is behavior that you will probably expect selector.start();