GithubHelp home page GithubHelp logo

spring-projects / spring-net Goto Github PK

View Code? Open in Web Editor NEW
834.0 141.0 370.0 118.75 MB

Spring Framework for .NET

Home Page: http://www.springframework.net

License: Apache License 2.0

PowerShell 0.07% XSLT 0.27% HTML 0.73% C# 95.80% GAP 0.08% Smalltalk 0.47% Batchfile 0.05% TSQL 0.03% Rich Text Format 2.05% Visual Basic .NET 0.01% ASP.NET 0.09% Shell 0.02% TypeScript 0.15% SCSS 0.10% CSS 0.08%

spring-net's Introduction

Build

THE SPRING.NET FRAMEWORK

http://www.springframework.net/

INTRODUCTION

Spring.NET contains:

  • A full featured Inversion of Control container
  • An Aspect Oriented Programming framework
  • Expression Language for lightweight scripting
  • UI-agnostic validation framework
  • ASP.NET Framework
    • Dependency Injection for pages and user controls, bi-directional data binding, and more.
  • ASP.NET MVC and ASP.NET WebAPI Framework
    • Dependency Injection for MVC (includin WebAPI).
  • Declarative transaction management abstraction
    • Declarative transaction management via use of common XML configuration and attributes across different transaction APIs
  • ADO.NET framework
    • Simplifies use of ADO.NET. DAO support classes and integration with Spring's declarative transaction management functionality
  • Portable Service Abstractions
    • Export plain .NET objects via .NET Remoting, Web Service or .NET Serviced Component and create client side proxies based on endpoint URL and service interface.
  • NHibernate Integation
    • NHibernate 5 integration to simplify use of NHibernate and participate in Spring's declarative transaction management functionality.
  • ASP.NET AJAX Integration
    • Exporter to expose plain object on which Dependency Injection and AOP have been applied to JavaScript.
  • NUnit and MSTest integration
    • Provides Dependency Injection of test cases and Spring container loading and caching. . Data access and transaction management features aid with integration testing.
  • WCF integration
    • Provides Dependency Injection and applicatin of AOP advice to WCF services
  • Quartz integration
    • Configure Quartz jobs using dependency injection and Spring's transactional support to persist job details
  • MSMQ integration
    • Simplifies the use MSMQ by providing helper classes for message sending and receiving. Integrates with Spring's transaction management features.
  • NMS integration
    • Simplifies the use of NMS by providing helper classes for message sending and receiving.
  • TIBCO EMS integration
    • Simplifies the use of TIBCO EMS by providing helper classes for message sending and receiving.
  • NVelocity integration
    • Simplifies the use of configuring NVelocity

Spring.NET is a port of the Java based Spring Framework. In turn, the Java/J2EE Spring Framework is based on code published in "Expert One-on-One J2EE Design and Development" by Rod Johnson (Wrox, 2002).

SUPPORTED .NET FRAMEWORK VERSIONS

Spring.NET 3.0.0 supports .NET 4.6.2 and .NET Standard 2.0 and later.

KNOWN ISSUES

RELEASE INFO

Release contents:

  • src contains the C# source files for the framework
  • test contains the C# source files for Spring.NET's test suite
  • bin contains various Spring.NET distribution dll files
  • lib/Net contains shared third-party libraries needed for building the framework
  • doc contains reference documentation, MSDN-style API help, and the Spring.NET xsd.
  • examples contains sample applications.
  • build-support contains additonal applications need to build using NAnt as some convenience VS.NET solution files.
  • dev-support contains 'developer support' tools and code, such as solution templates for VS.NET

debug build is done using /DEBUG:full and release build using /DEBUG:pdbonly flags.

The VS.NET solution for the framework and examples are provided.

Latest info is available at the public website: http://www.springframework.net/

The Spring Framework is released under the terms of the Apache Software License (see license.txt).

DISTRIBUTION DLLs

The "bin" directory contains the following distinct dll files for use in applications. Dependencies are those other than on the .NET BCL.

  • Spring.Core (~765 KB) NuGet Downloads

    • Contents: Inversion of control container. Collection classes.
    • Dependencies: Common.Logging
  • Spring.Aop (~150 KB) NuGet Downloads

    • Contents: Abstract Oriented Programming Framework.
    • Dependencies: Spring.Core, Common.Logging
  • Spring.Data (~320 KB) NuGet Downloads

    • Contents: Transaction and ADO.NET Framework.
    • Dependencies: Spring.Core, Spring.Aop
  • Spring.Data.NHibernate5 (~90 KB) NuGet Downloads

    • Contents: NHibernate 5.x integration
    • Dependencies: Spring.Core, Spring.Aop, Spring.Data, NHibernate
  • Spring.Services (~70 KB) NuGet Downloads

    • Contents: Web Services, Remoting, and Enterprise Component based services.
    • Dependencies: Spring.Core, Spring.Aop
  • Spring.Web (~165 KB) NuGet Downloads

    • Contents: ASP.NET based Web Application Framework.
    • Dependencies: Spring.Core, Spring.Aop
  • Spring.Web.Extensions (~8 KB) NuGet Downloads

    • Contents: ASP.NET AJAX Integartion
    • Dependencies: Spring.Core, Spring.Aop, System.Web.Extensions
  • Spring.Web.Mvc5 (~8 KB) NuGet Downloads

    • Contents: ASP.NET MVC5 and WebAPI Integartion
    • Dependencies: Spring.Core, Spring.Web
  • Spring.Testing.NUnit (~24 KB) NuGet Downloads

    • Contents: NUnit Integration
    • Dependencies: Spring.Core, Spring.Data, NUnit
  • Spring.Testing.Microsoft (~24 KB) NuGet Downloads

    • Contents: MSTest Integration
    • Dependencies: Spring.Core, Spring.Data, MSTest
  • Spring.Messaging (~65 KB) NuGet Downloads

    • Contents: MSMQ Integration
    • Dependencies: Spring.Core, Spring.Data, System.Messaging
  • Spring.Messaging.Nms (~100 KB) NuGet Downloads

    • Contents: NMS Integration
    • Dependencies: Spring.Core, Spring.Data, Apache NMS
  • Spring.Scheduling.Quartz3 (~44 KB) NuGet Downloads

    • Contents: Quartz32.x Integration
    • Dependencies: Spring.Core, Spring.Data, Quartz
  • Spring.Template.Velocity (~44 KB) NuGet Downloads

    • Contents: NVelocity Integration
    • Dependencies: Spring.Core, NVelocity

WHERE TO START?

Documentation can be found in the "docs" directory:

  • The Spring reference documentation

Documented sample applications can be found in "examples":

  • IoCQuickStart.MovieFinder - A simple example demonstrating basic IoC container behavior.
  • IoCQuickStart.AppContext - Show use of various IApplicationContext features.
  • IoCQuickStart.EventRegistry - Show use of loosely coupled eventing features.
  • AopQuickStart - Show use of AOP features.
  • CachingQuickStart - Show use of Caching abstraction.
  • SpringAir - Show use of Spring.Web features.
  • Calculator - Show use of Spring.Services features.
  • WebQuickStart - Show step by step usage of Spring.Web features.
  • Web.Extensions.Example - Show ASP.NET AJAX integartion.
  • DataQuickStart - Show use of Spring.Data data access features.
  • TxQuickStart - Show use of Spring's transaction features.
  • Data.NHibernate.Northwind - Show use of Spring's NHibernate features.
  • WCFQuickStart - Show use of DI and AOP with WCF
  • NMSQuickStart - Sample application using NMS
  • MSMQ QuickStart - Sample application using MSMQ
  • Quartz Example - Scheduling using Quartz
  • Mvc5QuickStart - Show the configuration of the ASP.NET MVC 5 support

How to build

VS.NET

Visual Studio 2022 is required to open and build the solution. The free community version of Visual Studio should suffice.

Acknowledgements

InnovaSys Document X!

InnovSys has kindly provided a license to generate the SDK documentation and supporting utilities for integration with Visual Studio.

spring-net's People

Contributors

aaronmell avatar andreaskl avatar bbaia avatar chadsowald avatar cnemo7539 avatar dependabot[bot] avatar djechelon avatar eeichinger avatar ezbz avatar hailtondecastro avatar kamiff avatar kvr000 avatar lahma avatar lukeabsent avatar markpollack avatar mashbrno avatar michaelpearce-gain avatar norvegec avatar ohadho avatar rpaterlini avatar sbohlen avatar sean-gilliam avatar serra avatar thomast74 avatar thorstenbaek avatar tobi-tobsen avatar tureylab avatar twisterino avatar yhrn avatar ynauls avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

spring-net's Issues

Spring is not injecting adoTemplate into AbstractTransactionalDbProviderSpringContextTests

For the RC1, AdoTemplate is not getting injected automatically. I get the following exception when executing the test:
"Unsatisfied dependency expressed through object property 'AdoTemplate'"

I have resolved this by explicitly defining the AdoTemplate spring object in my context file.

But when I was using an earlier version of Spring(version 2.0.0.35000), I was not setting the AdoTemplate.

Are there any changes done in the new Spring version, which requires the AdoTemplate to be set explicitly?
Thanks.

Hierarchical Contexts broken by change to DefaultListableObjectFactory

It seems that as of M2, if you use VariablePlaceholderConfigurer in combination with any child context, your app is now broken. There is no work-around other than removing all child contexts or removing all VariablePlaceholderConfigurers.

