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
#!/bin/bash | |
git checkout -b duplicate_mysql_to_postgresql | |
# Duplicate the MySQL "Extra Data Issuance Chain Deduplication" storage layer files into new PostgreSQL directories, preserving git line history. | |
# (h/t https://devblogs.microsoft.com/oldnewthing/20190919-00/?p=102904) | |
mkdir trillian/ctfe/storage/postgresql | |
git mv trillian/ctfe/storage/mysql/mysql.go trillian/ctfe/storage/postgresql/postgresql.go | |
git mv trillian/ctfe/storage/mysql/mysql_test.go trillian/ctfe/storage/postgresql/postgresql_test.go | |
git mv trillian/ctfe/storage/mysql/schema.sql trillian/ctfe/storage/postgresql/schema.sql |
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
#!/bin/bash | |
git checkout -b duplicate_mysql_to_postgresql | |
# Duplicate the MySQL quota.Manager and storage layer files into new PostgreSQL directories, preserving git line history. | |
# (h/t https://devblogs.microsoft.com/oldnewthing/20190919-00/?p=102904) | |
mkdir quota/postgresqlqm | |
git mv quota/mysqlqm/mysql_quota.go quota/postgresqlqm/postgresql_quota.go | |
git mv quota/mysqlqm/mysql_quota_test.go quota/postgresqlqm/postgresql_quota_test.go | |
git mv quota/mysqlqm/quota_provider.go quota/postgresqlqm |
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 ( | |
"context" | |
"flag" | |
"fmt" | |
"math" | |
"os/signal" | |
"syscall" | |
"time" |
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
module gist.github.com/robstradling/363b54e979b879e0450cfa36e238cca6 | |
go 1.21.6 | |
require github.com/sijms/go-ora/v2 v2.8.9 |
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 ( | |
"context" | |
"database/sql" | |
"flag" | |
"fmt" | |
"os" | |
go_ora "github.com/sijms/go-ora/v2" |
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 ( | |
"database/sql" | |
"flag" | |
"fmt" | |
"os" | |
"time" | |
go_ora "github.com/sijms/go-ora/v2" |
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
WITH cas AS ( | |
SELECT cac.CA_ID | |
FROM ccadb_certificate cc | |
JOIN ca_certificate cac ON cc.CERTIFICATE_ID = cac.CERTIFICATE_ID | |
WHERE cc.INCLUDED_CERTIFICATE_OWNER IS NULL | |
EXCEPT | |
SELECT cac.CA_ID | |
FROM ccadb_certificate cc | |
JOIN ca_certificate cac ON cc.CERTIFICATE_ID = cac.CERTIFICATE_ID | |
GROUP BY cac.CA_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
package main |
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
module gist.github.com/robstradling/f8f8c04b73af72e7f137c1eedb523d15 | |
go 1.20 | |
require github.com/sijms/go-ora/v2 v2.7.21 |
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 ( | |
"crypto/x509/pkix" | |
"encoding/asn1" | |
"encoding/base64" | |
"encoding/pem" | |
"fmt" | |
"math/big" | |
"time" |
NewerOlder