The URL-encoded form data is not valid.

If you are having a problem using Vault, post a message here.

Moderator: SourceGear

Post Reply
kkchan
Posts: 54
Joined: Wed Jun 30, 2010 12:45 am

The URL-encoded form data is not valid.

Post by kkchan » Thu Mar 08, 2012 3:24 am

Hi
I faced the error as subject when try to undo check-out some item.
I tried to add the below to web.config, not not helping. Any ideas? Thank you

<add key="aspnet:MaxHttpCollectionKeys" value="2000" />

lbauer
Posts: 9736
Joined: Tue Dec 16, 2003 1:25 pm
Location: SourceGear

Re: The URL-encoded form data is not valid.

Post by lbauer » Thu Mar 08, 2012 9:11 am

We've had a few reports of this from users who were trying to undo checkouts and had a large number of checkouts on the Vault Admin Web Client Undo Checkout page.

This is a known issue created by a recent Windows update that creates limits on the amount of data on a webpage in .Net.

The errors are:
Inner Exception: The URL-encoded form data is not valid.
Inner Exception: Operation is not valid due to the current state of the object.
http://technet.microsoft.com/en-us/secu ... 1-100.mspx

The workaround is to add this line in the app settings section of the Vault Service web.config file:

<appSettings> <!-- THIS LINE SHOULD ALREADY EXIST -->
<add key="aspnet:MaxHttpCollectionKeys" value="xxxx" />
</appSettings> <!-- THIS LINE SHOULD ALREADY EXIST -->

We're still doing testing but it looks like the "xxxx" value needs to be roughly 3x the number of checkouts. Right now I have MaxHttpCollectionKeys set to 5000 and I'm able to undo checkout when there are about 1600 files checked out.

So if you have 2000 files checked out your web config entry should look like this:

<add key="aspnet:MaxHttpCollectionKeys" value="6000" />

Note that you might need to experiment with this value -- might need to be a bit more.

To determine the total number of checkouts, look in the sgvault database, table dbo.tblcheckoutlists. It's the Colistitemcount number in the last row of the table.


We plan to address this in Vault 6.0 by creating tabbed pages for Undo Checkout.
Linda Bauer
SourceGear
Technical Support Manager

davenovak
Posts: 222
Joined: Mon Jan 15, 2007 2:15 pm
Location: Atlanta, GA

Re: The URL-encoded form data is not valid.

Post by davenovak » Mon Mar 12, 2012 8:30 am

Adding that line above did resolve the issue -- thanks!

As to Vault 6.0, I would like to hope that you are considering showing the Undo Checkout List in a hierarchical fashion rather than always showing all checkouts for the entire repository. In other words, I'd like the ability to filter by a particular branch within the repository rather than seeing everything that's checked out. This would really help me navigate easier to the file I need to undo especially when lots of files are checked out.

lbauer
Posts: 9736
Joined: Tue Dec 16, 2003 1:25 pm
Location: SourceGear

Re: The URL-encoded form data is not valid.

Post by lbauer » Mon Mar 12, 2012 8:59 am

Thanks for the feedback. I've added your comments to work item 16136, which addresses this bug.
Linda Bauer
SourceGear
Technical Support Manager

Post Reply