graph TD;
A[GetActiveAutoSplitProcessStatusesByDmsFolderId1] --> B{cache exists ?}
B --> |Yes| F{cache expired ?}
F --> |No| D[return]
B --> |No| C[request dms service]
F --> |Yes| C
C --> E[store result into cache]
E --> D
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Copyright (c) 2020 Pete Johanson | |
* | |
* SPDX-License-Identifier: MIT | |
*/ | |
#include <dt-bindings/zmk/matrix_transform.h> | |
/ { | |
chosen { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.util.Arrays; | |
import java.util.List; | |
import java.util.stream.Collectors; | |
class Scratch { | |
public static void main(String[] args) { | |
List<String> newFormIds = Arrays.asList("1", "2", "3", "5"); | |
List<String> results = Arrays.asList("1", "2", "3"); | |
List<String> restFormIds = newFormIds.stream() | |
.filter(s -> !results.contains(s)).collect(Collectors.toList()); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"io" | |
"os" | |
"strings" | |
) | |
type rot13Reader struct { | |
r io.Reader |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
events {} | |
http { | |
proxy_max_temp_file_size 0; | |
proxy_buffering off; | |
error_log /tmp/nginx_error.log; | |
access_log /tmp/nginx_access.log; | |
upstream frontend { | |
server 127.0.0.1:8080; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
## Default Elasticsearch configuration from Elasticsearch base image. | |
## https://github.com/elastic/elasticsearch/blob/7.11/distribution/docker/src/docker/config/elasticsearch.yml | |
# | |
cluster.name: "docker-cluster" | |
network.host: 0.0.0.0 | |
## X-Pack settings | |
## see https://www.elastic.co/guide/en/elasticsearch/reference/7.11/setup-xpack.html | |
xpack.license.self_generated.type: basic |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pymysql | |
from openpyxl import load_workbook | |
def write_to_db(conn, id, src_type, run_args): | |
src_type = 1 if src_type == '云更新' else 0 | |
cursor = conn.cursor() | |
sql = "update game_infos set src_type = %s, run_args = %s where id = %s;" | |
cursor.execute(sql, (src_type, run_args, id)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Given two strings s1, s2, find the lowest ASCII sum of deleted characters to m | |
//ake two strings equal. | |
// | |
// Example 1: | |
// | |
//Input: s1 = "sea", s2 = "eat" | |
//Output: 231 | |
//Explanation: Deleting "s" from "sea" adds the ASCII value of "s" (115) to the | |
//sum. | |
//Deleting "t" from "eat" adds 116 to the sum. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Solve a given equation and return the value of 'x' in the form of a string "x= | |
//#value". The equation contains only '+', '-' operation, the variable 'x' and its | |
// coefficient. You should return "No solution" if there is no solution for the eq | |
//uation, or "Infinite solutions" if there are infinite solutions for the equation | |
//. | |
// | |
// If there is exactly one solution for the equation, we ensure that the value o | |
//f 'x' is an integer. | |
// | |
// |
NewerOlder