[This][https://github.com/SpringSource/spring-net/blob/d8ff77d99941a2cf46e300c2f8dd080d58f7d18d/src/Spring/Spring.Core/Objects/Factory/Support/DefaultListableObjectFactory.cs] change to DefaultListableObjectFactory broke VariablePlaceholderConfigurer.

in VariablePlaceholderConfigurer.cs:

IList<string> objectDefinitionNames = factory.GetObjectDefinitionNames();
            for (int i = 0; i < objectDefinitionNames.Count; ++i)
            {
                string name = objectDefinitionNames[i];
                IObjectDefinition definition = factory.GetObjectDefinition( name );
                try
                {
                    visitor.VisitObjectDefinition( definition );

You can see that it uses GetObjectDefinitionNames() to list all of the definition names and then GetObjectDefinition() to get the definitions. GetObjectDefinitionNames() USED to only return definitions in the current context, but now it returns definitions in parent contexts as well. At a glance, I can't see why this was done, except it simplified (and I suppose obsoleted) ObjectFactoryUtils.ObjectNamesForTypeIncludingAncestors.

The problem now, though, is that there is no obvious way to retrieve the names of the definitions in the objectfactory without including the parents. A further problem seems to be that the related GetObjectDefinitionNames(Type type) method does NOT respect hierarchy, so now the two identically-named methods are very inconsistent in behaviour. And, of course, any code that behaves like the VariablePlaceholderConfigurer is now broken when using ancestor contexts.

My suggestions, in order of preference would be:

  1. Roll back the change to the behaviour of DefaultListableObjectFactory.GetObjectDefinitionNames() to the old one and add an overloaded method that takes a bool argument, just like GetObjectDefinition() does. Modify ObjectFactoryUtils.ObjectNamesForTypeIncludingAncestors to call the overloaded version. I do not yet know what other new code relies on the new behaviour of GetObjectDefinitionNames(), if any.
  2. Modify VariablePlaceholderConfigurer to ignore null values returned from GetObjectDefinition(). (Obviously this is probably a terrible idea).

I'm going to assume that the first option is the way to go, examine any calls to GetObjectDefinitionNames and make sure that none of them rely on the new behaviour. I would write a test that demonstrates the broken behaviour, but I'm not sure if it's even possible to construct a parent/child context with the integration test support, which is what's required in order to demonstrate the problem.

EDIT:

I've found the following additional code that will break if using the >=M2 version of DefaultListableObjectFactory:

ConfigurationClassPostProcessors.EnhanceConfigurationClasses: NRE on line 133
PropertyPlaceholderConfigurer.ProcessProperties: NRE within call on line 243
VariablePlaceholderConfigurer.ProcessProperties: NRE within call on line 256

Another question now presents itself:
Is it necessary to change the IConfigurableListableObjectFactory interface to provide the option of including ancestors? Is it necessary to modify GetObjectNamesForType and related methods to include those options? All of those methods call GetObjectDefinitionNames() and therefore now all behave differently than they used to, though it's reasonable to assume that the old behaviour was incorrect in some cases, especially since DoGetObjectNamesForType explicitly requests object definitions from ancestors.

Considering all of this, it MIGHT actually be better at this point to modify the three above broken classes to ignore null returns from GetObjectDefinition() since otherwise the effects of fixing this are wider and harder to predict and test.

Incidentally, this does appear to demonstrate a weakness in the testing that can be done when working in child contexts.

Spring.NET 2.0 release

You guys mentioned months ago this was going to be released months. When is 2.0 targeted to be released officially and the Nuget package updated?

Next Version

Hi all, I want to know if there is any date for the next version Spring.net stable, thanks.

session/request scope incompatible with IDisposable

in RootWebObjectDefinition:

        public override bool IsSingleton
        {
            get
            {
                if (IsPage)
                {
                    return false;
                }
                else if (0 == string.Compare("application", this.Scope, true)
                    || 0 == string.Compare("session", this.Scope, true)
                    || 0 == string.Compare("request", this.Scope, true))
                {
                    return true;
                }
                else
                {
                    return base.IsSingleton;
                }
            }
            set { base.IsSingleton = value; }
        }

Because it considers session and request objects to be a singleton (rather than just NOT prototype scope) the AbstractObjectFactory registers them with the GLOBAL disposable objects. This is in addition to the WebObjectFactory maintaining its own incomplete IDisposable support that is session and request specific.

        protected void RegisterDisposableObjectIfNecessary(string name, object instance, RootObjectDefinition od)
        {
            if (od.IsSingleton && RequiresDestruction(instance, od))
            {
                // Register a DisposableObject implementation that performs all destruction
                // work for the given object: DestructionAwareObjectPostProcessors,
                // DisposableObject interface, custom destroy method.
                RegisterDisposableObject(name,
                        new DisposableObjectAdapter(instance, name, od, objectPostProcessors));

            }
        }

This results in the following exception in the SECOND request/session that creates that object:

System.ArgumentException was caught
  HResult=-2147024809
  Message=An item with the same key has already been added.
  Source=mscorlib
  StackTrace:
       at System.ThrowHelper.ThrowArgumentException(ExceptionResource resource)
       at System.Collections.Generic.Dictionary`2.Insert(TKey key, TValue value, Boolean add)
       at System.Collections.Generic.Dictionary`2.Add(TKey key, TValue value)
       at Spring.Objects.Factory.Support.AbstractObjectFactory.RegisterDisposableObject(String objectName, IDisposable instance) in f:\bamboo-home\xml-data\build-dir\SPRNET-RELEASE-JOB1\src\Spring\Spring.Core\Objects\Factory\Support\AbstractObjectFactory.cs:line 2814
       at Spring.Objects.Factory.Support.AbstractObjectFactory.RegisterDisposableObjectIfNecessary(String name, Object instance, RootObjectDefinition od) in f:\bamboo-home\xml-data\build-dir\SPRNET-RELEASE-JOB1\src\Spring\Spring.Core\Objects\Factory\Support\AbstractObjectFactory.cs:line 2352
       at Spring.Objects.Factory.Support.AbstractObjectFactory.GetObjectInternal(String name, Type requiredType, Object[] arguments, Boolean suppressConfigure) in f:\bamboo-home\xml-data\build-dir\SPRNET-RELEASE-JOB1\src\Spring\Spring.Core\Objects\Factory\Support\AbstractObjectFactory.cs:line 2322
       at Spring.Objects.Factory.Support.AbstractObjectFactory.GetObject(String name) in f:\bamboo-home\xml-data\build-dir\SPRNET-RELEASE-JOB1\src\Spring\Spring.Core\Objects\Factory\Support\AbstractObjectFactory.cs:line 2013
       at Spring.Objects.Factory.Config.ObjectFactoryCreatingFactoryObject.GenericObjectFactory.GetObject() in f:\bamboo-home\xml-data\build-dir\SPRNET-RELEASE-JOB1\src\Spring\Spring.Core\Objects\Factory\Config\ObjectFactoryCreatingFactoryObject.cs:line 173
...

I have yet to investigate if changing RootWebObjectDefinition to return false from IsSingleton for session and request objects would have unintended side-effects, but the combination of request/session scope and IDisposable is most certainly completely broken right now. This is puzzling how this could happen, since WebObjectFactory has explicit support for calling Dispose() on IDisposable objects so obviously it was intended to be supported.

The method names and comments DO indicate that request and session scoped objects are intended to be considered 'singletons', so perhaps the correct fix is not to change RootWebObjectDefinition, but instead to change AbstractObjectFactory to not check IsSingleton of the object definition before adding it to the global disposables, but instead to check if the definition's Scope is SCOPE_SINGLETON. This would, however, break disposing of objects that were explicitly defined as having 'application' scope, but since application scope and singleton scope behave identically (according to the docs, at least) I don't see why an explicit application scope couldn't just be rewritten as SCOPE_SINGLETON.

Because RegisterDisposableObjectIfNecessary is not virtual and there are 3 major subclasses of AbstractObjectFactory, I have no real way to fix this other than forking my own version of Spring, or a horribly brutal hack that I won't even describe here.

Can't use "AbstractTransactionalDbProviderSpringContextTests" after SPRNET-CODECONFIG. merge.

Before this commit (SPRNET-1536 merge code and tests from SPRNET-CODECONFIG project) everything was going well, now my application can not perform the tests.

The error is this: "Additional information: Error creating context 'spring.root': Element 'http://www.springframework.net/context:code-config' was not declared."

As always I followed the instructions from this site: http://www.springframework.net/codeconfig/refdoc/sample-apps.html#sample-mvc-codeconfig

Please help me, I love Spring.NET project, thank you.

--sorry for bad English.

Make ExpressionParser public to allow, for example, expression formatting

I'm using Spring.Core on my c# project, and the final user writes its scripts using the Expression language. A nice addition i want to provide is being able to "nice format" this scripts (indentation, new lines etc...) to make all expressions look nice and well formatted (a really big script can be confusing if not well formatted)

I think the best way to make this is use the ExpressionParser / (or lexer, i dont know exactly yet...) to get "the expression tree" from the text string, and then insert indentation, spaces, new lines, etc according to each tree node type (conditionals, sequences, etc)

As ExpressionParser is private, i cant acces it directly to achieve that. So that is why i'm propossing to make that class public.

Spring.Net MVC 5 + Razor Generator + Object Scope Request

Hello!

I'm trying to use Spring.Net MVC 5 + Razor Generator + Object Scope Request (single by request), but when I try to send a request to my Controller I receive a error asking me to add < add name="Spring" type="Spring.Context.Support.WebSupportModule, Spring.Web" /> in < modules >. After that I receive another error described bellow at application start up. Could anyone help me to figure out this problem?

Error:

The layout page "{...}.cshtml" could not be found at the following path: "~/Views/Shared/{...}.cshtml".

Stack Trace:

[HttpException (0x80004005): The layout page "/Views/Shared/{...}.cshtml" could not be found at the following path: "/Views/Shared/{...}.cshtml".]
System.Web.WebPages.WebPageExecutingBase.NormalizeLayoutPagePath(String layoutPagePath) +227
System.Web.WebPages.WebPageBase.PopContext() +85
System.Web.Mvc.ViewResultBase.ExecuteResult(ControllerContext context) +380
System.Web.Mvc.ControllerActionInvoker.InvokeActionResultFilterRecursive(IList1 filters, Int32 filterIndex, ResultExecutingContext preContext, ControllerContext controllerContext, ActionResult actionResult) +109 System.Web.Mvc.ControllerActionInvoker.InvokeActionResultFilterRecursive(IList1 filters, Int32 filterIndex, ResultExecutingContext preContext, ControllerContext controllerContext, ActionResult actionResult) +890
System.Web.Mvc.ControllerActionInvoker.InvokeActionResultWithFilters(ControllerContext controllerContext, IList1 filters, ActionResult actionResult) +97 System.Web.Mvc.Async.<>c__DisplayClass21.<BeginInvokeAction>b__1e(IAsyncResult asyncResult) +241 System.Web.Mvc.Controller.<BeginExecuteCore>b__1d(IAsyncResult asyncResult, ExecuteCoreState innerState) +29 System.Web.Mvc.Async.WrappedAsyncVoid1.CallEndDelegate(IAsyncResult asyncResult) +111
System.Web.Mvc.Controller.EndExecuteCore(IAsyncResult asyncResult) +53
System.Web.Mvc.Async.WrappedAsyncVoid1.CallEndDelegate(IAsyncResult asyncResult) +19 System.Web.Mvc.MvcHandler.<BeginProcessRequest>b__5(IAsyncResult asyncResult, ProcessRequestState innerState) +51 System.Web.Mvc.Async.WrappedAsyncVoid1.CallEndDelegate(IAsyncResult asyncResult) +111
System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +606
System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +288

Spring.Template.Velocity depending on the outdated Apache NVelocity

Since Castle Project forked their own version of NVelocity which is more maintained than the old dead NVelocity, and supposing their APIs are equal if not even exactly the same, I suggest one of the two options:

  • Switching from NVelocity to Castle Velocity
  • Forking a new Spring.Template.Velocity.Castle with support for Castle Velocity

I have not yet used Spring.net and Velocity but I'll be doing it soon.
What do you think about it? I think in the next weeks I could try one of the two options by myself on Spring code. Meanwhile I tried, out of curiosity, to fork Spring and switch from NVelocity to Castle: all tests passed

djechelon@f806865

spring-net for mono Error

[System.Configuration.ConfigurationErrorsException]: Error creating context 'spring.root': An exception was thrown by the type initializer for Spring.Context.Support.WebApplicationContext
at Spring.Context.Support.ContextHandler.Create (System.Object parent, System.Object configContext, System.Xml.XmlNode section) [0x00000] in :0
at System.Configuration.ConfigurationSection.GetRuntimeObject () [0x00000] in :0
at System.Web.Configuration.WebConfigurationManager.GetSection (System.String sectionName, System.String path, System.Web.HttpContext context) [0x00000] in :0
at System.Web.Configuration.WebConfigurationManager.GetSection (System.String sectionName) [0x00000] in :0
at System.Web.Configuration.HttpConfigurationSystem.System.Configuration.Internal.IInternalConfigSystem.GetSection (System.String configKey) [0x00000] in :0
at System.Configuration.ConfigurationManager.GetSection (System.String sectionName) [0x00000] in :0
at Spring.Util.ConfigurationUtils.GetSection (System.String sectionName) [0x00000] in :0

[System.TypeInitializationException]: An exception was thrown by the type initializer for Spring.Context.Support.WebApplicationContext
at (wrapper dynamic-method) object:_dynamic_Spring.Context.Support.WebApplicationContext..ctor (object[])
at Spring.Reflection.Dynamic.SafeConstructor.Invoke (System.Object[] arguments) [0x00000] in :0
at Spring.Context.Support.ContextHandler+RootContextInstantiator.InvokeContextConstructor (System.Reflection.ConstructorInfo ctor) [0x00000] in :0
at Spring.Context.Support.ContextHandler+ContextInstantiator.InstantiateContext () [0x00000] in :0
at Spring.Context.Support.ContextHandler.InstantiateContext (IApplicationContext parentContext, System.Object configContext, System.String contextName, System.Type contextType, Boolean caseSensitive, IList1 resources) [0x00000] in <filename unknown>:0 at Spring.Context.Support.WebContextHandler.InstantiateContext (IApplicationContext parent, System.Object configContext, System.String contextName, System.Type contextType, Boolean caseSensitive, IList1 resources) [0x00000] in :0
at Spring.Context.Support.ContextHandler.Create (System.Object parent, System.Object configContext, System.Xml.XmlNode section) [0x00000] in :0

[System.NullReferenceException]: Object reference not set to an instance of an object
at Spring.Context.Support.WebApplicationContext..cctor () [0x00000] in :0

Unit Tests failing for .NET 4.0

For the .NET 4.0 build for the RC1 code, the following tests are failing in Spring.Core.Tests.2010:

Spring.Globalization.Formatters.CurrencyFormatterTests
-FormatUsingCustomSettings
-FormatUsingDefaults
-ParseUsingCustomSettings
-ParseUsingDefaults
Spring.Globalization.Formatters.DateTimeFormatterTests
-FormatUsingDefaults
-ParseUsingDefaults

I have verified on my machine commented these tests out on my machine and the build completes successfully. I haven't attempted to fix them because some of the assertions have funny characters in them and I'm not sure what's required there.

Also I'm not sure if this is machine specific. It's possible there are issues with my environment. However, I have compiled the milestone versions in the past with no issues.

Build log extract is included below.

        test:


        common.run-tests:


        common.run-tests.nunit:

             [echo] Unit Testing Spring.NET, Spring.Core.Tests in C:\devenv\spring-net-spring-net-2.0.0-RC1/build/net/4.0/debug
             [exec] Starting 'C:\devenv\spring-net-spring-net-2.0.0-RC1/packages/NUnit.Runners.2.6.1/tools/nunit-console-x86.exe (Spring.Core.Tests.dll /xml:Spring.Core.Tests.dll-TestResults.xml /framework:net-4.0 /nologo /noshadow)' in 'C:\devenv\spring-net-spring-net-2.0.0-RC1\build\net\4.0\debug'
             [exec] ProcessModel: Default    DomainUsage: Single
             [exec] Execution Runtime: net-4.0
             [exec] ...........................................................................................................................................................................................................................................................................Source      : Spring.Context.Events.ConsoleListenerTests
             [exec] Event fired : 7/03/2014 12:34:02 PM
             [exec] ........................................................................................................................N.........................................N.......post process Spring.Objects.TestObject#91FC31
             [exec] ...Spring.Context.Support.XmlApplicationContextTests+DestroyTester
             [exec] ............................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................F.F..F.F...F..F..................................................................................................................................................................................................................................................................................................................................................................................................init factory
             [exec] .N............................................N........................N............................................................................DisposableClass.Dispose()
             [exec] .N......N..............................................................................................................................N.......................................................................................................N...........................................................................................................................................................................N..N............................N....................................................................................................N....N........................................................................................................................N...................N.N........N................N.N..............................................................................................................................................................................................................................................................................................................................................................................................................................................
             [exec] Tests run: 2666, Errors: 3, Failures: 3, Inconclusive: 0, Time: 20.8386908 seconds
             [exec]   Not run: 20, Invalid: 0, Ignored: 20, Skipped: 0
             [exec] 
             [exec] Errors and Failures:
             [exec] 1) Test Failure : Spring.Globalization.Formatters.CurrencyFormatterTests.FormatUsingCustomSettings
             [exec]      String lengths are both 14. Strings differ at index 10.
             [exec]   Expected: "1'23'4,00 ???."
             [exec]   But was:  "1'23'4,00 ???."
             [exec]   ---------------------^
             [exec] 
             [exec] at Spring.Globalization.Formatters.CurrencyFormatterTests.FormatUsingCustomSettings() in c:\devenv\spring-net-spring-net-2.0.0-RC1\test\Spring\Spring.Core.Tests\Globalization\Formatters\CurrencyFormatterTests.cs:line 153
             [exec] 
             [exec] 2) Test Failure : Spring.Globalization.Formatters.CurrencyFormatterTests.FormatUsingDefaults
             [exec]      String lengths are both 13. Strings differ at index 9.
             [exec]   Expected: "1.234,00 din."
             [exec]   But was:  "1.234,00 Din."
             [exec]   --------------------^
             [exec] 
             [exec] at Spring.Globalization.Formatters.CurrencyFormatterTests.FormatUsingDefaults() in c:\devenv\spring-net-spring-net-2.0.0-RC1\test\Spring\Spring.Core.Tests\Globalization\Formatters\CurrencyFormatterTests.cs:line 69
             [exec] 
             [exec] 3) Test Error : Spring.Globalization.Formatters.CurrencyFormatterTests.ParseUsingCustomSettings
             [exec]    System.FormatException : Input string was not in a correct format.
             [exec]    at System.Number.ParseDouble(String value, NumberStyles options, NumberFormatInfo numfmt)
             [exec]    at System.Double.Parse(String s, NumberStyles style, IFormatProvider provider)
             [exec]    at Spring.Globalization.Formatters.CurrencyFormatter.Parse(String value) in c:\devenv\spring-net-spring-net-2.0.0-RC1\src\Spring\Spring.Core\Globalization\Formatters\CurrencyFormatter.cs:line 205
             [exec]    at Spring.Globalization.Formatters.CurrencyFormatterTests.ParseUsingCustomSettings() in c:\devenv\spring-net-spring-net-2.0.0-RC1\test\Spring\Spring.Core.Tests\Globalization\Formatters\CurrencyFormatterTests.cs:line 188
             [exec] 
             [exec] 4) Test Error : Spring.Globalization.Formatters.CurrencyFormatterTests.ParseUsingDefaults
             [exec]    System.FormatException : Input string was not in a correct format.
             [exec]    at System.Number.ParseDouble(String value, NumberStyles options, NumberFormatInfo numfmt)
             [exec]    at System.Double.Parse(String s, NumberStyles style, IFormatProvider provider)
             [exec]    at Spring.Globalization.Formatters.CurrencyFormatter.Parse(String value) in c:\devenv\spring-net-spring-net-2.0.0-RC1\src\Spring\Spring.Core\Globalization\Formatters\CurrencyFormatter.cs:line 205
             [exec]    at Spring.Globalization.Formatters.CurrencyFormatterTests.ParseUsingDefaults() in c:\devenv\spring-net-spring-net-2.0.0-RC1\test\Spring\Spring.Core.Tests\Globalization\Formatters\CurrencyFormatterTests.cs:line 104
             [exec] 
             [exec] 5) Test Failure : Spring.Globalization.Formatters.DateTimeFormatterTests.FormatUsingDefaults
             [exec]      Expected string length 16 but was 15. Strings differ at index 15.
             [exec]   Expected: "14. avgust 2004."
             [exec]   But was:  "14. avgust 2004"
             [exec]   --------------------------^
             [exec] 
             [exec] at Spring.Globalization.Formatters.DateTimeFormatterTests.FormatUsingDefaults() in c:\devenv\spring-net-spring-net-2.0.0-RC1\test\Spring\Spring.Core.Tests\Globalization\Formatters\DateTimeFormatterTests.cs:line 71
             [exec] 
             [exec] 6) Test Error : Spring.Globalization.Formatters.DateTimeFormatterTests.ParseUsingDefaults
             [exec]    System.FormatException : String was not recognized as a valid DateTime.
             [exec]    at System.DateTimeParse.ParseExact(String s, String format, DateTimeFormatInfo dtfi, DateTimeStyles style)
             [exec]    at System.DateTime.ParseExact(String s, String format, IFormatProvider provider, DateTimeStyles style)
             [exec]    at Spring.Globalization.Formatters.DateTimeFormatter.Parse(String value) in c:\devenv\spring-net-spring-net-2.0.0-RC1\src\Spring\Spring.Core\Globalization\Formatters\DateTimeFormatter.cs:line 116
             [exec]    at Spring.Globalization.Formatters.DateTimeFormatterTests.ParseUsingDefaults() in c:\devenv\spring-net-spring-net-2.0.0-RC1\test\Spring\Spring.Core.Tests\Globalization\Formatters\DateTimeFormatterTests.cs:line 100
             [exec] 
             [exec] 
             [exec] Tests Not Run:
             [exec] 1) Ignored : Spring.Context.Support.ResourceSetMessageSourceTests.GetNullResourceIn2PointOh
             [exec]    See SPRNET-246
             [exec] 2) Ignored : Spring.Context.Support.XmlApplicationContextTests.ContextWithInvalidLazyType
             [exec]    Need to add Spring.TypeLoadException
             [exec] 3) Ignored : Spring.Objects.Factory.DefaultListableObjectFactoryPerfTests.Test
             [exec] 4) Ignored : Spring.Objects.Factory.DefaultListableObjectFactoryTests.CreateObjectWithCtorArgsOnPrototypeOutOfOrderArgs
             [exec]    Ordering must now be strict when providing array of arguments for ctors
             [exec] 5) Ignored : Spring.Objects.Factory.DefaultListableObjectFactoryTests.GetObjectWithCtorArgsOnPrototypeOutOfOrderArgs
             [exec]    Ordering must now be strict when providing array of arguments for ctors
             [exec] 6) Ignored : Spring.Objects.Factory.SPRNET_1338.CanAvoidLockContentionDuringObjectFactoryDisposal
             [exec]    Test fails -- waiting for verification re: if bug exists in Java impl
             [exec] 7) Ignored : Spring.Objects.Factory.Support.AutowireUtilsTests.GetTypeDifferenceWeightWithMismatchedLengths
             [exec]    Investigate details of new type weight algorithm
             [exec] 8) Ignored : Spring.Objects.Factory.Xml.EventWiringTests.EventWiringInstanceSinkToPrototypeSource
             [exec]    SPRNET-21
             [exec] 9) Ignored : Spring.Objects.Factory.Xml.XmlObjectDefinitionReaderTests.AutoRegistersWellknownNamespaceParser
             [exec] 10) Ignored : Spring.Objects.ObjectWrapperTests.GetSetIndexerProperties
             [exec] 11) Ignored : Spring.Objects.ObjectWrapperTests.GetValueOfCustomIndexerProperty
             [exec] 12) Ignored : Spring.Objects.ObjectWrapperTests.SetIndexOutOfRangeFromListProperty
             [exec]    Addition of elements to the list via index that is out of range is not supported anymore.
             [exec] 13) Ignored : Spring.Pool.SimplePoolTests.PassivateBusyObjectsBeforeClose
             [exec]    Cannot figure out why this is failing?
             [exec] 14) Ignored : Spring.Pool.StessSimplePool.ScalingAgainstIncreasingNumberOfThreads
             [exec]    a try for a stress
             [exec] 15) Ignored : Spring.Reflection.Dynamic.DynamicFieldTests.CannotReadPrivateReadOnlyFieldIfNoReflectionPermission
             [exec]    TODO: this works as expected when run using TD.NET & R# (in VS2k8), but fails with nant/NET 2.0 ?!?
             [exec] 16) Ignored : Spring.Reflection.Dynamic.DynamicPropertyTests.BasePropertyTests.TestForRestrictiveGetter
             [exec]    test N/A anymore due to System.Reflection.Emit.DynamicMethod
             [exec] 17) Ignored : Spring.Reflection.Dynamic.DynamicPropertyTests.BasePropertyTests.TestForRestrictiveSetter
             [exec]    test N/A anymore due to System.Reflection.Emit.DynamicMethod
             [exec] 18) Ignored : Spring.Reflection.Dynamic.SafeFieldTests.DynamicFieldTests.CannotReadPrivateReadOnlyFieldIfNoReflectionPermission
             [exec]    TODO: this works as expected when run using TD.NET & R# (in VS2k8), but fails with nant/NET 2.0 ?!?
             [exec] 19) Ignored : Spring.Reflection.Dynamic.SafePropertyTests.BasePropertyTests.TestForRestrictiveGetter
             [exec]    test N/A anymore due to System.Reflection.Emit.DynamicMethod
             [exec] 20) Ignored : Spring.Reflection.Dynamic.SafePropertyTests.BasePropertyTests.TestForRestrictiveSetter
             [exec]    test N/A anymore due to System.Reflection.Emit.DynamicMethod
             [exec] 

        BUILD FAILED

        External Program Failed: C:\devenv\spring-net-spring-net-2.0.0-RC1/packages/NUnit.Runners.2.6.1/tools/nunit-console-x86.exe (return code was 6)

        Total time: 36.3 seconds.

