I created an example for gazebo_ros2_control based on a prismatic joint but reviewing the code I checked that is only going to work for a prismatic joint smaller than [-3.14, 3.14]. I don't see how the joint type is defined in the code.
In ROS 1 is defined using the UDRF