Commit Graph
291 Commits
Author SHA1 Message Date
Marek Habersack fc4874fac3 Merge Mono.Web back into System.Web and remove the Mono.Web module 2014-05-08 20:30:53 +02:00
Andres G. Aragoneses 7d75358e6c [WebConfigurationManager] Fix memleak by using a LruCache (BXC#5598)
System.Web.ConfigurationManager had a cache which didn't have any max limit,
therefore when using Restful URIs in ASP.NET (like having some variable
parameter in the virtual path, i.e. /user/{userId}/tracks, where {userId}
is a variable Integer) this was very likely to cause a leak which would
end up causing troubles, like an InvalidCastException thrown by
HttpApplication::PreStart()

(Read operations in the cache now cause a write operation on the cache
object, so all sectionCache lock-read usages are converted to lock-write.)

Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=5598
2013-05-14 17:47:40 +01:00
Bojan Rajkovic db8f33718a Revert "Merge pull request #618 from knocte/aspnet_lru"
This reverts commit 675328ef16, reversing
changes made to edc181c514.
2013-05-01 17:05:12 -04:00
Andres G. Aragoneses 96bbdc60bf [WebConfigurationManager] Fix memleak by using a LruCache (BXC#5598)
System.Web.ConfigurationManager had a cache which didn't have any max limit,
therefore when using Restful URIs in ASP.NET (like having some variable
parameter in the virtual path, i.e. /user/{userId}/tracks, where {userId}
is a variable Integer) this was very likely to cause a leak which would
end up causing troubles, like an InvalidCastException thrown by
HttpApplication::PreStart()

Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=5598
2013-04-23 16:36:42 +01:00
garyb 76bedd30a6 Fix System.Web build 2012-10-10 23:20:08 +01:00
Marek Safar 2873912e41 Fixes build 2012-09-26 08:29:33 +01:00
Marek Habersack 2ab1a05105 Fix for Novell bug #739119 2012-07-24 18:49:34 -04:00
Marek Habersack b76dfd8cea [asp.net] Implemented undocumented BuildManagerHost class to support the Cassini ASP.NET host 2011-04-17 03:00:15 +02:00
Kornél Pál 5a634b2487 [asp.net] Fix for bug #650695. Implements the System.Web.{HttpNotFoundHandler,HttpNotImplementedHandler} classes. 2011-03-14 23:46:51 +01:00
Jérémie Laval 325580a101 Correctly add ObjectPool to the build 2011-02-14 18:16:51 +00:00
Marek Habersack 1171cacd8d [asp.net] Implemented CustomErrorsRedirectMode 2011-02-09 01:24:16 +01:00
Marek Habersack 1465bf891a [ASP.NET] Templated exception reporting and a new look for the Yellow Screen Of Death
This commit implements the base template code along with the default Mono theme for exception/error
reporting in ASP.NET applications. Means for user to implement their own templates will be provided
at a later date.
2011-01-24 03:15:14 +01:00
Jérémie Laval 68fab8082c Add a default implementation of SpinWait when SplitOrderedList is built with Sys.Web 2.0 and add it to the build 2010-11-22 18:05:19 +00:00
Marek Habersack 3b8cd7bbce [asp.net] New version of code to purge underused entries from the cache.
This version uses an LRU cache to hold the cache items. Priority is not taken into account
when removing the underused entries (with the exception of the CacheItemPriority.NotRemovable
- items with this priority are never purged), they are treated equally.
A separate thread is not used to perform purging, instead the collection happens in the current
requests's thread.
Minor improvements to cache item enumerator and to the CheckDependencies method.
2010-11-16 04:03:26 +01:00
Marek Habersack 06cdf56198 [asp.net] 4.0-only types don't need the NET_4_0 ifdef and should be in net_4_0_System.Web.dll.sources 2010-11-02 11:30:26 +01:00
Sebastien Pouliot 21d2c6aedb A few moves/changes following previous patch review
* Makefile: Compile tests with TEST defined (to include System.Web.Util.
MachineKeySectionUtils unit tests)
* System.Web.dll.sources: Move MachineKeySectionUtils.cs from System.
Web.Configuration_2.0 to System.Web.Util
* System.Web_test.dll.sources: Move MachineKeySectionUtilsTest.cs from
System.Web.Configuration_2.0 to System.Web.Util

* System.Web.Configuration_2.0/MachineKeySection.cs: Adjust using
clauses. Uncomment some code. Fix TripleDES versus 3DES for Validation
under NET_4_0. Remove 'private' on fields/methods.
* System.Web.Handlers/AssemblyResourceLoader.cs: Adjust using clauses
* System.Web.Security/MembershipHelper.cs: Adjust using clauses
* System.Web.Security/RolePrincipal.cs: Adjust using clauses
* System.Web.SessionState_2.0/SessionId.cs: Adjust using clauses
* System.Web.UI/LosFormatter.cs: Adjust using clauses.
* System.Web.Util/MachineKeySectionUtils.cs: Moved from System.Web.
Configuration_2.0. Rename namespace and remove 'internal' on type
declaration

* Test/System.Web.Util/MachineKeySectionUtilsTest.cs: Moved from Test/
System.Web.Configuration/MachineKeySectionTest.cs. Add test case for
TripleDES versus 3DES
2010-10-12 11:38:48 -04:00
Sebastien Pouliot a22389fde2 Normalization of cryptographic uses in asp.net
* System.Web.Configuration_2.0/MachineKeyRegistryStorage.cs:
Remove key length check and generic key generation.

* System.Web.Configuration_2.0/MachineKeySection.cs: Add support for 4.0
ValidationAlgorithm and the use of custom algorithms (validation and
decryption). Allow the use of any, valid, key length (based on the
algorithm). Let each algorithm creates its own key (e.g. special needs,
default length...)

* System.Web.Configuration_2.0/MachineKeySectionUtils.cs: Remove key
generation (from random) code and 192bits key length hack (won't work
with custom algorithms). Add support for new (4.0) algorithms, including
custom ones. Provide uniform/shared code to Encrypt/Decrypt, Sign/Verify
and EncryptSign/VerifyDecrypt using MachineKeySection data.

* System.Web.Configuration_2.0/MachineKeyValidation.cs: Add new (4.0)
values.

* System.Web.Configuration_2.0/MachineKeyValidationConverter.cs: Add
support for new (4.0) algorithms.

* System.Web.Handlers/AssemblyResourceLoader.cs: Use the new common
cryptographic code and base64 the encrypted data.

* System.Web.Security/FormsAuthentication.cs: Use the new common
cryptographic code and base64 the signed and/or encrypted data.

* System.Web.Security/MembershipHelper.cs: Use the new common
cryptographic code - this should be 100% compatible with existing data.

* System.Web.Security/RolePrincipal.cs: Use the new common cryptographic
code.

* System.Web.Security/SqliteMembershipProvider.cs: Adapt code for
internal API change.

* System.Web.UI/LosFormatter.cs: Adapt code for internal API change.
Fix some small behaviro changes wrt NET_4_0

* System.Web.UI/ObjectStateFormatter.cs: Use the new common cryptographic
code.

* System.Web.UI/Page.cs: Remove code that is now unneeded (with the new
common cryptogrraphic code).

* System.Web.Configuration_2.0/MachineKeyCompatibilityMode.cs: New.

* Test/System.Web.Configuration/MachineKeyValidationConverterTest.cs:
Add more, mostly 4.0, test cases.

* Test/System.Web.Security/FormsAuthenticationTest.cs: Add test case to
ensure HashPasswordForStoringInConfigFile is not case sensitive.

* Test/System.Web.UI/LosFormatterTest.cs: Add some rountrip test cases
with the different ctors
2010-10-12 11:38:47 -04:00
Marek Habersack f1d69fd4bc [asp.net] Menu 4.0 List mode rendering 2010-09-10 15:36:08 +02:00
Marek Habersack dc152b5477 2010-07-20 Marek Habersack <[email protected]>
* StyleCollection.cs: added

svn path=/trunk/mcs/; revision=160656
2010-07-21 12:58:13 +00:00
Marek Habersack f2f50f05da 2010-07-15 Marek Habersack <[email protected]>
* PlaceHolder.cs, View.cs, WizardStepBase: added EnableTheming
	property

	* MultiViewControlBuilder.cs: added

More 2.0/4.0 metadata updates

svn path=/trunk/mcs/; revision=160448
2010-07-15 16:51:09 +00:00
Marek Habersack f8d637595c 2010-06-01 Marek Habersack <[email protected]>
* HttpUtility.cs: moved chunks of code to the new
	System.Web.Util.HttpEncoder class.

	* HttpResponseHeader.cs: encode header names and values using
	HttpEncoder.

	* HttpRequest.cs: added internal method Validate, to validate the
	request in 4.0 profile.

	* HttpHeaderCollection.cs: added. A helper class to encode header
	names/values on add.

	* HttpApplication.cs: Pipeline () validates request by calling
	HttpRequest.Validate in the 4.0 profile.

2010-06-01  Marek Habersack  <[email protected]>

	* HttpEncoder.cs: added. A 4.0 type but also used in 2.0 profile,
	internally.

2010-06-01  Marek Habersack  <[email protected]>

	* HttpRuntimeSection.cs: added 4.0 properties
	MaxQueryLengthString, MaxUrlLength, EncoderType and
	RelaxedUrlToFileSystemMapping.

svn path=/trunk/mcs/; revision=158300
2010-06-01 19:39:19 +00:00
Marek Habersack 5411dd0e2a 2010-05-19 Marek Habersack <[email protected]>
* PageParser.cs: handle several main directive attributes
    	specially, as they can have expressions as their values. Fixes bug
    	#603532

    	* MainDirectiveAttribute.cs: added - helper class to handle
    	directive attributes which can take either a value or an
    	expression.

    	* BaseParser.cs: IsDirective, IsExpression and IsDataBound methods
    	moved to here from TemplateControlCompiler.

    2010-05-19  Marek Habersack  <[email protected]>

    	* TemplateControlCompiler.cs: IsDirective, IsExpression and
    	IsDataBound methods moved to System.Web.UI.BaseParser.
    	Made CompileExpression and GetFieldOrProperty methods internal.

    	* PageCompiler.cs: check several of the Page directive attributes
    	for expressions. Fixes bug #603532

    	* AspGenerator.cs, TagAttributes.cs: use IDictionary instead of
    	Hashtable

svn path=/trunk/mcs/; revision=157519
2010-05-19 01:28:09 +00:00
Marek Habersack b7c1796077 2010-04-28 Marek Habersack <[email protected]>
* Makefile (OTHER_LIB_MCS_FLAGS): added a reference to
	System.Web.ApplicationServices in the 4.0 profile.

2010-04-28  Marek Habersack  <[email protected]>

	* KeyedList.cs: do not implement IStateManager in 4.0

2010-04-28  Marek Habersack  <[email protected]>

	* Makefile (OTHER_LIB_MCS_FLAGS): added a reference to
	System.Web.ApplicationServices in the 4.0 profile.

2010-04-28  Marek Habersack  <[email protected]>

	* Makefile (LIB_MCS_FLAGS): added a reference to
	System.Web.ApplicationServices in the 4.0 profile.

2010-04-28  Marek Habersack  <[email protected]>

	* Makefile (OTHER_LIB_MCS_FLAGS): added a reference to
	System.Web.ApplicationServices in the 4.0 profile.

2010-04-28  Marek Habersack  <[email protected]>

	* Makefile (common_dirs): added System.Web.ApplicationServices

2010-04-28  Marek Habersack  <[email protected]>

	* RolePrincipal.cs: class is not sealed in 4.0

	* MembershipUser.cs: type forwarded to
	System.Web.ApplicationServices in 4.0.
	In the 4.0 profile, a MembershipHelper instance is created using
	reflection, so that the Membership class and password
	encryption/decryption services can be accessed without referencing
	System.Web

	* MembershipProvider.cs: type forwarded to
	System.Web.ApplicationServices in 4.0.
	{Encrypt,Decrypt}Password implementations moved to
	MembershipHelper.
	Added new EncryptPassword overload for 4.0

	* MembershipHelper.cs: a helper class to handle password
	encryption/decryption and to forward requests for certain
	Membership properties in 4.0. It is used also in 2.0 to keep code
	cleaner. System.Web.ApplicationServices uses it to access the
	Membership class without having to reference System.Web

	* MembershipCreateStatus.cs, MembershipCreateUserException.cs,
	MembershipPasswordException.cs, MembershipPasswordFormat.cs,
	MembershipProviderCollection.cs, MembershipUserCollection.cs,
	MembershipValidatePasswordEventHandler.cs, RoleProvider.cs,
	ValidatePasswordEventArgs.cs:
	types forwarded to System.Web.ApplicationServices in 4.0

	* FormsIdentity.cs: class is not sealed in 4.0

svn path=/trunk/mcs/; revision=156264
2010-04-27 22:49:20 +00:00
Marek Habersack e105f08673 2010-03-04 Marek Habersack <[email protected]>
* BuildManager.cs: do less work in the static constructor

2010-03-04  Marek Habersack  <[email protected]>

	* RuntimeHelpers.cs: added. Contains methods moved here from
	HttpRuntime, so that initialization sequence of various objects is
	independent of HttpRuntime.

2010-03-04  Marek Habersack  <[email protected]>

	* HttpRuntime.cs: do less work in the static constructor. Most of
	the code was moved to System.Web.Util.RuntimeHelpers. Properties
	which have been moved: MonoVersion, RunningOnWindows,
	CaseInsensitive, IsDebuggingEnabled

Also:
	- hushed some compiler warnings
	- various classes now use RuntimeHelpers instead of HttpRuntime

svn path=/trunk/mcs/; revision=153038
2010-03-04 19:04:13 +00:00
Marek Habersack db5712f5ed Added to dist some missing files
svn path=/trunk/mcs/; revision=151677
2010-02-13 01:44:00 +00:00
Marek Habersack 73c3bfba56 2010-02-03 Marek Habersack <[email protected]>
* AssemblyInfo.cs: added back InternalsVisibleTo for the test
        assembly - it's needed to access CacheItemPriorityQueue

2010-02-03  Marek Habersack  <[email protected]>

        * OutputCache.cs: DefaultProviderName checks if there was any
        provider configured and, if not, returns a built-in provider's
        name.

        * SqlCacheDependencyAdmin.cs: added

        * OutputCacheProviderCollection.cs: added

        * OutputCacheProvider.cs: added

        * OutputCacheModule.cs: uses the 4.0 extensible output cache
        provider model now (also internally in the 2.0 profile)
        OutputCacheProvider is retrieved on every request using
        HttpApplication.GetOutputCacheProviderName (4.0+). In the 2.0
        profile an instance of InMemoryOutputCacheProvider is always
        returned.

        * InMemoryOutputCacheProvider.cs: default output cache provider
        for ASP.NET 4.0, also used internally in the  2.0 profile.

        * CachedVaryBy.cs: made the generated key shorter

        * CacheItemPriorityQueueDebug.cs: debugging support for
        CacheItemPriorityQueue. Most of the code is compiled only when the
        DEBUG macro is defined. Debugging support includes recording of
        the queue operations sequence which is output to an XML file on
        appdomain shutdown. The recorded sequence files can be used to
        generate NUnit test cases for the priority queue (see
        ../Test/tools/README)

        * CacheItemPriorityQueue.cs: rewritten using an array based heap
        instead of a binary tree based one - implementation is simpler,
        faster and more elegant. Heap is initially 32 entries long and
        its size is doubled every time it fills up. After reaching a
        threshold (8192 entries currently) it is shrunk to the number of
        items + 1/3 of item count in order to preserve memory.

        * CacheItem.cs: added a Guid field to easier distinguish items
        (mostly for debugging purposes)

        * CacheDependency.cs: minor performance improvements

        * Cache.cs: better handling of timer periods

2010-02-03  Marek Habersack  <[email protected]>

        * HttpApplication.cs: GetOutputCacheProviderName returns the value
        of OutputCache.DefaultProviderName

        * HttpRuntime.cs: internal cache is used to hold the dependencies
        now.

2010-02-03  Marek Habersack  <[email protected]>

        * CacheItemPriorityQueueTest_generated.cs: added

        * CacheItemPriorityQueueTest.cs: added

2010-02-04  Marek Habersack  <[email protected]>

        * Helpers.cs: added a helper method for checking of HTML mentions
        any .NET exceptions.

2010-02-03  Marek Habersack  <[email protected]>

        * Makefile: added targets to compile cache priority queue tests
        generator and to generate the tests themselves

svn path=/trunk/mcs/; revision=150855
2010-02-04 13:53:55 +00:00
Marek Habersack dc4d82729f 2010-01-25 Marek Habersack <[email protected]>
* SqlCacheDependency.cs: added parameter checks to the
	constructors.
	Partially implemented 4.0 method CreateOutputCacheDependency

	* CacheItemUpdateReason.cs, CacheItemUpdateCallback.cs: added

	* CacheItem.cs: added OnUpdateCallback field

	* Cache.cs: implemented support for cache item update callback
	(3.5+)

	* AggregateCacheDependency.cs: added undocumented
	DependencyDispose method override

2010-01-25  Marek Habersack  <[email protected]>

	* SqlCacheDependencyTest.cs: added

svn path=/trunk/mcs/; revision=150130
2010-01-25 14:02:18 +00:00
Marek Habersack b315e2df14 2010-01-21 Marek Habersack <[email protected]>
* FileResponseElementTest.cs, HeaderElementTest.cs,
	MemoryResponseElementTest.cs, SubstitutionResponseElementTest.cs:
	added

2010-01-21  Marek Habersack  <[email protected]>

	* DatabaseNotEnabledForNotificationException.cs, OutputCache.cs,
	FileResponseElement.cs, HeaderElement.cs, IOutputCacheEntry.cs,
	MemoryResponseElement.cs, OutputCacheProvider.cs,
	ResponseElement.cs, OutputCacheProviderCollection.cs,
	SubstitutionResponseElement.cs,
	TableNotEnabledForNotificationException.cs: added

	* CacheDependency.cs: default constructor is protected in 4.0

svn path=/trunk/mcs/; revision=150025
2010-01-21 22:30:21 +00:00
Marek Habersack 7804364216 2010-01-14 Marek Habersack <[email protected]>
* Helpers.cs, ITestCase.cs, ITestRunner.cs, StandaloneTest.cs,
	TestCallback.cs, TestCaseAttribute.cs,
	TestCaseFailureException.cs, TestRunItem.cs, TestRunner.cs,
	TestWorkerRequest.cs: added

2010-01-14  Marek Habersack  <[email protected]>

	* System.Web_standalone_test.dll.sources,
	standalone-runner-support.dll.sources: added

	* Makefile: Added targets to build and run standalone tests.
	Added standalone tests and test tools to EXTRA_DISTFILES

2010-01-14  Marek Habersack  <[email protected]>

	* Consts.cs.in, Locations.cs: added

2010-01-14  Marek Habersack  <[email protected]>

	* standalone-runner.cs: added

	* Makefile: added build targets for standalone-runner.exe

2010-01-14  Marek Habersack  <[email protected]>

	* NunitWebTest.cs: added new overload of GetControlFromPageHtml
	which takes begin and end markers as parameters.

2010-01-14  Marek Habersack  <[email protected]>

	* ApplicationManager.cs: implemented a missing CreateObject
	overload

2010-01-14  Marek Habersack  <[email protected]>

	* executable.make, library.make, rules.make: quote file name
	wherever referenced in dist* targets, so that files with spaces in
	name work fine.

svn path=/trunk/mcs/; revision=149522
2010-01-14 01:15:01 +00:00
Marek Habersack a7b1a2dd6f Removed 1.1-only directories:
- System.Web.Configuration
 - System.Web.SessionState

svn path=/trunk/mcs/; revision=143647
2009-10-07 13:31:42 +00:00
Marek Habersack 5c59801fff Performance improvements:
- made sure invariant culture is used with String.ToLower, String.ToUpper and String.Compare
- replaced all calls to CultureInfo.InvariantCulture with a reference to a static field System.Web.Util.Helpers.InvariantCulture

svn path=/trunk/mcs/; revision=143587
2009-10-07 00:10:03 +00:00
Marek Habersack aa68b0b904 2009-09-26 Marek Habersack <[email protected]>
* CacheItemPriorityQueue.cs, CacheItem.cs, CacheItemEnumerator.cs:
	added

	* Cache.cs: factored out CacheItem and CacheItemEnumerator to
	separate files.
	Use reader-writer locks instead of Monitor.
	Added two 3.5sp1 properties - EffectivePrivateBytesLimit and
	EffectivePercentagePhysicalMemoryLimit.
	Added support for disabling cache item expiration.
	One timer is used to expire all timed items (instead of one timer
	per item). Timed items are kept in a priority queue.

svn path=/trunk/mcs/; revision=142664
2009-09-25 22:28:21 +00:00
Veerapuram Varadhan 5c13496c4d * Use System.Data.Design version of TypedDataSetGenerator instead of from System.Data
svn path=/trunk/mcs/; revision=138436
2009-07-22 18:25:42 +00:00
Marek Habersack 6e2c12210d 2009-07-09 Marek Habersack <[email protected]>
* DefaultResourceProvider.cs, DefaultResourceProviderFactory.cs:
	added

2009-07-09  Marek Habersack  <[email protected]>

	* HttpContext.cs: fall back to default resource provider factory
	if the factory provided by user doesn't have the required object
	in Get{Global,Local}ResourceObject. Fixes bug #520397
	Refactored the GetResourceObject method and the
	ResourceManagerCacheKey class to DefaultResourceProvider.

svn path=/trunk/mcs/; revision=137624
2009-07-09 13:01:10 +00:00
Marek Habersack 7766743366 2009-04-03 Marek Habersack <[email protected]>
* WebConfigurationManager.cs: added code in the static constructor
	to enable retrieving application settings via
	ApplicationSettingsBase from within asp.net applications. Fixes
	bug #491531

	* ApplicationSettingsConfigurationFileMap.cs: added.

2009-04-03  Marek Habersack  <[email protected]>

	* CustomizableFileSettingsProvider.cs: added a way for System.Web
	to specify path to the current Web.config. Fixes bug #491531

svn path=/trunk/mcs/; revision=130909
2009-04-02 22:35:28 +00:00
Marek Habersack 3dfbadffd6 2009-02-26 Marek Habersack <[email protected]>
* System.Web.dll.sources: added System.Web/IisTraceListener.cs

2009-02-26  Marek Habersack  <[email protected]>

	* IisTraceListener.cs: added + implemented

svn path=/trunk/mcs/; revision=128046
2009-02-26 02:32:53 +00:00
Gonzalo Paniagua Javier 38d6841577 2009-02-20 Gonzalo Paniagua Javier <[email protected]>
* System.Web/HttpWriter.cs: new Response property and WriteUTF8Ptr
	method.
	* System.Web/HttpResponseStream.cs: added support for writing from an
	IntPtr. copied the memcpy method from String.cs.

	* System.Web.Compilation/BuildManager.cs: updated comment.

	* System.Web.UI/ResourceBasedLiteralControl.cs: new Control. It's just
	like a LiteralControl but will render itself from the bytes pointed to
	by an IntPtr and not create any string from the underlying data unless
	needed.

	* System.Web.UI/TemplateControl.cs: implemented a bunch of methods
	that are used from the precompiled assemblies for a web project. The
	most notable change needed is to be able to read a win32 resource from
	the dll of the control. The resource is a concatenation of literals
	with plain text for the control and a specialized LiteralControl is
	generated from different chunks of the resource.

	* System.Web.UI/HtmlTextWriter.cs: new method that returns the
	HttpWriter in use.

	* System.Web.dll.sources: added new file.

	* System.Web.Util/ICalls.cs: new internal call to get a pointer to the
	win32 resource associated with the control's assembly.


svn path=/trunk/mcs/; revision=127579
2009-02-20 21:30:58 +00:00
Marek Safar b1a2042b83 2009-02-12 Marek Safar <[email protected]>
* ControlBuilder.cs, PageParserFilter.cs, CodeConstructType.cs:
	Add few missing members.


svn path=/trunk/mcs/; revision=126769
2009-02-12 22:51:00 +00:00
Marek Habersack 15e7dec4cd Copied a few more stub files
svn path=/trunk/mcs/; revision=124784
2009-01-28 15:37:05 +00:00
Marek Habersack 7f146e5225 Added copies of some .jvm.cs files
svn path=/trunk/mcs/; revision=124780
2009-01-28 14:51:30 +00:00
Marek Habersack 7dea4232fe 2009-01-27 Marek Habersack <[email protected]>
* HttpHandlerAction.cs: removed the matches cache, it doesn't
	improve matters here in 99% of the cases.
	Regexps are no longer used to match handler paths, SearchPattern
	is used instead.

2009-01-27  Marek Habersack  <[email protected]>

	* SearchPattern.cs: added

2009-01-27  Marek Habersack  <[email protected]>

	* System.Web.dll.sources: added System.Web.Util/SearchPattern.cs

svn path=/trunk/mcs/; revision=124659
2009-01-27 14:25:00 +00:00
Marek Habersack 86b4448d43 2009-01-22 Marek Habersack <[email protected]>
* Makefile (net_2_0_dirs): added System.Web - it now depends on
        System.Core, so it needs to be recompiled one more time after
        System.Core is done.

2009-01-22  Marek Habersack  <[email protected]>

        * System.Web.dll.sources: added
        System.Web.Compilation/BuildManagerCacheItem.cs,
        System.Web.Compilation/BuildManagerDirectoryBuilder.cs,
        System.Web.Compilation/BuildProviderGroup.cs

        * Makefile (SYSTEMCORE_DEP): added. Defines SYSTEMCORE_DEP on the
        mcs command line when System.Core is present.
        Added the DEVEL define, which defines DEVEL on the mcs command
        line. This is used to conditionally compile development helper code in
        System.Web.Util.FileUtils (and possibly other stuff later on)

2009-01-22  Marek Habersack  <[email protected]>

        * XsdBuildProvider.cs: added missing BuildProviderAppliesTo
        attribute.

        * BuildProvider.cs: added new internal virtual method,
        ExtractDependencies() whose purpose is to extract virtual path
        dependencies without compiling the code, if possible.
        
        * TemplateBuildProvider.cs: implemented the new
        ExtractDependencies () method which uses regular expressions to
        extract file dependencies from the source without having to
        compile the file.

        * CompilationException.cs: added a new public property, Results,
        which returns the compilation results.

        * BuildProviderGroup.cs: added. A simple class descending from
        List <BuildProvider> which is used to hold a compilation batch -
        that is a collection of BuildProvider instances.

        * BuildManagerDirectoryBuilder.cs: new class which takes care of
        generating compilation batches for the requested virtual path. A
        set of batches is generated from files found in the same virtual
        directory as the requested virtual path and all of the
        dependencies of those files. All files are grouped in batches
        within which no file depends upon its siblings. An attempt is made
        to sort the batches from the "least dependent" to the "most
        dependent" batches - i.e. the batches which do not depend on other
        batches go to the top.
        Code generating the batches now correctly detects dependency loops
        and throws an exception when one is encountered.
        Batches are represented as instances of a new class -
        BuildProviderGroup.

        * BuildManagerCacheItem.cs: added. Contains all the compilation
        result information needed by BuildManager. See below.

        * BuildManager.cs: complete batch building rewrite:
         - only one build lock is held instead of a set of compilation
           tickets. Only one thread can compile anything at one given
           time.
         - retrieving types from the build cache now uses a slim rw lock,
           so that readers aren't blocked while compilation is in
           progress. Writer lock is acquired only when adding a newly
           compiled type to the build cache and when removing it after its
           dependencies made it invalid.
         - assembly references for each compilation are now collected
           dynamically as the source is being compiled, this removed a lot
           of complexity in dealing with assembles containing conflicting
           types. As a consequence right now there may exist several
           loaded assemblies containing the same type, but only the latest
           of them will be used in new compiles.
         - the thread compiling code can recurse into the Build method
           which causes the recursively referenced code to be compiled
           into a separate, uniquely named, assembly. This deals with all
           recursion loops and dependency problems.
         - automatic app domain restart after a certain number of compiles
           is enabled now.
         - improved compilation error handling. If a compilation error
           occurs, the code attempts to recompile the assembly up to 3
           times, each time removing from the batch the files/virtual
           paths which failed parsing/compilation. If the attempts failed,
           another one is made to compile only the virtual path requested
           by the calling code. Only should that fail a compilation
           exception is thrown. All the compilation errors are written to
           stdout if the application is in the debug mode.
         - changed assembly naming. It now generates assembly names based
           on whether the compilation is recursive and whether the batch
           being compiled contains more than one code unit or
           not.
         - compilation results are now stored in the cache as instances of
           the new BuildManagerCacheItem class, which contains all the
           information required by BuildManager to return types,
           assemblies, dependencies etc.
         - GetReferencedAssemblies now correctly returns only the
           assemblies defined in the .config files.
         - GetVirtualPathDependencies does not need to compile code
           anymore in order to extract virtual path dependencies. New code
           in BuildProvider.ExtractDependencies () takes care of that.
         - a BuildManagerDirectoryBuilder class instance is used to
           generate compilation batches.

        * AssemblyBuilder.cs: added support for keeping track of which
        code unit was generated by which BuildProvider andr which
        BuildProvider produced a given source file. Both changes serve the
        purpose of dealing with compilation errors in BuildManager.

        * ApplicationFileBuildProvider.cs: added missing
        BuildProviderAppliesTo attribute

2009-01-22  Marek Habersack  <[email protected]>

        * FileUtils.cs: added two conditionally compiled methods (they
        require DEVEL to be defined) which output lines to a log file.

2009-01-22  Marek Habersack  <[email protected]>

        * WebTest.cs: Run () sets the internal field
        BuildManager.suppressDebugModeMessages to true.

2009-01-22  Marek Habersack  <[email protected]>

        * Web.mono.config: added numRecompilesBeforeAppRestart attribute
        to the compilation element, set to 100000, to avoid appdomain
        restarts during tests.



svn path=/trunk/mcs/; revision=124179
2009-01-22 11:40:22 +00:00
Marek Habersack 2279cf0cf8 2009-01-20 Marek Habersack <[email protected]>
* Substitution.cs: added. Fixes bug #467460

2009-01-20  Marek Habersack  <[email protected]>

	* System.Web.dll.sources: added System.Web.UI.WebControls/Substitution.cs

svn path=/trunk/mcs/; revision=123865
2009-01-20 10:04:10 +00:00
Marek Habersack 6e8c180f09 Reverted r123106
svn path=/trunk/mcs/; revision=123113
2009-01-12 19:42:35 +00:00
Marek Habersack dbd6e55cdc 2009-01-12 Marek Habersack <[email protected]>
* LiteralStringControlBuilder.cs: added. Fixes bug #461214

	* ControlBuilder.cs: added location tracking for literal string
	children. Fixes bug #461214

	* TemplateParser.cs: line pragmas are on by default. Fixes bug
	#460479

2009-01-12  Marek Habersack  <[email protected]>

	* TemplateControlCompiler.cs: the LiteralStringControlBuilder
	class is now used to track the location of the plain strings being
	output to the generated code. Fixes bug #461214

	* AspGenerator.cs: AppendLiteralString is called with the current
	parser location as one of its parameters in FlushText (). Fixes
	bug #461214

2009-01-12  Marek Habersack  <[email protected]>

	* System.Web.dll.sources: added
	System.Web.UI/LiteralStringControlBuilder.cs


svn path=/trunk/mcs/; revision=123106
2009-01-12 18:53:41 +00:00
Dean Brettle af9585a7b3 Changes approved via private email from Marek Habersack <[email protected]> on 2008-10-05.
In System.Web.Configuration_2.0:
2008-12-12  Owen Brady <[email protected]>
	* nBrowser/File.cs, nBrowser/Identification.cs, nBrowser/Node.cs, nBrowser/NodeTypes.cs,
	nBrowser/Result.cs, nBrowser/Build.cs, nBrowser/Exception.cs, CapabilitiesBuild.cs, 
	CapabilitiesResult.cs: Updated Copyright information to include updated contact information.
	
	* nBrowser/Build.cs: Removed LoadDefaultEmbeddedResource function, the embeded resource
	it is referring too was never included in Mono. And was designed for a free standing 
	browser identification libary.

	* nBrowser/Exception.cs: Removed Compile Attributes and related comments which were left
	in from the original free standing browser libary.
	
	* CapabilitiesBuild.cs: Removed Header Checksum related coding since it is not required
	for the Mono implementation.

	* CapabilitiesResult.cs: Updated Copyright information to include updated contact information. 
	Removed functions which were designed to make use of features of a embeded browser file which
	is not present in Mono.
	
	* CapabilitiesChecksum.cs, RandomRoboBotKeywords.txt: Deleted

In .:
2008-12-12  Dean Brettle  <[email protected]>

	* System.Web.dll.sources: deleted
	System.Web.Configuration_2.0/CapabilitiesChecksum.cs
	
	* Makefile (RESOURCE_FILES_2): deleted
	System.Web.Configuration_2.0/RandomRoboBotKeywords.txt


svn path=/trunk/mcs/; revision=121408
2008-12-12 09:43:04 +00:00
Marek Habersack fa32fdf482 2008-11-25 Marek Habersack <[email protected]>
* System.Web.dll.sources: added
	System.Web.Compilation/AspComponent.cs

2008-11-25  Marek Habersack  <[email protected]>

	* RootBuilder.cs: use new API in AspComponentFoundry to retrieve
	registered control type.

	* TemplateControlParser.cs: AddControlImports () removed. Its
	functionality is now implemented in ControlBuilder.AddChild in a
	more elegant, fine grained and correct way.

	* TemplateParser.cs: replaced some "" with String.Empty

	* ControlBuilder.cs: AddChild now adds an import for child's
	namespace if the control being added has been registered in the
	web.config file. Possible fix for #447896 and #447898

	* PageParser.cs, MasterPageParser.cs: do not call
	AddControlImports, it no longer exists.

2008-11-25  Marek Habersack  <[email protected]>

	* AspComponentFoundry.cs: GetComponentType methods replaced with
	GetComponent returning an instance of AspComponent which fully
	describes the registered item. Components are cached, indexed by
	full tag name.

	* AspComponent.cs: added

svn path=/trunk/mcs/; revision=119893
2008-11-25 00:51:21 +00:00
Marek Habersack cd9089259b 2008-11-15 Marek Habersack <[email protected]>
* ContentPlaceHolder.cs, Content.cs, FormViewPagerRow.cs,
	ChangePassword.cs, DetailsViewPagerRow.cs: implements
	INonBindingContainer interface.

	* Wizard.cs: implement INonBindingContainer interface for several
	private/internal classes.

2008-11-15  Marek Habersack  <[email protected]>

	* INonBindingContainer.cs: added

	* Control.cs: BindingContainer now checks if a control implements
	INonBindingContainer interface in addition to the
	BINDING_CONTAINER mask check.

	* UserControl.cs: implements INonBindingContainer

	* ControlBuilder.cs: use the new INonBindingContainer interface to
	determine the binding container type in the BindingContainerType
	property. If TemplateBuilder's ContainerType implements that
	interface, the NamingContainer is queried for the binding
	container type. If ContainerType is null, we return our own
	ControlType (if we're TemplateBuilder)

2008-11-15  Marek Habersack  <[email protected]>

	* System.Web.dll.sources: added System.Web.UI/INonBindingContainer.cs

svn path=/trunk/mcs/; revision=118917
2008-11-15 03:40:24 +00:00
Marek Habersack 1923115250 2008-10-09 Marek Habersack <[email protected]>
* MonoSettingsSection.cs: added - a section for mono-specific
	settings.

2008-10-09  Marek Habersack  <[email protected]>

	* BuildManager.cs: if monoSettings section is found in the
	system.web section in web.config, use its contents to augment
	compiler configuration. Used to work around the issue reported in
	bug #433806

2008-10-09  Marek Habersack  <[email protected]>

	* System.Web.dll.sources: added System.Web.Configuration_2.0/MonoSettingsSection.cs

svn path=/trunk/mcs/; revision=115337
2008-10-09 14:45:06 +00:00
Marek Habersack 45c4d688ac 2008-09-29 Marek Habersack <[email protected]>
* OutputCacheModule.cs: invalidate cache entries when the
	corresponding source file (.as?x) is recompiled by hooking up to
	System.Web.Compilation.BuildManager's build cache entry removal
	event. Fixes bug #429926

2008-09-29  Marek Habersack  <[email protected]>

	* BuildManagerRemoveEntryEventHandler.cs: added

	* BuildManager.cs: added a static event to notify interested
	parties when an entry is removed from the buildCache. Fixes bug
	#429926.

svn path=/trunk/mcs/; revision=114369
2008-09-29 06:53:14 +00:00