Like operator and int64 not working together with HibernateTemplate

With an Oracle database table with a column named Data with type NUMBER(16,0) I could with old versions of Spring.Net and nHibernate write an HQL and use the like operator like done in regular SQL:

string query =
"from TD.Common.DataObject.TDDetectorFileInfo as info where info.Data like ?";
object[] values1= new object[1];
object[] values2 =new object[1];
values1[0] = "19911111000000"
values2[0] = "1991111100000%"
var res = HibernateTemplate.Find(query, values1);
var res2 = HibernateTemplate.Find(query, values2);

I expect to get the same result in res and res2 since the like operator in Oracle can be applied to numbers.

Using Spring.Net 2.0.1 and NHibernate4 I instead get an expection for the res2 call.
Inner exception text: "Failed to convert parameter value from a String to a Decimal."

Should use Release version instead of Debug version of OpenCover.

There appears to be a debug version of OpenCover into your repository. The debug version has a LOT of diagnostics, which can be viewed via DebugView, and is a lot, lot, lot slower than the release version.

I advise you to use supported release versions from OpenCover Downloads and only use debug versions if you are developing against opencover itself.

If you need silverlight support or have assemblies that use AllowPartiallyTrustedCallersAttribute (or similar) then the Beta 2.0.* might be worth a look as that version doesn't not mess with any permissions in order to instrument the target assemblies.

