JD.com has laid a foundation for good long-term growth, though its stock could be due for a pullback after reaching an all-time high, analysts said on Tuesday, after China’s No. 2 e-commerce company posted its first-ever profit. On Monday the company posted a net profit of 355.7 million yuan ($51.5 million) for the three months through March, compared with a loss of 867.3 million yuan a year earlier. The surprise profit sparked an 8% rally for JD.com’s American Depositary Shares, sending them to an all-time high of $38.55 in Monday trading, Caixin reports. Following that jump, the stock is nearly double its levels from July. Analysts said the rally is a reward for investors who waited patiently for years while JD.com plowed money into new investments and aggressive marketing to compete with the larger Alibaba. Alibaba commands more than half of China’s B2C e-commerce market, while JD.com controls about one quarter.