Nice little library to do this is located at http://www.barcodelib.com/java_barcode/main.html… import com.barcodelib.barcode.*; public class MyBarCode { public static void main (String args[]) throws Exception { Linear barcode = new Linear(); barcode.setType(Linear.UPCA); java.util.Random r = new java.util.Random(); String str = new…
Managing F5 load balancers with the python bigsuds library
Connecting to a GTM from bigsuds import * b = BIGIP(hostname = ‘GTM_Name_orIP’, username = ‘your_username’, password = ‘your_password’) for pool in b.GlobalLB.Pool.get_list(): for member in b.GlobalLB.Pool.get_member([pool]): for i in range(len(member[0])): print “Pool =”, pool, \ “, IP”,member[i][‘member’][‘address’], \ “listens…
“Unable to find valid certification path to requested target” exception
In a JBOSS environment, the issue was the connector in the server.xml file is only used for *inbound* connections, not ones out from JBOSS to another SSL enabled service. If you compile and run the following test class below… [sa-jboss@cmhldecomecm01…
Birthday paradox in python
I love things like this. Earlier, we produced a working example of the Monte Hall problem. In this post, we show something similar for the birthday paradox… c:\Python27>type c:\Users\showard\bday.py from random import randint cnt = 0 for k in range(2000):…
Verifying an SSL certificate expiration with java
We came up with this as a one-off to alert us when a certificate was close to expiration (we were burned one too many times)… import java.net.*; import java.security.cert.*; import javax.net.ssl.*; public class GetCertDates { public static void main(String []…
Deleting in a loop in SQL Server
While discussing a way to delete many rows, but without deleting all of them at the same time (too much transaction logging), we came up with the following… This works pretty well. It’s faster to do it all at once,…