locked
Question about the Bidi communication when using IPrinterQueue::Refresh

    Question

  • When using IPrinterQueue::Refresh to I am only getting up-to-date information after the 2nd call.  

    I have a network printer which I can query using SNMP and it is installed as a print queue.  When I start my printer extension in Metro from a print job I send a bidi query using IPrinterQueue::Refresh and I get printer data back.  Although, if I change a setting on the printer, verify the change through an SNMP browser, and then execute a bidi query I do not get correct data.  Instead I would see the previous value for the setting until I perform the bidi query again. 

    Is the method IPrinterQueue::Refresh supposed to retrieve(through the resulting event) up-to-date information from the printer?

    Thursday, February 16, 2012 1:21 AM

Answers

  • Hi jftrc,

    SendBidiQuery returns using cached data to ensure that there is always data available. . When this API is called, we kick off a query to the printer in parallel to update the cache. We also update the cache at some predetermined intervals, and when we get events from the printer that the configuration has changed (such as over WSD).

    Thanks!

    Justin

    Tuesday, March 13, 2012 3:04 AM

All replies

  • jfrtc,

    I will look into this for you.

    Best Wishes - Eric

    Monday, March 12, 2012 8:15 PM
    Moderator
  • Hi Eric,

    This question was for the DP.  However for CP it should now be:

    Does IPrinterQueue::SendBidiQuery retrieve up-to-date information (through the resulting event) from the printer or is it retrieved from a cache that updates at fixed intervals?

    Monday, March 12, 2012 9:02 PM
  • Hi jftrc,

    SendBidiQuery returns using cached data to ensure that there is always data available. . When this API is called, we kick off a query to the printer in parallel to update the cache. We also update the cache at some predetermined intervals, and when we get events from the printer that the configuration has changed (such as over WSD).

    Thanks!

    Justin

    Tuesday, March 13, 2012 3:04 AM
  • Hi Justin,

    Thanks for the answer.  Currently I can disconnect my computer from the network (and consequently the printer) and still get cached responses from the printer from from the time it was last seen.  Is this the intended effect?


    -Jeff

    Wednesday, March 14, 2012 1:38 AM
  • Yes. That's the intended behavior.

    Thanks!

    Justin

    Wednesday, March 14, 2012 4:52 PM
  • Justin,

    Can you expound on the "predetermined intervals"?  I'm curious how often the bidi cache gets updated.  Moreover, is there a way I can force an update?

    Thanks,
    Lance

    Wednesday, February 20, 2013 8:12 PM