Common.Logging 3.0

Can't use common.logging 3.0 with these libraries since they haven't been compiled against them.

spring.net Error

I use it linux system it have some bug

context filename unkown but my write xml file is exist ,spring.net is not find
i use spring.net version 1.3.2 Environment linux system mono 3.2.5
can you tell me how to fix it

System.ArgumentException : The transaction specified for TransactionScope has a different IsolationLevel than the value requested for the scope.

After upgrading from 1.3.2 to 2.0-RC2, I am getting the following error:

Spring.Transaction.CannotCreateTransactionException : Transaction Scope failure on begin
System.ArgumentException : The transaction specified for TransactionScope has a different IsolationLevel than the value requested for the scope.
Parameter name: transactionOptions.IsolationLevel.

Sample code below.

public class Service1
{
    [Transaction(TransactionPropagation.Required)]
    public virtual void MethodWithRequired(TransferUserDto userToTransferDto)
    {
        Service2.MethodWithNotSuppored();
    }
}

public class Service2
{
    [Transaction(TransactionPropagation.NotSupported)]
    public virtual void MethodWithNotSuppored()
    {
        // do something, expecting to suspend current transaction
    }
}

I tried setting the isolation level for both Transaction attributes with no luck.

spring2.0GA error by mono-runtime

ex {System.TypeInitializationException: An exception was thrown by the type initializer for Spring.Context.Support.WebApplicationContext ---> System.NullReferenceException: Object reference not set to an instance of an object at Spring.Context.Support.WebApplicationContext..cctor () [0x0005f] in /home/mowan/code/spring/spring.Web/Context/Support/WebApplicationContext.cs:166 --- End of inner exception stack trace --- at (wrapper dynamic-method) object._dynamic_Spring.Context.Support.WebApplicationContext..ctor (object[]) <IL 0x00038, 0x0013c> at Spring.Reflection.Dynamic.SafeConstructor.Invoke (object[]) [0x00008] in /home/mowan/code/spring/spring.core/Reflection/Dynamic/DynamicConstructor.cs:113 at Spring.Context.Support.ContextHandler/RootContextInstantiator.InvokeContextConstructor (System.Reflection.ConstructorInfo) [0x0002d] in /home/mowan/code/spring/spring.core/Context/Support/ContextHandler.cs:562 at Spring.Context.Support.ContextHandler/ContextInstantiator.InstantiateContext () [0x00039] in /home/mowan/code/spring/spring.core/Context/Support/ContextHandler.cs:507 at Spring.Context.Support.ContextHandler.InstantiateContext (Spring.Context.IApplicationContext,object,string,System.Type,bool,System.Collections.Generic.IList1<string>) [0x0004d] in /home/mowan/code/spring/spring.core/Context/Support/ContextHandler.cs:350 at Spring.Context.Support.WebContextHandler.InstantiateContext (Spring.Context.IApplicationContext,object,string,System.Type,bool,System.Collections.Generic.IList1) [0x00078] in /home/mowan/code/spring/spring.Web/Context/Support/WebContextHandler.cs:123 at Spring.Context.Support.ContextHandler.Create (object,object,System.Xml.XmlNode) [0x000b9] in /home/mowan/code/spring/spring.core/Context/Support/ContextHandler.cs:288 } System.TypeInitializationException

Spring.Data.NHibernate4 shows dependency on NHibernate 3.3.1.4.000 using dotPeek

I am running into an error when programmatically loading an assembly that references Spring.Data.NHibernate4,

ERROR 
Could not load file or assembly 'NHibernate, Version=3.3.1.4000, Culture=neutral, PublicKeyToken=aa95f207798dfdb4' or one of its dependencies. The system cannot find the file specified.

Using JetBrains dotPeek shows NHibernate 3.3.1.4.0000 as a dependency for Spring.Data.NHibernate4

Next release

What is the plan to create another release and update the Nuget package? There are some useful fixes that have been committed.

