This piece is indeed in ternary form.
The A section at the beginning runs for the first 14-15 bars following a two bar introduction. There is a half cadence in measure 6 followed by a PAC in the dominant key (of B major) in both endings (this section repeats at the double bar). I would call this section a parallel period, although asymmetric because the first phrase is 4 measures long and the second is 8.
The B section begins at measure 16. Although there is not a huge contrast from the A section, the right hand rhythms change and the tonality also differs. The A section does not return until measure 29 (with the pickup note in m. 28). It is almost exactly the same as the beginning expository section until about measure 40. For the most part, though, the harmonic goals are similar and the piece eventually ends in the beginning key.