I have stated in other thread why China and Russia have strong foundations to maintain good relationship: economic, security, geo-politics, technology and world-view, contrary to what many westerners believe. Here I'd like to add a few historical and personnel dimension.
The historical connection between Russian Revolution and Chinese Revolution. Many early Chinese communist leaders had experiences living or educated in Russia. Russian Revolution has been the inspiration for first-generation Chinese communist leaders. Today, Russia is no longer ruled by communist party, but China is. Russian Revolution has been part of CCP's legend and historical narrative, forming part of the justifications for the historical justice and legitimacy of CCP.
Both the second-generation Chinese leaders (Deng Xiaoping, Chen Yun and others) and third-generation Chinese leaders (Jiang Zeming, Li Peng and others) also have extensive experiences living in Russia and working with many Russians. They had built extensive personal relationships. I read the news that when China and USSR/Russia made up in late '80s and the '90s, Chinese leader Chen Yun had a reunion with one of the USSR deputy prime ministers (forget his name) then whom he worked closely in the '50s. They embraced, tears in the eyes.
The current China-Russia relationship has been built and evolved over multiple generations of leaders on both sides. On the Russia/USSR side, the rapprochement started from Gorbachev, going through Yeltsin and Putin. On the Chinese side, it started from Deng Xiaoping, through Jiang Zemin, Hu Jintao and now to Xi Jinping. It is built on strong national interests, reinforced by good relationships between leaders, including that between Putin and Xi now.
There have been millions of Chinese who love Russian arts, music, literature and science, dating back from the honeymoon days of the '50s.
These are the aspects of the China-Russia relationship that westerners are either unfamiliar with or simply ignore. They like to either make up or exaggerate issues/non-issues.