เพิ่งทดลองใช้ activemq สั่ง run ครั้งแรก พบ error

java.io.IOException: Transport Connector could not be registered in JMX: Illegal character in hostname at index 14: tcp://firstname_lastname:61616

งงว่าเพราะอะไร จึงเกิด error ขึ้น eror แจ้งว่า 'Illegal character in hostname'

 

ค้นไปหามา พบว่าสาเหตุเกิดมาจากชื่อเครื่องคอมพิวเตอร์นี่เอง ใช้ "_" (underscore) ซึ่งผิดกฏของ RFC 2396 (URI spec)

mark = "-" | "_" | "." | "!" | "~" | "*" | "'" | "(" | ")"

 

ก็เลยไปเปลี่ยนชื่อเครื่อง คราวนี้ทำงานได้ตามปกติ smile.gif

Links
activemq