Monday, 8 November 2010

Smalltalk Useful

Smalltalk Start Settings

http://www.instantiations.com/docs/FAQ/wwhelp/wwhimpl/js/html/wwhelp.htm#href=va03001.html


[abt.exe] -sp:blparams.in -i icxFile -mo128000000 -mn2000000 -mf16000000 -ml80000000 -mi8000000



This option sets the size of the largest old space to XXXX bytes. The default is the size of the old space in the image when it was saved. In a newly packaged image, the default size is the actual byte size required by the image.





Tuesday, 12 October 2010

Monday, 27 September 2010

Useful GUI Mock Up Tools

Pretty cheap and ubiquitous
Also has hooks to confluence and jira - very good.

Free open source

Somore more good ones for jira / Confluence - diagrams in jira/confluence

Saturday, 25 September 2010

Grails & Cobertura Bug

Grails & Cobertura - Cobertura does not cover all classes even though there are tests

Found this by accident. It seems like uncompiled classes that are referenced in a Plugin.groovy script are not poperly instrumented when grails test-app --coverage is run.

However if you do "grails compile" then "grails test-app --coverage" everything then works

Wierd but useful to remember!

Wednesday, 9 June 2010

Useful Tools & Sites

SoapUI - www.soapui.org
Well handy for testing web services. Can import a WDSL and create a test suite.

Burp Suite
Java based proxy for HTTP(S) see what is being sent to a remote localation, manipulate it etc

WireShark
General Network Sniffing Tool - Handy when you aren't sure why a TCP connection is dropping

xSQL
Excellent tool for comparing 2 databases (SQL Server) to document schema differences

Hudson
Continuous Integration



http://www.javapractices.com
http://www.hibernate.org - ORM Mapping
http://www.springframework.org - IOC Server
http://www.quickserver.org/ - Multithreaded network apps
http://maven.apache.org - project building
http://www.theserverside.com - good  j2ee site
http://www.postgres.org - Opensource multiversioning database.  now supports windows
http://www.h2database.com/  Java based DB
http://www.myeclipse.org
http://www.jdocs.org
http://www.javalobby.org
http://cargo.codehaus.org - Container wrapper api.  makes it easier to start stop etc containers from ant

Friday, 29 May 2009

Open SSL

Command to generate a private key
genrsa -des3 -out [CertRoot]/private/privateKey.pem 1024

Command to generate a private key for a self signed cert
genrsa -des3 -out [CertRoot]/private/cAPrivateKey.pem 1024

Command to create a private key for Bank-Link

genrsa -out [CertRoot]/private/banklinkPrivate.pem 1024

Commands to create self seigned cert
req -new -x509 -keyout [CertRoot]/private/cAPrivateKey.pem -out [CertRoot]/ca/CACert.pem -config [CertRoot]/openssl.cnf -days[days]

req -new -x509 -key [CertRoot]/private/cAPrivateKey.pem -out [CertRoot]/ca/CACert.pem -config [CertRoot]/openssl.cnf -days [days]

Command to create a certificate request
req -new -key [CertRoot]/private/privateKey.pem -out [CertRoot]/cert.csr

Command to sign a server certiciate request
x509 -req -in [CertRoot]/cert.csr -CA [CertRoot]/ca/CACert.pem -CAkey [CertRoot]/private/CAPrivateKey.pem -CAserial [CertRoot]/serial -out [CertRoot]/cert.pem -days [days]

ca -policy policy_anything -config [CertRoot]/openssl.cnf -cert [CertRoot]/ca/CACert.pem -keyfile [CertRoot]/private/CAPrivateKey.pem -in [CertRoot]/cert.csr -out [CertRoot]/cert.pem -days [days]

Command to convert a PKCS#12 file to .pem format
openssl pkcs12 -in banklink.pfx -out banklink.pem -nodes

See also - To install cert in IIS
http://www.dylanbeattie.net/docs/openssl_iis_ssl_howto.html

See also - Free SSL supported by browsers
https://cert.startcom.org/

Thursday, 28 May 2009

SQL Server - Useful Stuff

To fix orphansed users.
Occurs when you force a db backup onto another instance on another server
------------------------------------------------------------------------------------------------
exec sp_change_users_login 'Auto_Fix', ''

