Programming Considerations

This topic describes some requirements for StreamInsight programming.

.NET Framework Versions

StreamInsight supports the .NET Framework 3.5 with Service Pack 1 and the .NET Framework 4 for application development.

If your application uses event sources or sinks that implement the IObservable or IObserver interfaces, the application must target .NET Framework 4 (not the .NET Framework 4 Client Profile). For more information, see Using Observable and Enumerable Event Sources and Event Sinks (StreamInsight).

StreamInsight Versions

When you install a new version of StreamInsight, the new version is installed side-by-side with previously installed versions. Applications and libraries that were compiled against previous versions continue to run without modification. After installing a new version of StreamInsight, you will observe the following changes on your computer:

  • The new assemblies are installed in a new folder in the file system. For example, C:\Program Files\Microsoft StreamInsight 1.1.

  • The new assemblies are installed side-by-side with the previously installed versions in the global assembly cache (GAC).

  • In Microsoft Visual Studio, you can develop against any of the installed versions of StreamInsight. The assemblies for each installed version appear in the Add Reference dialog box.

  • If you compile an application against a newer version of StreamInsight, the application will fail with an exception if you run it against an older version of StreamInsight.

  • At runtime, assembly references in applications or libraries compiled against a previous version are redirected to the newest version of the assemblies. To bypass this redirection, you can add information to the application’s configuration file to override the installed publisher policy. In the app.config for your StreamInsight application, specify <publisherPolicy apply="no" /> under the <configuration><runtime><assemblyBinding> tag. If those tags are not present, create them, as shown in the following example:

    …
        <configuration>
            <runtime>
                <assemblyBinding>
                     <publisherPolicy apply="no" />
                </assemblyBinding>
            </runtime>
        </configuration>
    …
    

    For more information, see the section “Bypassing Publisher Policy” in Redirecting Assembly Versions. If you choose to bypass assembly redirection, make sure that you bypass redirection for all StreamInsight assemblies.

For additional information, see “Installing a New Version of StreamInsight” in Installation (StreamInsight).

String Comparison in StreamInsight Metadata

When you pass the name of a StreamInsight object in a method call, the strings are compared by ordinal only, in a manner that ignores the culture. As a result, some strings may be identified as different by ordinal when in fact they are identical in the intended culture. This issue can occur when you are creating a new object or retrieving an existing object by using one of the following methods and properties: