Windows 2008 SMTP Logging

Requires that you install the ODBC logging module.  This is done via the server manager.  You need to the “ODBC Logging” Role Service for IIS.

image

Technorati Tags: ,,
1. September 2010 06:31 by Danny Gershman | Comments (0) | Permalink

OData ListData.svc issues on Sharepoint 2010

After deciding that I wanted to query the much reveled OData services offered by Sharepoint 2010 I ran into multiple issues (now which I’ve resolved).

This is the service endpoint

http://<hostname>/_vti_bin/ListData.svc

1) OData services do not work over HTTPS.  I’m assuming this is related to configuration of WCF.  This is a key point to remember. 

2) Installing of the ADO.NET Data Services v1.5 CTP2 on the Sharepoint 2010 Server.  Do an IISRESET or reboot after this.

3) Ensure that there are no corrupt lists on a site.  If there are you’ll be able to hit a specific list but not hit the endpoint.  You’ll keep getting prompted with the NTLM/Keberos login from your web browser and never get logged in.  To remove a corrupted list (mine happened from upgrading from Sharepoint 2007 to Sharepoint 2010 without installing custom list types), run the following command from the Sharepoint Powershell Prompt (thanks to Harold van de Kamp’s blog entry on this one.)

stsadm.exe -o forcedeletelist -url <url>

 

Technorati Tags: ,,,

 

18. August 2010 08:17 by Danny Gershman | Comments (0) | Permalink

Fiddler debugging a non-browser XMLHTTP application

Fiddler is an excellent application for observing and debugging internet traffic.  However I wanted to be able to monitor some non-browser traffic.  In this particular case a piece of VB code.  Here’s how I did it.  I have my simple XMLHTTP request here.

 
Set x = New ServerXMLHTTP60
Call x.Open("GET", "http://www.bing.com/", True)
x.Send()

So essentially I need some way to pass this request to a proxy server.  Fiddler “listens” on localhost port 8888.  Here is the final code with the modification to pass the request through Fiddler.

 
Set x = New ServerXMLHTTP60
Call x.Open("GET", "http://www.bing.com/", True)
Call x.setProxy(2, "127.0.0.1:8888")
x.Send()

You can also redirect all traffic from WinINET to Fiddler to, I thought this was a more granular way to control this.

1. August 2010 05:47 by Danny Gershman | Comments (0) | Permalink

Stopping a stuck in “Starting” Sharepoint service

A sharepoint service as defined by Sharepoint 2010 is not your typical “run-of-mill” service.  You can’t simply go to the Windows Service snap-in (commonly referred by sysops as services.msc), and hit Stop or Restart.

You’ll need to fire up the Sharepoint 2010 Management Shell.  You might need to logged into the box as a Farm Administrator.  Run the command:

Get-SPServiceInstance.   Locate the GUID, and then run.

Stop-SPServiceInstance <GUID>

Select ‘Y’ to stop it.  You should be able to refresh the Central Administration > Services on Server dashboard and see the respective service is stopped.

Technorati Tags: ,,

29. July 2010 07:32 by Danny Gershman | Comments (0) | Permalink

Running NetBeans developed Java JAR on OS/X

I ran into some issues yesterday when trying to deploy an application that I developed in NetBeans.  I’m using the forms designer feature of NetBeans 6.9 which utilizes Swing controls.  Its very nice I might add, however I did receive a warning message that Swing will no longer be updated going forward, so I’m going to have to consider doing the next one in the “Application Platform” that is recommended.

There were a couple of things I needed to do to get this application to work on OS/X.  First is to install JDK1.5 Update 14.  Apple has their own version of Java, that they distribute and maintain.  As of this blog post, JRE1.5 R10, is the highest it goes.  So we will need to compile against 1.5 instead of 1.6 that is the default JDK that gets installed with NetBeans 6.9. 

I downloaded JDK1.5 by searching for it on Google.  After installing it, you need to explicitly add it to your Platforms in NetBeans.  See below.

On the NetBeans menubar click Tools, then Java Platforms.  A dialog window will appear. 

image

Click Add Platform… Browse to your Program Files directory on Windows and then Java.  (usually C:\Program Files\Java).  There you should see the JDK1.5 folder.

image

Select it and click Next >.  On the next screen, give it a name and target the source.  You may want the Javadoc too, which you need to download from Sun’s site.

image

Now you’ll be able to compile against JDK1.5.  The next step is to ensure that your compiling against the correct Swing implementation.  In the form designer select one of your forms, as seen below.  Notice the properties window, and the Layout Generation Style property.

image

Make sure that it says Swing Layout Extensions Library and NOT Standard Java 6 Code. 

The final difficulty I had was with reading a text file.  Line delimiter characters vary from platform to platform.  I had hard code to parse on “\r\n”.  A safer way to do this is to use: System.getProperty("line.separator").  A much safer way to code up.

 

Technorati Tags: ,,
21. July 2010 20:46 by Danny Gershman | Comments (0) | Permalink

COM+ subsystem log duplicate suppressing disabling

COM+ will by default disable multiple duplication of log entries.  This it the error message you will receive in the Window Application Event Log

image 

Do the above to enable logs.

Technorati Tags: ,,
18. June 2010 07:40 by Danny Gershman | Comments (0) | Permalink

Simulating POST with Fiddler

Sometimes its useful to simulate POST action on a WebForm or a Webservice in ASP.NET for debugging.  Fortunately Fiddler allows you to compose (construct) such a request.  First thing to do is fire up Fiddler.  Jump to the “Request Builder” tab.

image

From the drop down, select “POST”.  Put the URL you are testing in the textbox.  The other thing to input is in the “Request Headers” field which is to let the receiving page that form data is being passed.  “Content-type: application/x-www-form-urlencoded”

image

The final piece of data is the key value pairs of the data to be passed.  Make sure these values are URL encoded.  Put this in the “Request Body” field.

image 

One setting to change is to ensure that request will be automatically tracked.  Switch to the option tab, as ensure “Inspect Session” is checked.

image

Click “Execute” to fire off the request.  This can be really useful if you need to debug something.  Make sure your ASP.NET development server is running.  In this case mine is running on localhost, port 8080.  Set your breakpoint in Visual Studio and then fire off the request.  Then the breakpoint will catch and you can step through.  This is a great way to test different variations of data POSTs.

Technorati Tags: ,,,,
6. May 2010 07:40 by Danny Gershman | Comments (3) | Permalink

Perfmon Counters for Measuring Bandwidth

Works well, measured in bytes.

image

Technorati Tags: ,,

31. March 2010 18:32 by Danny Gershman | Comments (0) | Permalink

Debug VBScript in EditPlus

See the below screenshot for configuring.

image

Technorati Tags: ,
3. December 2009 11:35 by Danny Gershman | Comments (0) | Permalink

Poison Cookies

I thought I coined the term, but it exists already

http://www.testingreflections.com/node/view/3701

18. September 2009 03:55 by Danny Gershman | Comments (2) | Permalink

About dannyg

dannyg has been writing software for the last 12+ years and worked with various languages and programs.  He specializes business process automation, versatile solutions and R&D.