To move data around

You can use SQL Server 2008 to move data into older databases


See where CPU is being used when CPU utilisation is high
---------------------------------------------------------------------
Select
signal_wait_time_ms=sum(signal_wait_time_ms)
, '%signal (cpu) waits' = cast(100.0 * sum(signal_wait_time_ms) / sum (wait_time_ms) as numeric(20,2))
, resource_wait_time_ms=sum(wait_time_ms - signal_wait_time_ms)
, '%resource waits'= cast(100.0 * sum(wait_time_ms - signal_wait_time_ms) / sum (wait_time_ms) as numeric(20,2))
From sys.dm_os_wait_stats


If % signal waits (i.e. time spent waiting for CPU to be free) is greater than 25%, then more CPUs / faster CPUs will help

if % resource waits is high then use the following to see what:
---------------------------------------------------------------------------
SELECT * FROM sys.dm_os_wait_stats

Before doing a check call the following to reset wait counters:
---------------------------------------------------------------------------
DBCC SQLPERF ('sys.dm_os_wait_stats', CLEAR)
How To Get Donmar Warehouse Tickets

Ten seats for every performance are released at 10.30 each morning; there are 20 spaces for standing. Then there are potential returns. If you are prepared to queue from 9.00 on Saturday you can usually get a ticket. Take a book, a coffee, chat to your fellow theatrephiles; it's a risk, but worth it.

Wednesday, 27 May 2009

MQ Series Useful Stuff

MQ Series

To connect to an MQ Series server

1) I
nstall MQ Client. Note that if you are on the same machine as the MQServer then the client should be installed using the server installation disks not eth client ones.

2) Set environment variable:
MQSERVER=[Channel]/[Protocol]/[HostName]([port])

[Channel] - Is the name of teh server connection channel that the client will use. The default vaue of
SYSTEM.DEF.SVRCONN is usually sufficient.

[Protocol] - The network prorocol to use to communicate with the server. the default value of TCP is usually used.

[HostName] - Is the remote MQ Server hostname or IP address

[Port] - Is the port for the QM manager process on the MQ server. Normally the default (1414) will do.

So, a vald string looks like:
MQSERVER=SYSTEM.DEF.SVRCONN/TCP/aHost(1414)

To check client connectivity

Use a test utility bundled with the client: (in bin directory)
amqscnxc -x [server name]([port])
e.g. amqscnxc -x 192.168.100.14(1414) -c DEFAULT.SERVER.CON QNAME
If you leave the params off it looks for vaklues in MQSERVER environment variable so its a good way to test that is set correctly.

If that doesn't exist, use amqsputc [QName] [QMName]
Should be able to enter some text that will appear as a meessage. Then [enter] to submit to server
This also uses MQ Client and MQSERVER environment variable

From Java
Note that the MQClient jars are in the folder:
[MQ Root Dir]\eclipse\plugins\com.ibm.mq.runtime_7.0.0.1

E.g.:
C:\Program Files\IBM\WebSphere MQ\eclipse\plugins\com.ibm.mq.runtime_7.0.0.1

More info
http://www3.sympatico.ca/n.rieck/docs/mqseries_client_on_openvms.html

Using JMS to connect Java to MQ:
http://www.devx.com/Java/Article/40866/1954?pf=true

http://hursleyonwmq.wordpress.com/2007/05/29/simplest-sample-applications-using-websphere-
mq-jms/


http://www.academictutorials.com/jms/jsm-mqseries.asp


MQBooks:
http://www-01.ibm.com/software/integration/wmq/library/crossplatform_books.html

Wednesday, 22 October 2008

I'm fed up with keeping my life organised in multiple different places and machines. I kinda like using delicious for bookmarks, but mostly having added a bookmark I rarely go back to it.

So I thought i'd try moving my musings onto a blog as well.

I've never really been the sort to write a diary. So not sure how long this will last. Last time I tried I posted one message in 2004, and then didn't go back, so I'm not holding my breath at this point. Still we'll see...

Now all I have to do is trawl through all my archived stuff, decide what is interesting and what isn't and go from there....