#1 mORMot 2 » TZipRead.Create from TStream » 2023-06-08 07:16:48

redhan_xp
Replies: 1

hi ab:

I need TZipRead to read from TStream as follows:

TZipRead. Create (AStream: TStream; Size: PtrInt; Offset: Int64);


I can modify the mormot.core.zip source code and add it myself, but it will be overwritten after the update.

#3 mORMot 2 » How to use SynBigTable in mORMot 2 ? Is there a replacement? » 2023-04-21 14:37:37

redhan_xp
Replies: 3

As per the question, how to use SynBigTable in mORMot 2 ? Is there a replacement?

#5 mORMot 2 » TWebSocketAsyncServer - THttpServerRequest Recycle » 2023-04-11 02:50:23

redhan_xp
Replies: 2

When reusing THttpServerRequest in TWebSocketAsyncServer, RespStatus was not reset:=0;
Causing subsequent judgment errors

#6 Re: mORMot 2 » TURiRouter.add » 2023-03-23 15:05:36

Thank you ab, I only use the THttpServerGeneric framework

#7 mORMot 2 » TURiRouter.add » 2023-03-23 01:12:44

redhan_xp
Replies: 2

I need to add a find method to the TURiRouter class to determine whether it exists in the OnBeforeBody event. If it does not, access will be denied.


function TURiRouter.Find(const aUri, aMethod: RawUtf8): TUriTreeNode;

or


function TURiRouter.Find(const aUri, aMethod: RawUtf8): TUriTreeNodeData;

Is the proposal feasible




If possible, it is best to temporarily store the find results for use by THttpServerRequest, such as: THttpServerRequest. fRoute?

#8 Re: mORMot 2 » THttpServerRequest create? » 2023-03-20 10:15:33

I need to implement the interface and try it out for the dll. Let me handle it in a different way, thank you

#9 Re: mORMot 2 » THttpServerRequest create? » 2023-03-20 03:31:57

THttpServerRequest.create ?


mormot.net.async.pas:   (row 3366)
3364             HTTP_UPG_FLAGS[hfConnectionUpgrade in fHttp.HeaderFlags];
3365    if fRequest = nil then // created once, if not rejected by OnBeforeBody
3366:     fRequest := THttpServerRequest.Create(
3367        fServer, fConnectionID, fReadThread, flags, @fConnectionOpaque)
3368    else


mormot.net.server.pas:   (3082;  4088)
3081    // compute the response
3082:   req := THttpServerRequest.Create(self, ConnectionID, ConnectionThread,
3083      HTTP_TLS_FLAGS[ClientSock.TLS.Enabled] +
3084      HTTP_UPG_FLAGS[hfConnectionUpgrade in ClientSock.Http.HeaderFlags],
....
4086      if global_verbs[hvOPTIONS] = '' then
4087        global_verbs := VERB_TEXT;
4088:     ctxt := THttpServerRequest.Create(self, 0, self, [], nil);
4089      // main loop reusing a single ctxt instance for this thread
4090      reqid := 0;

#10 Re: mORMot 2 » THttpServerRequest create? » 2023-03-20 03:15:59

Thank you. I didn't find the ComputeContext method before.

#11 mORMot 2 » THttpServerRequest create? » 2023-03-19 01:56:57

redhan_xp
Replies: 6

Hello Ab,


I want to implement THttpServerRequest inheritance,

For example: TWebSocketAsyncServer.ProcessClass

#12 Re: mORMot 2 » websocket parse bug » 2023-03-18 09:04:28

until P^ <> ' ';

test ok, thanks

#13 mORMot 2 » websocket parse bug » 2023-03-18 07:21:20

redhan_xp
Replies: 2

CONNECTION: KEEP-ALIVE, UPGRADE

mormot.net.http 

1374                repeat
1375                  inc(P);
1376                until P^ <= ' ';
                      Inc(P); // add ok

Board footer

Powered by FluxBB