System.InvalidCastException : Unable to cast object of type from CompositeAopProxy

Thank you, I am troubleshooting a proxy issue this time. I swapped my proxy factory class from NHibernate.ByteCode.Castle to Spring.Data.NHibernate4. NHibernate.ByteCode.Castle doesn't support having identical interface name in different namespaces. I can got passed this failure by swapping the factory to Spring.Data.NHibernate4, but now another unit test is failing when is trying to cast a CompositeAopProxy to the proxy type of the class (an interface). I tried using NHibernate.Initialize to initialize the proxy but no luck. any tips would be very helpful.

// changed from 
<entry key="proxyfactory.factory_class" value="NHibernate.ByteCode.Castle.ProxyFactoryFactory, NHibernate.ByteCode.Castle"/>

// to this
<entry key="proxyfactory.factory_class" value="Spring.Data.NHibernate.Bytecode.ProxyFactoryFactory, Spring.Data.NHibernate4"/>

// both interfaces ISquare and ICircle inherit from IShape, so it creates a composite AOP proxy of ISquare and ICircle,  
Both interfaces share a property called SomeProperty in my example. I ensured that the proxy belongs to an instance of type Square
System.InvalidCastException : Unable to cast object of type 'SomeNameSpace.Square' to type 'SomeNameSpace.ICircle'.
   at _dynamic_SomeNameSpace.ICircle.get_SomeProperty(Object,ย Object[])
   at Spring.Reflection.Dynamic.SafeMethod.Invoke(Objectย target,ย Object[]ย arguments)
   at Spring.Data.NHibernate.Bytecode.LazyInitializer.Invoke(IMethodInvocationย invocation)
   at Spring.Aop.Framework.AbstractMethodInvocation.Proceed()
   at Spring.Aop.Framework.DynamicProxy.AdvisedProxy.Invoke(Objectย proxy,ย Objectย target,ย Typeย targetType,ย MethodInfoย targetMethod,ย MethodInfoย proxyMethod,ย Object[]ย args,ย IListย interceptors)
   at CompositionAopProxy_4127a6f79e61431eb15f3b096c68144f.get_SomeProperty()

[TransactionAttribute] not working with async programming

Hi,

I have incidentally found that using AOP attributes with async programming might not as straightforward as it looks. Consider an example code (EF6 based, which works with Txes)

[Transaction(ReadOnly = true)]
public async Task<boolean> UserExists(string username){
    using (SomethingDbContext ctx = new SomethingDbContext(...)) {
        return ctx.Users.AnyAsync(x=> x.username == username);
    }
}

Invoking this method like await UserRepository.UserExists(someUserName); throws a DataException saying the transaction is closed, most likely because the effects of AOP Transaction happen before the actual Any method is executed.

Personally, I gave up aynchronous programming for classing synchronous (maybe old school multi-threaded in some cases) programming but I'd like to share my finding with the community, so maybe if this cannot be avoided at least it could be documented (Spring docs look pretty old, there is no trace of asynchronous programming).

NHibernate: System.Reflection.TargetException : Object does not match target type.

After upgrading from 1.3.2 to 2.0 RC2 I am getting the following error:

System.Reflection.TargetException : Object does not match target type.
at System.Reflection.RuntimeMethodInfo.CheckConsistency(Objectย target)
at System.Reflection.RuntimeMethodInfo.InvokeArgumentsCheck(Objectย obj,ย BindingFlagsย invokeAttr,ย Binderย binder,ย Object[]ย parameters,ย CultureInfoย culture)
at System.Reflection.RuntimeMethodInfo.Invoke(Objectย obj,ย BindingFlagsย invokeAttr,ย Binderย binder,ย Object[]ย parameters,ย CultureInfoย culture)
at NHibernate.Proxy.DefaultLazyInitializer.Intercept(InvocationInfoย info)

I need to look into it, but maybe related to a bug in NHibernate 4.0.0.4. Is there a road map to integrate with NHibernate 4.0.3?

Quartz 2.2 issue

I have raised the following issue on the Quartz.NET github.
quartznet/quartznet#157

Quartz.NET v2.2 is currently unusable for Oracle DBs. Before you put the GA release out, it might be a good idea to check on the status of this issue and possibly revert to version 2.1 if it hasn't been solved.

Is Spring.Net active again?

Hi,

It looks like this'd project is active again.
If help is wanted please let me know what can be done.
I hope to see the version 2.0 soon to be released with more features to come in the future.

[OFFTOPIC] Graduation Project

Hello there fellow programmers, my name is Marcelo Tokarnia, I'm from Brazil and I'm about to graduate in Computer Engeneering.

My final graduation project involves software design quality, tests and source code metrics.

Extract the metrics is all up to me, but I need your help to decide to what extend is the code being tested in this project, could you please fill up this survey ? It will take you only 30 seconds.
http://pt.surveymonkey.com/s/CH6B5XX

I appreciate your help,
Thank you very much,
Marcelo Tokarnia

{"Error creating context 'spring.root': At least one object must implement IComparable."}

I am getting below error if i include two spring configuration xml file with PropertyPlaceholderConfigurer. This is happening after migrating from spring 1.3.2 to 2.0.1

<object type="Spring.Objects.Factory.Config.PropertyPlaceholderConfigurer, Spring.Core"> <property name="ConfigSections" value="databaseSettings"/> </object>

