Support for intelligent and autonomous resource management is one key factor to the success of modern sensor network systems. The limited resources, such as exhaustible battery life, moderate processing ability and finite bandwidth, restrict the system's ability to serve multiple users simultaneously. It always happens that only a subset of tasks is selected with the goal of maximizing total profit. Besides, because of uncertain factors like unreliable wireless medium or variable quality of sensor outputs, it is not practical to assume that both demands and profits of tasks are deterministic and known a priori, both of which may be stochastic following certain distributions. In this paper, we model this resource allocation challenge as a stochastic knapsack problem. We study a specific case in which both demands and profits follow normal distributions, which are then extended to Poisson and Binomial variables. A couple of tunable parameters are introduced to configure two probabilities: one limits the capacity overflow rate with which the combined demand is allowed to exceed the available supply, and the other sets the minimum chance at which expected profit is required to be achieved. We define relative values for random variables in given conditions, and utilize them to search for the best resource allocation solutions. We propose heuristics with different optimality/ efficiency tradeoffs, and find that our algorithms run relatively fast and provide results considerably close to the optimum.