0.9.0pre1:
* PEERINFO:
- trust: need *fast* way to check/update trust in peers
- (async peerinfo would not be right; certainly not with the
- current API)
+ (async peerinfo would not be right; certainly not with the current API)
+* STATISTICS:
+ - does not seem to work with timeouts (especially if service is not running)
* UTIL:
- - scheduler should change OS process priority based on task priority;
- should make better use of task priorities in general
- only connect() sockets that are ready (select()) [Nils]
[On W32, we need to select after calling socket before
doing connect etc.]
-* SETUP:
- - design & implement new setup tool
-* TBENCH: [MW]
- - good to have for transport/DV evaluation!
-* DV: [Nate]
- - write DV API (need to move declarations from dv_api.c to gnunet_dv_service.h!)
- - implement DV service
- - implement DV library (looks done)
- - implement DV transport plugin
- - implement testcases
- - implement performance tests
-* STATISTICS:
- - does not seem to work with timeouts (especially if service is not running)
* TOPOLOGY:
- needs more testing (especially F2F topology)
- needs to re-try connecting after disconnect (currently, it
more balanced load)
- check if new HELLO learned is different from old HELLO
before resetting entire state!
+* DATASTORE:
+ - API lacks cancellation methods (needed? or is disconnect enough?);
+ may also want to integrate request queuing here instead of gnunet-service-fs_drq.c
* FS: [CG]
- support recursive download even if filename is NULL and we hence
do not generate files on disk (use temp_filename)
- [gnunet-service-fs.c:700]: member 'ConnectedPeer::last_client_replies_woff' is never used
- GAP improvements:
+ active reply route caching design & implementation of service; gap extension!
-* DATASTORE:
- - API lacks cancellation methods (needed? or is disconnect enough?);
- may also want to integrate request queuing here instead of gnunet-service-fs_drq.c
+* TBENCH: [MW]
+ - good to have for transport/DV evaluation!
+* DV: [Nate]
+ - write DV API (need to move declarations from dv_api.c to gnunet_dv_service.h!)
+ - implement DV service
+ - implement DV library (looks done)
+ - implement DV transport plugin
+ - implement testcases
+ - implement performance tests
* GNUNET-GTK:
- use g_main_context_set_poll_func to integrate GTK with GNUnet Scheduler!? (YUCK!)
- OR: add scheduler API to enable integration with GTK main loop instead of doing our own select
- use g_main_context_pending, g_main_context_query / g_main_context_check / g_main_context_dispatch
and NEVER g_main_loop_run (can this be done? might be the clean way to do this! But how
- to integrate this with "tak_main"? Docu says:
+ to integrate this with "gtk_main"? Docu says:
"It's OK to use the GLib main loop directly instead of gtk_main(), though it involves
slightly more typing. See GMainLoop in the GLib documentation."
=> so maybe it "just works"?
+* SETUP:
+ - design & implement new setup tool
0.9.0pre2:
* TRACEKIT: [MW]
enum GNUNET_SCHEDULER_Priority prio)
{
int rprio = 0;
+ int have;
+ int delta;
GNUNET_assert (prio < GNUNET_SCHEDULER_PRIORITY_COUNT);
if (prio == GNUNET_SCHEDULER_PRIORITY_KEEP)
/* convert to MINGW/Unix values */
switch (prio)
{
- case GNUNET_SCHEDULER_PRIORITY_DEFAULT:
+ case GNUNET_SCHEDULER_PRIORITY_UI:
+ case GNUNET_SCHEDULER_PRIORITY_URGENT:
#ifdef MINGW
- rprio = NORMAL_PRIORITY_CLASS;
+ rprio = HIGH_PRIORITY_CLASS;
#else
rprio = 0;
#endif
break;
+
case GNUNET_SCHEDULER_PRIORITY_HIGH:
#ifdef MINGW
rprio = ABOVE_NORMAL_PRIORITY_CLASS;
#else
- rprio = -5;
+ rprio = 5;
#endif
break;
- case GNUNET_SCHEDULER_PRIORITY_BACKGROUND:
+
+ case GNUNET_SCHEDULER_PRIORITY_DEFAULT:
#ifdef MINGW
- rprio = BELOW_NORMAL_PRIORITY_CLASS;
+ rprio = NORMAL_PRIORITY_CLASS;
#else
- rprio = 10;
+ rprio = 7;
#endif
break;
- case GNUNET_SCHEDULER_PRIORITY_UI:
- case GNUNET_SCHEDULER_PRIORITY_URGENT:
+
+ case GNUNET_SCHEDULER_PRIORITY_BACKGROUND:
#ifdef MINGW
- rprio = HIGH_PRIORITY_CLASS;
+ rprio = BELOW_NORMAL_PRIORITY_CLASS;
#else
- rprio = -10;
+ rprio = 10;
#endif
break;
+
case GNUNET_SCHEDULER_PRIORITY_IDLE:
#ifdef MINGW
rprio = IDLE_PRIORITY_CLASS;
#ifdef MINGW
SetPriorityClass (GetCurrentProcess (), rprio);
#else
- if (proc == getpid ())
+ if ( (0 == proc) ||
+ (proc == getpid () ) )
{
+ have = nice (0);
+ delta = rprio - have;
errno = 0;
- if ((-1 == nice (rprio)) && (errno != 0))
+ if ( (rprio != 0) &&
+ (-1 == nice (delta)) &&
+ (errno != 0) )
{
GNUNET_log_strerror (GNUNET_ERROR_TYPE_WARNING |
GNUNET_ERROR_TYPE_BULK, "nice");
*/
#include "platform.h"
#include "gnunet_common.h"
+#include "gnunet_os_lib.h"
#include "gnunet_scheduler_lib.h"
#include "gnunet_signal_lib.h"
#include "gnunet_time_lib.h"
*/
enum GNUNET_SCHEDULER_Priority current_priority;
+ /**
+ * How 'nice' are we right now?
+ */
+ int nice_level;
+
};
GNUNET_assert (pos != NULL); /* ready_count wrong? */
sched->ready[p] = pos->next;
sched->ready_count--;
- sched->current_priority = pos->priority;
+ if (sched->current_priority != pos->priority)
+ {
+ sched->current_priority = pos->priority;
+ GNUNET_OS_set_process_priority (0, pos->priority);
+ }
sched->active_task = pos;
tc.sched = sched;
tc.reason = pos->reason;