There is 3 kind of discrete log problem as you explained :

1. Diffie-Hellman problem (Dlog):<br>
Pick $a \in \{1,\ldots,q\}$. Compute $A = g^a (mod\ p)$<br>
Given $(p,q,g,A)$ find $a$.<br>
Assumed hard.

2. Computational Diffie-Hellman problem (CDH) :<br>
Pick $a,b \in \{1,\ldots,q\}$. Compute $A = g^a (mod\ p)$ and $B = g^b (mod\ p)$<br>
Given $(p,q,g,A,B)$ find $g^{ab}$.<br>

Note that solving the DH problem solves the CDH problem.

3. Decisional Diffie-Hellman problem (DDH) :<br>
Pick $a,b,c \in \{1,\ldots,q\}$. Compute $A = g^a (mod\ p)$ and $B = g^b (mod\ p)$<br>
Given $(p,q,g,A,B)$ distinguish $g^{ab}$ from $g^{c}$.<br>

In any of these problems, the goal is to find the $a$ or $b$. In your question you are giving them, therefore there is no complexity (as the generator $g$ of a sub-group of $\mathbb{Z}/p\mathbb{Z}$ is usually provided).