Opened 10 years ago
Last modified 9 years ago
#2382 assigned task
Improve regex in String2XMLSerializer
Reported by: | ascheibe | Owned by: | epitzer |
---|---|---|---|
Priority: | medium | Milestone: | HeuristicLab 3.3.x Backlog |
Component: | General | Version: | 3.3.11 |
Keywords: | Cc: |
Description
I ran into the limitation that arrays are not allowed to be larger than 2GB in total size. I propose to enable support for larger arrays in .NET. This is a new option that came with .NET 4.5 and can be enabled by putting <runtime>
<gcAllowVeryLargeObjects enabled="true" />
</runtime> into the app.config. See https://msdn.microsoft.com/en-us/library/hh285054%28v=vs.110%29.aspx for more details.
Change History (4)
comment:1 Changed 10 years ago by ascheibe
- Owner changed from ascheibe to architects
- Status changed from new to assigned
comment:2 Changed 10 years ago by ascheibe
comment:3 Changed 10 years ago by ascheibe
- Owner changed from architects to epitzer
- Summary changed from Add support for large arrays to Improve regex in String2XMLSerializer
There is a regex in String2XMLSerialilzer that maybe could be improved to reduce memory consumption:
private static readonly Regex re = new Regex(@"<!\[CDATA\[((?:[^]]|\](?!\]>))*)\]\]>|<Base64>([<]*)</Base64>", RegexOptions.Singleline);
Could you have a look at it? It may be a problem with backtracking?
comment:4 Changed 9 years ago by ascheibe
- Milestone changed from HeuristicLab 3.3.12 to HeuristicLab 3.3.x Backlog
I discussed this with epitzer. The regex seems to be ok so the reason for this problem is the big hive job. As the gcAllowVeryLargeObjects flag is not an option there is no quick way to fix this at the moment.
Example of such an exception: