  This paper considers a general stochastic resource allocation problem that
arises widely in wireless networks, cognitive radio, networks, smart-grid
communications, and cross-layer design. The problem formulation involves
expectations with respect to a collection of random variables with unknown
distributions, representing exogenous quantities such as channel gain, user
density, or spectrum occupancy. We consider the constant step-size stochastic
dual subgradient descent (SDSD) method that has been widely used for online
resource allocation in networks. The problem is solved in dual domain which
results in a primal resource allocation subproblem at each time instant. The
goal here is to characterize the non-asymptotic behavior of such stochastic
resource allocations in an almost sure sense.
  It is well known that with a step size of $\epsilon$, {SDSD} converges to an
$\mathcal{O}(\epsilon)$-sized neighborhood of the optimum. In practice however,
there exists a trade-off between the rate of convergence and the choice of
$\epsilon$. This paper establishes a convergence rate result for the SDSD
algorithm that precisely characterizes this trade-off. {Towards this end, a
novel stochastic bound on the gap between the objective function and the
optimum is developed. The asymptotic behavior of the stochastic term is
characterized in an almost sure sense, thereby generalizing the existing
results for the {stochastic subgradient} methods.} For the stochastic resource
allocation problem at hand, the result explicates the rate with which the
allocated resources become near-optimal. As an application, the power and
user-allocation problem in device-to-device networks is formulated and solved
using the {SDSD} algorithm. Further intuition on the rate results is obtained
from the verification of the regularity conditions and accompanying simulation
results.