{"Error creating context 'spring.root': At least one object must implement IComparable."}
InnerException : {"Errored while postprocessing an object factory."}
InnerException : {"Failed to compare two elements in the array."}
Stack trace : at Spring.Objects.Factory.Config.PropertyResourceConfigurer.PostProcessObjectFactory(IConfigurableListableObjectFactory factory)
at Spring.Context.Support.AbstractApplicationContext.InvokeObjectFactoryPostProcessors(IList objectFactoryPostProcessors, IConfigurableListableObjectFactory objectFactory)
at Spring.Context.Support.AbstractApplicationContext.InvokeObjectFactoryPostProcessors(IConfigurableListableObjectFactory objectFactory)
at Spring.Context.Support.AbstractApplicationContext.Refresh()
at Spring.Context.Support.XmlApplicationContext..ctor(XmlApplicationContextArgs args)
at Spring.Context.Support.XmlApplicationContext..ctor(String name, Boolean caseSensitive, String[] configurationLocations)
at _dynamic_Spring.Context.Support.XmlApplicationContext..ctor(Object[] )
at Spring.Reflection.Dynamic.SafeConstructor.Invoke(Object[] arguments)
at Spring.Context.Support.ContextHandler.RootContextInstantiator.InvokeContextConstructor(ConstructorInfo ctor)
at Spring.Context.Support.ContextHandler.ContextInstantiator.InstantiateContext()
at Spring.Context.Support.ContextHandler.InstantiateContext(IApplicationContext parentContext, Object configContext, String contextName, Type contextType, Boolean caseSensitive, IList`1 resources)
at Spring.Context.Support.ContextHandler.Create(Object parent, Object configContext, XmlNode section)

Initialization throught AOP Composite Proxy

Wherever i use IInitializingObject and AfterPropertySet or define init method on container configuration file, the initialization occurs before a proxy creation.
I`s cool, but all of my infrastructure need to initialization of my class depends of an context, created via AOP obviously dependente of the proxy.

How to define an method (like initialization) to spring.net call a specific method throught proxy infrastructure?

WebObjectFactory has incomplete disposable support for request and session

WebObjectFactory has the following implementation (OnEndSession is similar):

        /// <summary>
        /// Disposes all 'request'-scoped objects at the end of each Request
        /// </summary>
        private static void OnEndRequest(HttpContext context)
        {
            IDictionary items = context.Items[OBJECTTABLEKEY] as IDictionary;

            if (items != null)
            {
                log.Debug("disposing 'request'-scoped item cache");
                ArrayList keys = new ArrayList(items.Keys);
                for (int i = 0; i < keys.Count; i++)
                {
                    IDisposable d = items[keys[i]] as IDisposable;
                    if (d != null)
                    {
                        d.Dispose();
                    }
                }
            }
        }

AbstractObjectFactory has no explicit (but broken, actually) support for separate scopes for disposable objects but for non scoped singletons, it has a fairly complex procedure of checking the objects up front for IDisposable interface, or an on-destroy definition (and wrapping that in an IDisposable), registering them, calling Dispose() on them when necessary, and also calling any DestructionAwareBeanPostProcessors. Therefore, scoped singleton support for IDisposable in WebObjectFactory is currently incomplete since it does not support on-destroy configuration, DestructionAwareBeanPostProcessors or dependent objects. I'll also note that the calls to Dispose() are unsafe since they are not wrapped in try blocks.

Please note that currently, ALL scoped singleton support for IDisposable is broken, so it will be necessary to fix this after, or in tandem with, the other issue.

CacheResult Key SpEl can't use #variableName

Spring.net 2.0.0.40000
[CacheResult("AspNetCache", "'Address.Ip =' + #ipAddress", TimeToLive = "24:0:0")]
public Address SelectAddressByIp(string ipAddress)

It has exception "expect: LPAREN, found"

Check the code, it break at

match (POUND);
match(ID);
match(LPAREN);<-here

Look like the variable reference is not checked correctly.

Spring.Web.Optimization integration in Spring.Web

Hello, I have a feature request to propose.

You all know about Web Optimization Framework. One of its features is bundle mapping for styles and scripts. It is currently done via code using the BundleTable class. For example:

        bundles.Add(new ScriptBundle("~/bundles/jquery").Include(
                    "~/Scripts/jquery-{version}.js"));

        bundles.Add(new ScriptBundle("~/bundles/jqueryval").Include(
                    "~/Scripts/jquery.validate*"));

More advanced users map bundles to their official (or project-supplied) CDN.

On my own, a few years ago, I have made an XML-based configuration of the bundles, so these could be changed without recompiling the application. I don't know about its real utility in common projects, because normal product lifecycles require that a change in the Javascript/CSS fileset (e.g. adding/changing version of Bootstrap) is treated as a change and it's easy for a project manager to require a code change to map the new JS/CSS bundle to a library.

Anyway I have created a parser that automatically maps bundles to the BundleTable according to the following syntax

<bundle xsi:type="StyleBundle" virtualPath="~/bundles/metro-style-dark-blue" cdnPath="http://some.cdn">
    <include>~/Content/themes/dark-blue.css</include>
</bundle>

<bundle xsi:type="StyleBundle" virtualPath="~/bundles/metroStyle">
    <include>~/Content/base.css</include>
    <include>~/Content/skeleton.css</include>
    <include>~/Content/layout.css</include>
</bundle>

<bundle xsi:type="ScriptBundle" virtualPath="~/bundles/jQuery">
    <include>~/Scripts/jquery-{version}.js</include>
    <include>~/Scripts/jquery-ui-{version}.js</include>
    <include>~/Scripts/jquery.easing.{version}.js</include>
    <include>~/Scripts/plugins.all.js</include>
    <!--<include>~/Scripts/jquery.address-{version}.js</include>-->
    <include>~/Scripts/selectivizr.js</include>
</bundle>

I do currently have defined an XML schema, a ConfigurationSection element and a utility class. Currently my implementation doesn't support transformations yet (very useful to add). I won't show for brevity.

In order to start the discussion, and later provide code, I would ask the Spring team if you are interested in adding support for System.Web.Optimization in the Spring context file, so that the developer can add bundles to the BundleTable according to a similar syntax in the web context file. That would be automagically activated by the Spring Web context once the proper tag is found in the XML.
(Similarly for code-based configuration).

Thank you for your time.

post scriptum: I read about the bundles.config file (that is supposed to do everything my implementation does) but I have found no information about it. My code was built about 3 years ago

A first chance exception of type 'System.InvalidCastException' occurred in Spring.Core.dll

Can't seem to get this expression to evaluate a instance to see if a condition has been met keep receiving some type of run-time message.

[Expression:](PtnStats.Key ==) and (PtnStats.Pattern >= 5)

[Registration Of The Type In Question:]
TypeRegistry.RegisterType("PtnStats", typeof(GlobalPatternStatistics));

[Creation of the Instance:]
var result = new object();
object instance = new object();
string expr = "(PtnStats.Key == 'BNSum') and (PtnStats.Pattern >= 5)";

// Used in a switch statement thats why instance is created this way.
instance = new GlobalPatternStatistics();

result = ExpressionEvaluator.GetValue(instance, expr);

[Exception:]

A first chance exception of type 'System.InvalidCastException' occurred in Spring.Core.dll

Additional information: Unable to cast object of type 'System.RuntimeType' to type 'UltimateLotteryLib.Stats.GlobalPatternStatistics'.

[Stack Trace:]
at _dynamic_UltimateLotteryLib.Stats.GlobalPatternStatistics.get_Key(Object , Object[] )
at Spring.Reflection.Dynamic.SafeProperty.GetValue(Object target)

[System.MissingMethodException] System.String[] Spring.Objects.Factory.IListableObjectFactory.GetObjectNamesForType(System.Type, Boolean, Boolean)

first of all , i must say sorry to u for my english..... so.... hope you can see Understand my word :-)
first, my project just have MVC,and i include spring.net for DI, and everything is ok,
but i wanner support service with ASP.NET WebAPI , so i get the some dlls from nuget...
i saw the info of spring.net that if you want to use ASP.NET WebAPI, must include Spring.Web.Mvc4/5 ? right? so i do that. and Spring.Core also from 1.3 to 2.0 version;
when i invoke my ProxyObject, i got a MissingMethodException , it maybe because version conflict?
the Spring.Core 2.0 hasn`t method "GetObjectNamesForType"
so what should i do?
code like this:

    IMenuManager MenuManager { get; set; } // Proxy Object
    [HttpGet]
    [ExceptionCatcher]
    public HttpResponseMessage Menus()
    {
        IList<S_MENU> _menus = MenuManager.GetAll(p => p.ISSHOW == 1); //1
        return CustomeHttpResponseMessage.SuccessMessage(_menus);
    }

//1 : MissingMethodException

thanks~~~~ :-)

InvalidProgramException when trying to get a constant in some class

With this class:

public class MyClass {
public const byte MyConstant = 1;
}

When i try to evaluate the expression:

MyClass.MyConstant == 5

I get an InvalidProgramException.

I've found that defining instead it as:

public class MyClass {
public static readonly byte MyConstant = 1;
}

The exception is gone.

Can somebody help me with this?

Type Casting at Runtime for Array.SetValue

bugs_spring_expressionevaluate_01
Hello,

I am having a problem with an expression, not sure if it is becus of what i am doing or a bug. Here the expression (see below). What it is doing is this, i load and instance of a class and call one of it properties called "Steps" which contains a string value of float values like so "1,4,3,0,5,6,2,8,0".

I then pass Steps as a parameter to a static method call Conv.ToFloatArray(string) which returns an array of float[] value which is then used as a parameter for the next static that is called Algbra.StDev(float[]) this function returns a float value based on the value that is return the expression should return true or false. But instead throws an error, the exception is being thrown in this method: Spring.Util.ReflectionUtils.PackageParamArray(object[] argValues, int argCount, Type elementType).

It seems that when before it calls my Algbra.StDev(float[]) method, it tries to package the array of float and it fails and throws an error.I have added the logic for the methods i am using hopefully u will be able to help me resolve this and or maybe a work around.

Expression:
(Algbra.StDev(Conv.ToFloatArray(Steps, ',', 3)) > 3.5)

Values:
GblStats.Steps = "1,4,3,0,5,6,2,8,0";

Instance:
public class GblStats
{
[System.ComponentModel.DataObjectField(false, false, false)]
[System.ComponentModel.Browsable(true)]
public string Steps
{
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
get { return m_steps; }
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
set
{
if (m_steps != value)
{
m_steps = value;
PropertyHasChanged();
}
}
}
}

public static class Conversion
{
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining,
MethodCodeType = System.Runtime.CompilerServices.MethodCodeType.IL), System.Security.SuppressUnmanagedCodeSecurity]
public static float[] ToFloatArray(string value, string seperator, int numberofelements)
{
if (string.IsNullOrWhiteSpace(value))
return new float[] { };

        float[] result;

        result = value.Split(',').Select(float.Parse).Take(numberofelements).ToArray();

        return result;
    }

}

public static class Algebra
{
///

    /// Used to calculate the average of single values passed in.
    /// </summary>


    /// <param name="values">An array of single values.</param>
    /// <returns>Standard Deviation of a list of single values.</returns>
    /// <remarks></remarks>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining,
        MethodCodeType = System.Runtime.CompilerServices.MethodCodeType.IL), System.Security.SuppressUnmanagedCodeSecurity]
    public static float StDev(params float[] values)
    {
        // Step 1: Average
        // Step 2: Take each value - by the average
        // Step 3: square
        // Step 4: take all add them up
        // Step 5: #sample minus by 1
        // Step 6: divide step 4 by  4
        int count = values.Count();
        float total = 0.0f;
        float average = 0.0f;
        float values_minus_average = 0.0f;
        float squareroot = 0.0f;
        int maxIndex = values.Count() - 1;
        for (int Index = 0; Index <= maxIndex; Index++)
        {
            float value = values[Index];
            total += value;
        }

        if (count > 0)
        {
            average = total / count;
        }

        maxIndex = values.Count() - 1;
        for (int Index = 0; Index <= maxIndex; Index++)
        {
            float value = values[Index];
            values_minus_average += ((value - average) * (value - average));
        }

        float stdevbase = 0.0f;

        if (count > 1)
        {
            stdevbase = (values_minus_average / (count - 1));
        }
        else
        {
            stdevbase = values_minus_average;
        }

        squareroot = (float)System.Math.Sqrt(stdevbase);

        return squareroot;
    }

}

Build failed on latest code pull (v2.0)

Built on both Visual Studio 2010, and build.cmd script. Failed with following log:

NAnt 0.92 (Build 0.92.4543.0; release; 6/9/2012)
Copyright (C) 2001-2012 Gerry Shaw
http://nant.sourceforge.net

[loadtasks] Failure scanning "C:\Temp\spring-net-master\build-support\tools\nant\bin\NAnt.NUnit2Tasks.dll" for extensions. Could not load file or assembly 'nunit.core.interfaces, Version=2.6.0.12051, Culture=neutral, PublicKeyToken=96d09a1eb7f44a77' or one of its dependencies. The system cannot find the file specified.
Buildfile: file:///C:/Temp/spring-net-master/Spring.build
Target framework: Microsoft .NET Framework 4.5
Target(s) specified: test

[readregistry] Registry Value Not Found! - key='SOFTWARE\Microsoft\VisualStudio\9.0\InstallDir';hive='LocalMachine';

check-package.passedbuildincrement:

[sysinfo] Setting system information properties under sys.*
[sysinfo] Property could not be created for environment variable 'ProgramFiles(x86)' : Property name 'sys.env.ProgramFiles(x86)' is invalid.
[sysinfo] Property could not be created for environment variable 'CommonProgramFiles(x86)' : Property name 'sys.env.CommonProgramFiles(x86)' is invalid.

check-current-build-config:

set-build-configuration:

set-debug-build-configuration:

check-current-build-config:

set-build-configuration-flags:

set-build-namespaces-release:

set-user-overrides:

test:

 [echo] Compiling debug configuration for all runtime configurations.

build-all-function:

build-3.5:

set-build-namespaces-release:

 [echo] ------------------------
 [echo] Building .NET 3.5 DEBUG 
 [echo] ------------------------

set-debug-build-configuration:

check-current-build-config:

set-build-configuration-flags:

compile-build-3.5:

check-bin-dir:

check-doc-dir:

check-sdkdoc-dir:

check-sdkdoc-debug:

check-current-build-config:

check-build-debug:

check-build-defines:

set-net-3.5-runtime-configuration:

[property] Target framework changed to "Microsoft .NET Framework 3.5".

check-spring-basedir:

check-current-bin-dir:

[mkdir] Creating directory 'C:\Temp\spring-net-master\build\net\3.5\debug'.

clean-current-bin-dir:

 [echo] Cleaning the C:\Temp\spring-net-master/build/net/3.5/debug binaries directory.

[delete] Deleting directory 'C:\Temp\spring-net-master\build\net\3.5\debug'.
[mkdir] Creating directory 'C:\Temp\spring-net-master\build\net\3.5\debug'.

restore-nuget-packages:

 [exec] Installing 'NUnit.Runners 2.6.1'.
 [exec] Successfully installed 'NUnit.Runners 2.6.1'.
 [exec] Installing 'Microsoft.AspNet.Razor 3.0.0'.
 [exec] Installing 'Microsoft.AspNet.Mvc 5.0.0'.
 [exec] Installing 'Microsoft.AspNet.WebApi.WebHost 5.0.0'.
 [exec] Installing 'Microsoft.AspNet.WebPages 3.0.0'.
 [exec] Installing 'Microsoft.AspNet.WebApi.Core 5.0.0'.
 [exec] Installing 'Microsoft.AspNet.WebApi.Client 5.0.0'.
 [exec] Successfully installed 'Microsoft.AspNet.WebApi.WebHost 5.0.0'.
 [exec] Successfully installed 'Microsoft.AspNet.Razor 3.0.0'.
 [exec] Successfully installed 'Microsoft.AspNet.WebApi.Core 5.0.0'.
 [exec] Successfully installed 'Microsoft.AspNet.WebApi.Client 5.0.0'.
 [exec] Successfully installed 'Microsoft.AspNet.Mvc 5.0.0'.
 [exec] Successfully installed 'Microsoft.AspNet.WebPages 3.0.0'.
 [exec] All packages listed in packages.config are already installed.
 [exec] Installing 'NUnit 2.6.3'.
 [exec] Successfully installed 'NUnit 2.6.3'.
 [exec] Installing 'NHibernate 3.2.0.4000'.
 [exec] Installing 'NUnit 2.6.3'.
 [exec] Installing 'Iesi.Collections 3.2.0.4000'.
 [exec] Successfully installed 'Iesi.Collections 3.2.0.4000'.
 [exec] Successfully installed 'NUnit 2.6.3'.
 [exec] Successfully installed 'NHibernate 3.2.0.4000'.
 [exec] Installing 'NUnit 2.6.3'.
 [exec] Successfully installed 'NUnit 2.6.3'.
 [exec] Installing 'Microsoft.AspNet.Razor 1.0.20105.408'.
 [exec] Installing 'Microsoft.AspNet.Mvc 3.0.20105.1'.
 [exec] Installing 'EntityFramework 4.1.10331.0'.
 [exec] Installing 'Common.Logging 2.1.2'.
 [exec] Successfully installed 'Microsoft.AspNet.Razor 1.0.20105.408'.
 [exec] Successfully installed 'Microsoft.AspNet.Mvc 3.0.20105.1'.
 [exec] Installing 'Microsoft.AspNet.WebPages 1.0.20105.408'.
 [exec] Successfully installed 'Microsoft.AspNet.WebPages 1.0.20105.408'.
 [exec] Successfully installed 'Common.Logging 2.1.2'.
 [exec] Installing 'Microsoft.Web.Infrastructure 1.0.0.0'.
 [exec] Successfully installed 'EntityFramework 4.1.10331.0'.
 [exec] Successfully installed 'Microsoft.Web.Infrastructure 1.0.0.0'.
 [exec] Installing 'jQuery.vsdoc 1.6'.
 [exec] Installing 'Spring.Web.Mvc3 1.3.2'.
 [exec] Installing 'jQuery.UI.Combined 1.10.3'.
 [exec] Installing 'Spring.Web 1.3.2'.
 [exec] Installing 'Spring.Core 1.3.2'.
 [exec] Installing 'jQuery 1.10.2'.
 [exec] Installing 'jQuery.Validation 1.11.1'.
 [exec] Installing 'Modernizr 2.7.1'.
 [exec] Successfully installed 'jQuery.vsdoc 1.6'.
 [exec] Successfully installed 'jQuery.Validation 1.11.1'.
 [exec] Successfully installed 'jQuery 1.10.2'.
 [exec] Successfully installed 'jQuery.UI.Combined 1.10.3'.
 [exec] Successfully installed 'Modernizr 2.7.1'.
 [exec] Successfully installed 'Spring.Web.Mvc3 1.3.2'.
 [exec] Successfully installed 'Spring.Web 1.3.2'.
 [exec] Successfully installed 'Spring.Core 1.3.2'.
 [exec] Installing 'jQuery.Validation 1.11.1'.
 [exec] Installing 'jQuery 1.10.2'.
 [exec] Installing 'jQuery.UI.Combined 1.10.3'.
 [exec] Installing 'Microsoft.AspNet.Mvc 4.0.30506.0'.
 [exec] Successfully installed 'jQuery.Validation 1.11.1'.
 [exec] Successfully installed 'jQuery 1.10.2'.
 [exec] Successfully installed 'Microsoft.AspNet.Mvc 4.0.30506.0'.
 [exec] Installing 'Microsoft.AspNet.Razor 2.0.30506.0'.
 [exec] Successfully installed 'Microsoft.AspNet.Razor 2.0.30506.0'.
 [exec] Successfully installed 'jQuery.UI.Combined 1.10.3'.
 [exec] Installing 'Microsoft.AspNet.WebApi.Client 4.0.30506.0'.
 [exec] Successfully installed 'Microsoft.AspNet.WebApi.Client 4.0.30506.0'.
 [exec] Installing 'Microsoft.AspNet.WebApi.Core 4.0.30506.0'.
 [exec] Successfully installed 'Microsoft.AspNet.WebApi.Core 4.0.30506.0'.
 [exec] Installing 'Microsoft.AspNet.WebApi.WebHost 4.0.30506.0'.
 [exec] Successfully installed 'Microsoft.AspNet.WebApi.WebHost 4.0.30506.0'.
 [exec] Installing 'Microsoft.AspNet.WebPages 2.0.30506.0'.
 [exec] Successfully installed 'Microsoft.AspNet.WebPages 2.0.30506.0'.
 [exec] Installing 'EntityFramework 5.0.0-rc'.
 [exec] Installing 'Microsoft.AspNet.Providers 1.1'.
 [exec] Installing 'Microsoft.AspNet.Providers.Core 1.0'.
 [exec] Installing 'knockoutjs 3.0.0'.
 [exec] Installing 'Microsoft.AspNet.WebApi 4.0.20505.0'.
 [exec] Installing 'Microsoft.Bcl 1.1.6'.
 [exec] Successfully installed 'Microsoft.AspNet.Providers 1.1'.
 [exec] Successfully installed 'Microsoft.AspNet.WebApi 4.0.20505.0'.
 [exec] Successfully installed 'knockoutjs 3.0.0'.
 [exec] Successfully installed 'Microsoft.AspNet.Providers.Core 1.0'.
 [exec] Installing 'Antlr 3.5.0.2'.
 [exec] Installing 'Microsoft.AspNet.Web.Optimization 1.1.2'.
 [exec] Successfully installed 'Antlr 3.5.0.2'.
 [exec] Installing 'Microsoft.jQuery.Unobtrusive.Validation 3.0.0'.
 [exec] Installing 'Microsoft.Web.Infrastructure 1.0.0.0'.
 [exec] Successfully installed 'Microsoft.Web.Infrastructure 1.0.0.0'.
 [exec] Successfully installed 'Microsoft.AspNet.Web.Optimization 1.1.2'.
 [exec] Successfully installed 'EntityFramework 5.0.0-rc'.
 [exec] Installing 'Modernizr 2.7.1'.
 [exec] Successfully installed 'Modernizr 2.7.1'.
 [exec] Installing 'Microsoft.jQuery.Unobtrusive.Ajax 3.0.0'.
 [exec] Installing 'Microsoft.Bcl.Build 1.0.13'.
 [exec] Successfully installed 'Microsoft.jQuery.Unobtrusive.Validation 3.0.0'.
 [exec] Installing 'Microsoft.Net.Http 2.2.18'.
 [exec] Successfully installed 'Microsoft.jQuery.Unobtrusive.Ajax 3.0.0'.
 [exec] Successfully installed 'Microsoft.Bcl 1.1.6'.
 [exec] Installing 'WebGrease 1.5.2'.
 [exec] Successfully installed 'Microsoft.Bcl.Build 1.0.13'.
 [exec] Installing 'Newtonsoft.Json 5.0.8'.
 [exec] Successfully installed 'Microsoft.Net.Http 2.2.18'.
 [exec] Successfully installed 'WebGrease 1.5.2'.
 [exec] Successfully installed 'Newtonsoft.Json 5.0.8'.
 [exec] Installing 'jQuery 1.10.2'.
 [exec] Installing 'EntityFramework 5.0.0-rc'.
 [exec] Installing 'Antlr 3.5.0.2'.
 [exec] Installing 'jQuery.UI.Combined 1.10.3'.
 [exec] Installing 'knockoutjs 3.0.0'.
 [exec] Installing 'Microsoft.AspNet.Providers 1.1'.
 [exec] Installing 'Microsoft.AspNet.Mvc 5.0.0'.
 [exec] Installing 'jQuery.Validation 1.11.1'.
 [exec] Successfully installed 'Microsoft.AspNet.Providers 1.1'.
 [exec] Successfully installed 'jQuery.Validation 1.11.1'.
 [exec] Successfully installed 'Antlr 3.5.0.2'.
 [exec] Successfully installed 'knockoutjs 3.0.0'.
 [exec] Installing 'Microsoft.AspNet.Razor 3.0.0'.
 [exec] Installing 'Microsoft.AspNet.Web.Optimization 1.1.2'.
 [exec] Installing 'Microsoft.AspNet.Providers.Core 1.0'.
 [exec] Successfully installed 'Microsoft.AspNet.Web.Optimization 1.1.2'.
 [exec] Successfully installed 'Microsoft.AspNet.Mvc 5.0.0'.
 [exec] Successfully installed 'Microsoft.AspNet.Razor 3.0.0'.
 [exec] Successfully installed 'jQuery 1.10.2'.
 [exec] Successfully installed 'Microsoft.AspNet.Providers.Core 1.0'.
 [exec] Installing 'Microsoft.AspNet.WebApi.WebHost 5.0.0'.
 [exec] Installing 'Microsoft.AspNet.WebPages 3.0.0'.
 [exec] Installing 'Microsoft.AspNet.WebApi.Client 5.0.0'.
 [exec] Installing 'Microsoft.AspNet.WebApi.Core 5.0.0'.
 [exec] Successfully installed 'Microsoft.AspNet.WebApi.WebHost 5.0.0'.
 [exec] Successfully installed 'Microsoft.AspNet.WebApi.Client 5.0.0'.
 [exec] Successfully installed 'EntityFramework 5.0.0-rc'.
 [exec] Successfully installed 'Microsoft.AspNet.WebApi.Core 5.0.0'.
 [exec] Successfully installed 'Microsoft.AspNet.WebPages 3.0.0'.
 [exec] Installing 'Microsoft.jQuery.Unobtrusive.Ajax 3.0.0'.
 [exec] Installing 'Microsoft.jQuery.Unobtrusive.Validation 3.0.0'.
 [exec] Successfully installed 'Microsoft.jQuery.Unobtrusive.Ajax 3.0.0'.
 [exec] Installing 'Microsoft.Web.Infrastructure 1.0.0.0'.
 [exec] Successfully installed 'Microsoft.jQuery.Unobtrusive.Validation 3.0.0'.
 [exec] Installing 'Modernizr 2.7.1'.
 [exec] Successfully installed 'jQuery.UI.Combined 1.10.3'.
 [exec] Successfully installed 'Microsoft.Web.Infrastructure 1.0.0.0'.
 [exec] Installing 'Newtonsoft.Json 5.0.8'.
 [exec] Successfully installed 'Modernizr 2.7.1'.
 [exec] Installing 'WebGrease 1.5.2'.
 [exec] Successfully installed 'WebGrease 1.5.2'.
 [exec] Successfully installed 'Newtonsoft.Json 5.0.8'.
 [exec] Installing 'Microsoft.AspNet.WebApi 5.0.0'.
 [exec] Installing 'Microsoft.Data.OData 5.6.0'.
 [exec] Installing 'Microsoft.Data.Edm 5.6.0'.
 [exec] Installing 'System.Spatial 5.6.0'.
 [exec] Successfully installed 'Microsoft.AspNet.WebApi 5.0.0'.
 [exec] Installing 'Microsoft.AspNet.WebApi.OData 5.0.0'.
 [exec] Successfully installed 'Microsoft.AspNet.WebApi.OData 5.0.0'.
 [exec] Successfully installed 'Microsoft.Data.Edm 5.6.0'.
 [exec] Successfully installed 'System.Spatial 5.6.0'.
 [exec] Successfully installed 'Microsoft.Data.OData 5.6.0'.
 [exec] Installing 'Quartz 2.2.3'.
 [exec] Installing 'Common.Logging 2.1.2'.
 [exec] Successfully installed 'Common.Logging 2.1.2'.
 [exec] Successfully installed 'Quartz 2.2.3'.
 [exec] Installing 'NUnit 2.6.3'.
 [exec] Successfully installed 'NUnit 2.6.3'.
 [exec] Installing 'NUnit 2.6.3'.
 [exec] Installing 'Common.Logging 2.1.2'.
 [exec] Successfully installed 'NUnit 2.6.3'.
 [exec] Successfully installed 'Common.Logging 2.1.2'.
 [exec] WARNING: Project file C:\Temp\spring-net-master\examples\Spring\Spring.WebQuickStart\src\Spring.WebQuickStart.2005\ cannot be found.
 [exec] WARNING: Project file C:\Temp\spring-net-master\examples\Spring\Spring.WebQuickStart\src\Spring.WebQuickStart.Providers\ cannot be found.
 [exec] All packages listed in packages.config are already installed.
 [exec] WARNING: Project file C:\Temp\spring-net-master\examples\Spring\SpringAir\src\SpringAir.Web.2010\ cannot be found.
 [exec] Installing 'NUnit 2.6.3'.
 [exec] Successfully installed 'NUnit 2.6.3'.

compile-net-3.5:

generate-build-number:

common.set-assembly-attribute-values:

common.generate-assemblyinfo:

[asminfo] Generated file 'C:\Temp\spring-net-master\src\Spring\GenCommonAssemblyInfo.cs'.

copylibs:

 [echo] Current lib20 dir = C:\Temp\spring-net-master\lib\net\2.0
 [echo] Current lib dir = C:\Temp\spring-net-master/lib/net/3.5
 [copy] Copying 3 files to 'C:\Temp\spring-net-master\lib\net\3.5'.

compile-test:

copylibtobin:

 [echo] Current bin dir = C:\Temp\spring-net-master/build/net/3.5/debug
 [echo] Current lib dir = C:\Temp\spring-net-master/lib/net/3.5
 [copy] Copying 15 files to 'C:\Temp\spring-net-master\build\net\3.5\debug'.
 [copy] Copying 2 files to 'C:\Temp\spring-net-master\build\net\3.5\debug'.
 [nant] C:\Temp\spring-net-master\src\Spring\Spring.Core\Spring.Core.build build
        Buildfile: file:///C:/Temp/spring-net-master/src/Spring/Spring.Core/Spring.Core.build
        Target framework: Microsoft .NET Framework 3.5
        Target(s) specified: build 


        compileGrammar:

             [exec] Starting 'C:\Temp\spring-net-master\build-support\tools\antlr-2.7.6\antlr-2.7.6.exe (-o C:\Temp\spring-net-master\src\Spring\Spring.Core\Expressions\Parser C:\Temp\spring-net-master\src\Spring\Spring.Core\Expressions\Expression.g)' in 'C:\Temp\spring-net-master\src\Spring\Spring.Core'
             [exec] ANTLR Parser Generator   Version 2.7.6 (2005-12-22)   1989-2005

        build:

             [echo] Compiling 'C:\Temp\spring-net-master/build/net/3.5/debug/Spring.Core.dll' with args 
              [csc] Compiling 686 files to 'C:\Temp\spring-net-master\build\net\3.5\debug\Spring.Core.dll'.

        BUILD SUCCEEDED - 0 non-fatal error(s), 1 warning(s)

        Total time: 1.9 seconds.

 [nant] C:\Temp\spring-net-master\src\Spring\Spring.Aop\Spring.Aop.build build
        Buildfile: file:///C:/Temp/spring-net-master/src/Spring/Spring.Aop/Spring.Aop.build
        Target framework: Microsoft .NET Framework 3.5
        Target(s) specified: build 


        build:

              [csc] Compiling 153 files to 'C:\Temp\spring-net-master\build\net\3.5\debug\Spring.Aop.dll'.

        BUILD SUCCEEDED

        Total time: 0.4 seconds.

 [nant] C:\Temp\spring-net-master\src\Spring\Spring.Web\Spring.Web.build build
        Buildfile: file:///C:/Temp/spring-net-master/src/Spring/Spring.Web/Spring.Web.build
        Target framework: Microsoft .NET Framework 3.5
        Target(s) specified: build 


        build:

              [csc] Compiling 126 files to 'C:\Temp\spring-net-master\build\net\3.5\debug\Spring.Web.dll'.

        BUILD SUCCEEDED

        Total time: 0.4 seconds.

 [nant] C:\Temp\spring-net-master\src\Spring\Spring.Web.Extensions\Spring.Web.Extensions.build build
        Buildfile: file:///C:/Temp/spring-net-master/src/Spring/Spring.Web.Extensions/Spring.Web.Extensions.build
        Target framework: Microsoft .NET Framework 3.5
        Target(s) specified: build 


        build:

              [csc] Compiling 3 files to 'C:\Temp\spring-net-master\build\net\3.5\debug\Spring.Web.Extensions.dll'.

        BUILD SUCCEEDED

        Total time: 0.1 seconds.

 [nant] C:\Temp\spring-net-master\src\Spring\Spring.Data\Spring.Data.build build
        Buildfile: file:///C:/Temp/spring-net-master/src/Spring/Spring.Data/Spring.Data.build
        Target framework: Microsoft .NET Framework 3.5
        Target(s) specified: build 


        build:

              [csc] Compiling 194 files to 'C:\Temp\spring-net-master\build\net\3.5\debug\Spring.Data.dll'.

        BUILD SUCCEEDED

        Total time: 0.4 seconds.

 [nant] C:\Temp\spring-net-master\src\Spring\Spring.Data.NHibernate32\Spring.Data.NHibernate32.build build
        Buildfile: file:///C:/Temp/spring-net-master/src/Spring/Spring.Data.NHibernate32/Spring.Data.NHibernate32.build
        Target framework: Microsoft .NET Framework 3.5
        Target(s) specified: build 


        build:

             [echo] C:\Temp\spring-net-master/packages/NHibernate.3.2.0.4000/lib/Net35
             [copy] Copying 1 file to 'C:\Temp\spring-net-master\build\net\3.5\debug'.
             [echo] C:\Temp\spring-net-master/packages/Iesi.Collections.3.2.0.4000/lib/Net35
             [copy] Copying 1 file to 'C:\Temp\spring-net-master\build\net\3.5\debug'.
              [csc] Compiling 43 files to 'C:\Temp\spring-net-master\build\net\3.5\debug\Spring.Data.NHibernate32.dll'.
              [csc] c:\Temp\spring-net-master\src\Spring\Spring.Data.NHibernate\Data\NHibernate\DelegatingLocalSessionFactoryObject.cs(43,28): error CS0103: The name 'ConfigurationManager' does not exist in the current context
              [csc] c:\Temp\spring-net-master\src\Spring\Spring.Data.NHibernate\Data\NHibernate\DelegatingLocalSessionFactoryObject.cs(43,96): error CS0234: The type or namespace name 'Cfg' does not exist in the namespace 'Spring.Data.NHibernate' (are you missing an assembly reference?)
              [csc] c:\Temp\spring-net-master\src\Spring\Spring.Data.NHibernate\Data\NHibernate\DelegatingLocalSessionFactoryObject.cs(47,76): error CS0234: The type or namespace name 'Cfg' does not exist in the namespace 'Spring.Data.NHibernate' (are you missing an assembly reference?)
              [csc] c:\Temp\spring-net-master\src\Spring\Spring.Data.NHibernate\Data\NHibernate\DelegatingLocalSessionFactoryObject.cs(51,52): error CS0234: The type or namespace name 'Cfg' does not exist in the namespace 'Spring.Data.NHibernate' (are you missing an assembly reference?)

        BUILD FAILED

        C:\Temp\spring-net-master\src\Spring\Spring.Data.NHibernate32\Spring.Data.NHibernate32.build(26,4):
        External Program Failed: C:\Windows\Microsoft.NET\Framework64\v3.5\csc.exe (return code was 1)

        Total time: 0.2 seconds.

BUILD FAILED - 1 non-fatal error(s), 2 warning(s)

Nested build failed. Refer to build log for exact reason.

Total time: 13 seconds.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.