Mataram–Srivijayan wars
Mataram–Srivijayan wars, also called as Pralaya in Pucangan inscription, were a military engagements between two rival kingdoms of the Srivijaya of Shailendra and Mataram kingdom of Ishana, intermittently from when the Srivijayan forces attempted to approach the Mataram capital, until 1016 when the kingdom of Mataram was collapsed due to a rebellion incited by Srivijaya.
Background
The monarch of the Mataram kingdom way before the eastern rule of Ishana was Samaratungga of the Shailendra dynasty. He had one son, Balaputradewa, and one daughter, Pramodhawardhani. The successor of Samaratungga was his Buddhist daughter, Pramodhawardhani that betrothed to Rakai Pikatan of Sanjaya, son of the influential Rakai Patapan, a landlord in Central Java. Rakai Pikatan and the Sanjaya dynasty were Shivaite Hindus and are recorded in the Shivagrha inscription as having married a daughter of another religion.However, Balaputra opposed the rule of Pikatan and Pramodhawardhani. The relations between Balaputra and Pramodhawardhani is interpreted differently by some historians. According to Bosch and De Casparis holds that Balaputra was the son of Samaratungga, which means he was the younger brother of Pramodhawardhani. Later historians such as Muljana, argued that Balaputra was the son of Samaragrawira and the younger brother of Samaratungga, which means he was the uncle of Pramodhawardhani.
It is not known whether Balaputra was expelled from Central Java because of succession dispute with Pikatan, or was he already ruled in Suvarnadvipa. Either ways, it seems that Balaputra eventually ruled the Sumatran branch of Shailendra dynasty and enthroned in Srivijayan capital of Palembang. Historians argued that this was because Balaputra's mother—Tara, the queen consort of King Samaragrawira was the princess of Srivijaya, this rendered Balaputra as the heir of Srivijayan throne. Balaputra, the Maharaja of Srivijaya later stated his claim as the rightful heir of Shailendra dynasty from Java, as proclaimed in Nalanda inscription dated 860.
In, the centre of the kingdom was shifted from Central Java to East Java by Mpu Sindok, who established a new dynasty, Ishana dynasty, named after his daughter. The exact cause of the move is still uncertain. Historians have proposed various possible causes; from natural disaster, epidemic outbreak, politics and power struggle, to religious or economic motives.
One of the proposed causes of the move is a politics and power struggle. Coedes suggested that the move to East Java was probably in response to the Buddhist Shailendra dynasty. This theory is inline with the one proposed by J.G. de Casparis which suggests that the shift of capital city eastward was to avoid a Srivijayan invasions from Sumatra.
However, De Casparis then expands his theory that it was most likely motivated by economic reasons, saying that the location of the kingdom in Central Java was less accessible than East Java. The Brantas river valley was considered to be a strategic location, as the river provides easy access to reach ports on East Java's north coast and Java Sea, strategic for the control of maritime trade routes to the eastern parts of archipelago, being especially vital for control of the Maluku spice trade. But the reasons of the move are still unclear.
History
Malayu invasion of 937
According to J.G. de Casparis, the villagers of Anjukladang was awarded for their service and merit on assisting the king's forces — under the leadership of Mpu Sindok, to repel the invading Malayu army that tried to approach the capital and has reached the area near Nganjuk. This means, the relations between Mataram kingdom with Srivijaya has badly deteriorated to the state of hostility. In addition, According to de Casparis, the Anjukladang inscription mentioned that Mpu Sindok has erected a monument of victory after successfully repelled the invasion of Malayu, and in the year, the monument was replaced by a temple. Most likely, the sacred building mentioned in this inscription was referring to the Lor temple, a temple ruins made of red bricks located in the Candirejo village.The animosity was probably caused by the Srivijayan effort to reclaim Shailendran lands in Java, or by Mataram aspirations to challenge Srivijaya dominance as the regional power.
Mataram invasion of Srivijaya (990–1006)
In 990, Dharmawangsa launched a naval invasion against Srivijaya in an attempt to capture Palembang. The news of Javanese invasion of Srivijaya was recorded in Chinese accounts from Song period. In 988, an envoy from Srivijaya was sent to Chinese court in Guangzhou. After sojourned for about two years in China, the envoy learned that his kingdom has been attacked by the Javanese Mataram, thus made him unable to return home.The hostility between Srivijaya and Mataram was confirmed by the Javanese envoy. In 992, the envoy from Mataram arrived in Chinese court and explaining that their country has involved in continuous war with Srivijaya. In the same year, Mataram was succeeded in capturing Palembang for a while, but then Mataram forces were repulsed by Srivijayan troops.
In 999, the Srivijayan envoy sailed from China to Champa in an attempt to return home, however he received no news about the condition of his kingdom. The Srivijayan envoy then sailed back to China and appealed Chinese emperor for the protection of Srivijaya from Javanese invaders.
Dharmawangsa's campaign against Srivijaya led the Sri Cudamani Warmadewa, Maharaja of Srivijaya to seek protection to China. In the midst of crisis brought by Javanese invasion, he secured Chinese political support by appeasing the Chinese emperor. In 1003, a Song historical record reported that the envoy of Srivijaya dispatched by Sri Cudamani Warmadewa, informed that a Buddhist temple had been erected in their country to pray for the long life of Chinese emperor, thus asked the emperor to give the name and the bell for this temple which was built in his honour. Rejoiced, the emperor named the temple Ch'eng-t'en-wan-shou and a bell was immediately cast and sent to Srivijaya to be installed in the temple.
By 1005, Srivijaya started to appear victoriously. In 1006, Srivijayan alliance proved its resilience by successfully repelling the Javanese invasion, The invasion was ultimately unsuccessful. This attack has opened the eyes of Srivijayan Maharaja of how dangerous Javanese Mataram could be, and further contemplate, patiently laid a plan and effort to destroy his Javanese nemesis.
Cudamani Warmadewa died in, He was succeeded by his heir, Sri Maravijayottungavarman.
Wurawari rebellion
In 1016, Srivijaya launched a retaliation attack and destroyed the Wwatan Palace in Java, by assisting the lesser king of Mataram vassal polity, Wurawari of Lwaram to revolt, attacked and destroyed the Mataram palace. The reason Wurawari rebelled was because previously, he wanted to marry the daughter of Dharmawangsa. He wants to replace Dharmawangsa and become the ruler of Mataram. However, his proposal was rejected, and Dharmawangsa chose Airlangga, son of Udayana Warmadewa of Bali and Mahendradatta, as his son-in-law. Wurawari was vengeful, he allied with Srivijaya to help attack the palace. The sudden and unexpected attack took place during the wedding ceremony of Dharmawangsa's daughter, which left the court unprepared and shocked — killing Dharmawangsa and most of the royal family.This calamity was recorded in Javanese account as the Pralaya ; "the death of the Mataram kingdom". With the death of Dharmawangsa and the fall of Mataram capital under military pressure from Srivijayan forces assisting Wurawari, Srivijaya contributed to the collapse of Mataram kingdom, leaving central and eastern Java in further unrest, violence and, ultimately, desolation for several years to come. With the absence of Mataram paramount ruler, warlords in regional provinces and settlements in central and eastern Java rebelled and break loose from the central Mataram government and forming their own polities serving local dynasties. Raids and robbery were rampant ravaging the country. There was further unrest and violence several years after the kingdom's demise.