Re: Can JCIFS subscribe to a file change modification from SMB?
Michael B Allen <[email protected]> Sat, 17 Nov 2012 12:55:28 -0500
| Newsgroups | gmane.network.samba.java |
|---|---|
| Message-ID | <CAGMFw4jPBf0bWPsd4eXZwNL8hYw575yuXtUhEHgeVM07mSj_3Q@mail.gmail.com> |
True. Msrpc is not applicable. Thx for the correction. M On Nov 14, 2012 12:32 PM, "Christopher R. Hertel" <[email protected]> wrote: > The NT_TRANSACT_NOTIFY_CHANGE request is an SMB transaction, not an MS-RPC > call. It is carried within an SMB_COM_NT_TRANSACT exchange, and MS-RPC > messages are transported over SMB_COM_TRANSACTIONs which are a little bit > different. > > The SMB and MS-RPC mechanisms are quite similar, however, and that may be > what Mike means here. > > Note that any outstanding notification request counts against the > MaxMpxCount limit. > > Chris -)----- > > On 11/14/2012 10:51 AM, Michael B Allen wrote: > >> On Thu, Oct 11, 2012 at 3:39 PM, rickbliss <[email protected]> wrote: >> >>> It looks as though SMB supports a notification event when a directory is >>> changed [http://msdn.microsoft.com/en-**us/library/ee380523(prot.20).** >>> aspx <http://msdn.microsoft.com/en-us/library/ee380523(prot.20).aspx>] ; >>> however, i am having diffuculty implementing this with JCIFS. i dont >>> want >>> to store an array and poll for changes, i would think that JCIFS could >>> subscribe , or recognize a change event? Please help. >>> >> >> Hi Rick, >> >> JCIFS does not implement the file change event part of the protocol. >> >> But it does have a pretty good MS-RPC framework under the hood that >> users have been successful in using to implement new functionality. >> You could add a method like >> SmbFile.addNotifyHandler(**FileChangeHandler) and then call-back if >> something changes and so on. Look at jcifs.smb.SID.getServerSid as a >> good self-contained starting point for making an MS-RPC call. If you >> do the work, please post a patch. >> >> Also look in the patches directory to make sure someone has not >> already submitted the work. >> >> Mike >> >> > -- > "Implementing CIFS - the Common Internet FileSystem" ISBN: 013047116X > Samba Team -- http://www.samba.org/ -)----- Christopher R. Hertel > jCIFS Team -- http://jcifs.samba.org/ -)----- ubiqx development, > uninq. > ubiqx Team -- http://www.ubiqx.org/ -)----- [email protected] > OnLineBook -- http://ubiqx.org/cifs/ -)----- [email protected] >