1Sa 1:11 And she vowed a vow and said, “O LORD of hosts, if you will indeed look on the affliction of your servant and remember me and not forget your servant, but will give to your servant a son, then I will give him to the LORD all the days of his life, and no razor shall touch his head.”
Hannah appears to be the first to ever use the phrase “the Lord of hosts or armies”. She acknowledged the greatness of God who has all creation under His jurisdiction. This was her way of saying that there was nothing impossible with God. The praise led her to present this special request ”Remember your servant, give your servant a son”. Point no. 2, She was specific in asking, she asked not for any child but the kind of a child, a son. This was the burden Hannah in prayer; and the strong preference she expressed for a male child originated in her purpose of dedicating him to the tabernacle service.
James addresses two groups of people, those who don’t ask and those who ask a miss. Hannah was in neither of those groups. Her focus in the prayer was for God’s service and glory, that is to give back to God what comes from God. It is very proper, when we are in pursuit of any mercy, to bind our own souls with a bond, that, if God give it us, we will devote it to His honor and cheerfully use it in His service.