Re: [Mono-devel-list] System.Web/System.Web.SessionState - patch (code synchronization between Mono and Mainsoft)
I agree, good shot Ben! Attached updated patch. Thank you, Ilya. Ben Maurer wrote: On Wed, 2005-06-08 at 13:17 +0300, Ilya Kharmatsky wrote: InProc = 1, StateServer = 2, SQLServer = 3 +#if TARGET_J2EE + ,J2ee = 4 +#endif It's probably a bad idea to add such a low enumeration value, as msft could add a value here. -- Ben Index: ChangeLog === --- ChangeLog (revision 45568) +++ ChangeLog (working copy) @@ -1,3 +1,12 @@ +2005-06-08 Ilya Kharmatsky ilyak-at-mainsoft.com + +* SessionStateMode.cs: Added TARGET_J2EE directive in order +to provide in J2EE configuration additional mode - J2EE +* SessionStateModule.cs: Added TARGET_JVM directives in order +to resolve unsupported in Ghrasshopper static variables issue +(When static variable are stored in general place, instead of +storing such variables per AppDomain). + 2005-05-27 Gonzalo Paniagua Javier [EMAIL PROTECTED] * RemoteStateServer.cs: Index: SessionStateMode.cs === --- SessionStateMode.cs (revision 45568) +++ SessionStateMode.cs (working copy) @@ -35,6 +35,9 @@ InProc = 1, StateServer = 2, SQLServer = 3 +#if TARGET_J2EE + ,J2ee = 4 +#endif } } Index: SessionStateModule.cs === --- SessionStateModule.cs (revision 45568) +++ SessionStateModule.cs (working copy) @@ -42,8 +42,27 @@ internal static readonly string CookieName = ASPSESSION; internal static readonly string HeaderName = AspFilterSessionId; +#if !TARGET_J2EE static SessionConfig config; static Type handlerType; +#else + static private SessionConfig config { + get { + return (SessionConfig)AppDomain.CurrentDomain.GetData(SessionStateModule.config); + } + set { + AppDomain.CurrentDomain.SetData(SessionStateModule.config, value); + } + } + static private Type handlerType { + get { + return (Type)AppDomain.CurrentDomain.GetData(SessionStateModule.handlerType); + } + set { + AppDomain.CurrentDomain.SetData(SessionStateModule.handlerType, value); + } + } +#endif ISessionHandler handler; bool sessionForStaticFiles; @@ -197,8 +216,10 @@ internal void OnEnd () { +#if !TARGET_J2EE if (End != null) End (this, EventArgs.Empty); +#endif } public event EventHandler Start; ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
Re: [Mono-devel-list] System.Web/System.Web.SessionState - patch (code synchronization between Mono and Mainsoft)
Sorry I've sent the old diff - here is a new one - the value changed to '1024'. Ilya Kharmatsky wrote: I agree, good shot Ben! Attached updated patch. Thank you, Ilya. Ben Maurer wrote: On Wed, 2005-06-08 at 13:17 +0300, Ilya Kharmatsky wrote: InProc = 1, StateServer = 2, SQLServer = 3 +#if TARGET_J2EE + ,J2ee = 4 +#endif It's probably a bad idea to add such a low enumeration value, as msft could add a value here. -- Ben Index: ChangeLog === --- ChangeLog (revision 45568) +++ ChangeLog (working copy) @@ -1,3 +1,12 @@ +2005-06-08 Ilya Kharmatsky ilyak-at-mainsoft.com + +* SessionStateMode.cs: Added TARGET_J2EE directive in order +to provide in J2EE configuration additional mode - J2EE +* SessionStateModule.cs: Added TARGET_JVM directives in order +to resolve unsupported in Ghrasshopper static variables issue +(When static variable are stored in general place, instead of +storing such variables per AppDomain). + 2005-05-27 Gonzalo Paniagua Javier [EMAIL PROTECTED] * RemoteStateServer.cs: Index: SessionStateMode.cs === --- SessionStateMode.cs (revision 45568) +++ SessionStateMode.cs (working copy) @@ -35,6 +35,9 @@ InProc = 1, StateServer = 2, SQLServer = 3 +#if TARGET_J2EE + ,J2ee = 1024 +#endif } } Index: SessionStateModule.cs === --- SessionStateModule.cs (revision 45568) +++ SessionStateModule.cs (working copy) @@ -42,8 +42,27 @@ internal static readonly string CookieName = ASPSESSION; internal static readonly string HeaderName = AspFilterSessionId; +#if !TARGET_J2EE static SessionConfig config; static Type handlerType; +#else + static private SessionConfig config { + get { + return (SessionConfig)AppDomain.CurrentDomain.GetData(SessionStateModule.config); + } + set { + AppDomain.CurrentDomain.SetData(SessionStateModule.config, value); + } + } + static private Type handlerType { + get { + return (Type)AppDomain.CurrentDomain.GetData(SessionStateModule.handlerType); + } + set { + AppDomain.CurrentDomain.SetData(SessionStateModule.handlerType, value); + } + } +#endif ISessionHandler handler; bool sessionForStaticFiles; @@ -197,8 +216,10 @@ internal void OnEnd () { +#if !TARGET_J2EE if (End != null) End (this, EventArgs.Empty); +#endif } public event EventHandler Start; ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
[Mono-devel-list] System.Web/System.Web.SessionState - patch (code synchronization between Mono and Mainsoft)
Please review changes. Thanks, Ilya. Index: ChangeLog === --- ChangeLog (revision 45568) +++ ChangeLog (working copy) @@ -1,3 +1,12 @@ +2005-06-08 Ilya Kharmatsky ilyak-at-mainsoft.com + +* SessionStateMode.cs: Added TARGET_J2EE directive in order +to provide in J2EE configuration additional mode - J2EE +* SessionStateModule.cs: Added TARGET_JVM directives in order +to resolve unsupported in Ghrasshopper static variables issue +(When static variable are stored in general place, instead of +storing such variables per AppDomain). + 2005-05-27 Gonzalo Paniagua Javier [EMAIL PROTECTED] * RemoteStateServer.cs: Index: SessionStateMode.cs === --- SessionStateMode.cs (revision 45568) +++ SessionStateMode.cs (working copy) @@ -35,6 +35,9 @@ InProc = 1, StateServer = 2, SQLServer = 3 +#if TARGET_J2EE + ,J2ee = 4 +#endif } } Index: SessionStateModule.cs === --- SessionStateModule.cs (revision 45568) +++ SessionStateModule.cs (working copy) @@ -42,8 +42,27 @@ internal static readonly string CookieName = ASPSESSION; internal static readonly string HeaderName = AspFilterSessionId; +#if !TARGET_J2EE static SessionConfig config; static Type handlerType; +#else + static private SessionConfig config { + get { + return (SessionConfig)AppDomain.CurrentDomain.GetData(SessionStateModule.config); + } + set { + AppDomain.CurrentDomain.SetData(SessionStateModule.config, value); + } + } + static private Type handlerType { + get { + return (Type)AppDomain.CurrentDomain.GetData(SessionStateModule.handlerType); + } + set { + AppDomain.CurrentDomain.SetData(SessionStateModule.handlerType, value); + } + } +#endif ISessionHandler handler; bool sessionForStaticFiles; @@ -197,8 +216,10 @@ internal void OnEnd () { +#if !TARGET_J2EE if (End != null) End (this, EventArgs.Empty); +#endif } public event EventHandler Start; ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list