Dimension 4 is “… the best time synchronization utility available today for Windows 95 and Windows NT 4.0..” I had been using AtomTime, but Dimension 4 has a ton more features.
All posts by ajohnson
WEB-INF directory security
Thanks to Maia for pointing out that my WEB-INF directory on karensrecipes.com and other jsp based sites was accessible.. I was under the (incorrect) impression that Tomcat didn’t allow requests to the WEB-INF directory by default, but apparently it’s something you have to setup in Apache, specifically:
<Location “/WEB-INF/”>
AllowOverride None
deny from all
</Location>
Covalent has an excellent support document on properly setting up your Apache and Tomcat installation.
Running stored procedure from the Query Analzyer
If you’ve ever wanted to run a stored procedure from the Query Analzyer, check out this MSDN article: Executing Stored Procedures in SQL Query Analyzer
Amazon.com Trivia
Amazon will pay you to learn about their site: Amazon.com Trivia
C# Plugin for Eclipse
Do you use C#? Don’t wanna shell out a grand for Visual Studio? Check out the Improve C# Plugin for Eclipse. Detailed setup instructions on Sys-Con.
On patent law and how the proliferation of patents granted by the USPTO is bad for society
Great article on Forbes.com on patent law and how the proliferation of patents granted by the USPTO is bad for society: “… too many patents are just as bad for society as too few. The undisciplined proliferation of patent grants puts vast sectors of the economy off-limits to competition, without any corresponding benefit to the public.” [source: slashdot.org]
The Slashdot piece was focused on a lawsuit brought by F5 Networks whose aim was to defend a patent on technology that “… improves the interaction of servers and desktop computers with Web browsers. Information such as shopping cart contents is often stored in files called “cookies” on desktop computers; F5 was awarded a patent that lets a Web traffic management device reunite a desktop computer with a particular server if the desktop computer user returns to the Web site.” They’re effectively saying that they own the technology that provides “sticky sessions”. I guess in an industry (software) where the barrier to entry is so low, patent law helps to brings the barriers up a notch or two. But seriously F5, how trivial is this technology? Your hardware device examines the HTTP stream, picks out the cookie and sends the user to the appropriate server. How long did it take to figure that out? 30 seconds? Innovation? No. I hope you all go to bed at night feeling like you made a contribution to the world.
J2EE Application Server matrix
Also on Serverside.com, an excellent J2EE Application Server matrix.
Are Java people the only ones talking about .NET?
From theserverside.com, “Are Java people the only ones talking about .NET?“: , “Last week, a Microsoft representative confirmed that Microsoft bCentral, which provides Web site hosting and services to small companies, lacks support for .NET. The main reason for the lack of support for .Net is that few of bCentral’s 15,000 customers have asked for it.“
.NET Flash Remoting: ASP.NET, ADO.NET, Webservices or Assemblies?
Spent some quality time with SQL Server 2000, .NET Assemblies, Flash Remoting and the DataGrid Component last night and this morning. My current project at work involves setting up a Flash client (which I won’t be writing), to talk to .NET via Flash Remoting. We’ll also be using ASP for other clients so the business logic that lives in multiple stored procedures on the database server can be accessed by both ASP and C#.
Anyway, last week I spent a couple hours getting up to speed on setting up .NET Remoting, specifically I wanted to know which .NET technology would be best suited to the job (you can use ADO.NET, ASP.NET pages, Web Services and Assemblies). If you download Flash Remoting for .NET and then install the Flash Remoting executable, you’ll get a subdirectory off of inetpub\wwwroot\ called ‘flashremoting’, which contains an example of the first three options mentioned above written in VB and C#. Long story short, using ADO.NET, ASP.NET pages or ASP Webservices didn’t strike me as the ‘best’. The ADO.NET version requires that you use register the flashgateway dll within your ASP.NET page like so:
<%@ Register TagPrefix=”Macromedia” Namespace=”FlashGateway” Assembly=”flashgateway” %>
and the code behind for the above page also is tightly coupled to Flash:
public class CustomerInfo : System.Web.UI.Page
{
//Define Objects needed for CustomerInto Class
protected FlashGateway.Flash Flash;
The ASP.NET page looks like this:
<%@ Register TagPrefix=”Macromedia” Namespace=”FlashGateway” Assembly=”flashgateway” %>
<%@ Page language=”c#” debug=”true” %>
This line is available only when the page is viewed through a web browser.
<Macromedia:Flash ID=”Flash” runat=”server”>
The Webservice example doesn’t presupposed it’s going to be used by Flash, which IMNSHO is a good thing. And while a Webservice is an excellent way of exposing your business logic to various non human clients, performance will never be as fast as a non-webservice call, which leaves us with Assemblies. Why didn’t Macromedia offer an Assembly example? 🙂
An assembly lives in the {applicationroot}/bin folder off your website and can be used by any other client. It doesn’t presuppose that it will be used with Flash (which means I have loose coupling of my apps and I can probably reuse this business logic anywhere else I want) and performance will be markedly better than a webservice (when not using the Flash Remoting client, which doesn’t *really* make a SOAP call to the Webservice). Anyway, for my own sake, here are my .NET Flash Remoting setup notes (which came from http://www.jasonmperry.com/articles/YahooQuoteTicker.aspx:
1) download and install .NET Flash Remoting
2) download and install Flash Remoting Components
3) copy the flashgateway.dll (which was probably installed into \inetpub\wwwroot\flashremoting\bin\) into the site you’re working on: \wwwroot\yourapplication\bin\
NOTE: /yourapplication/ must be marked as an ‘application’ within IIS
4) add
<httpModules>
<add name=”GatewayController” type=”FlashGateway.Controller.GatewayController,flashgateway” />
</httpModules>
to your web.config file in /yourapplication/
5) create an empty file called ‘gateway.aspx’ in /yourapplication/
<%@ Page %>
<!– This file is intentionally blank. –>
6) write your Assembly in C#/VB.NET, compile and then publish it to the /yourapplication/bin folder where it should be happily co-existing along w/ the flashgateway.dll file you copied to this folder in step 3.
7) Open up FlashMX, do your dee-sign thing and then include something like in the Flash movie:
#include “NetServices.as”
////////////////////////////////////////////
// Inits Web Service
////////////////////////////////////////////
//creates connection to ASP.Net web service
//should never ever run more than once!!
if( init == null )
{
//insures this code block is only run once
init = true;
// point flash to the flash remoting gateway
NetServices.setDefaultGatewayURL(“http://localhost/yourapplication/gateway.aspx”);
gatewayConnnection = NetServices.createGatewayConnection();
// register your service w/ flash, substituting com.packagename.Classname for the package and name of the C#/VB.NET class you wrote and have installed to /yourapplication/bin/
myService = gatewayConnnection.getService(“com.packagename.Classname”, this);
}
// call a method on the service you’re written
myService.getProducts();
….
Hope that helps someone!
Further resources:
Flash Remoting Docs: [source]
ASP.NET assemblies in Flash: [source]
Flash Remoting Sample Applications: [source]
Flash Remoting Development Center: [source] (where is the .NET category BTW? how about some more .NET examples MACR?!!?)
Viewing Flash Remoting log entries: Flash Remoting MX writes error messages to the flash.log file in the local assembly cache. You can change the log file settings in the Windows Registry. The Flash Remoting registry keys are located at HKEY_LOCAL_MACHINE\SOFTWARE\Macromedia\Flash Remoting\1\Registration.
TechTV and O ETECH
Rael was on TechTV w/ Cory Doctorow talking about the upcoming Oreilly Emerging Technology Conference. If you don’t have cable or your Tivo didn’t tape it, you can watch it online.