[SOLVED] Rule not finding HTTP item

I’m trying to send some commands to other items when item SONOS_LIVINGROOM receives the PLAY command
rule looks liek this:

rule "Start Sonos playing"
when
	Item SONOS_LIVINGROOM received command PLAY
then
	YAMAHA_RXV675.sendCommand(POWER_ON)
	Thread::sleep(1)
	YAMAHA_RXV675.sendCommand(Scene_Sel_Scene_3)
	YAMAHA_RXV675.sendCommand(Input_Sel_AV1)
	YAMAHA_RXV675.sendCommand(Program_Sel_Current_Sound_Program_7ch_Stereo)
	
	Sonos_Livingroom_Control.sendCommand(PLAY)
end

The point is in the logfile I see the message “2018-01-15 03:10:40.959 [ERROR] [ntime.internal.engine.RuleEngineImpl] - Rule ‘Start Sonos playing’: The name ‘YAMAHA_RXV675’ cannot be resolved to an item or type; line 8, column 2, length 13”

So it doesn’t find the Item “YAMAHA_RXV675” whichi s a http binding item. It works perfectly in sitemap and via mqtt I don’t see why my rule doesn’t find the item.

It’s defined like this in an items file:

String YAMAHA_RXV675 "Yamaha RX-V675" { http=">[*:POST:http://192.168.10.46/YamahaRemoteControl/ctrl:MAP(yamaha_v675.map)]" }

I’m lost what to do now… Is this a bug, is there a workaround or am I doing something wrong?

Have you checked the list of items in the karaf console?

Ye it’s there. Here’s the list of items in karaf:

openhab> smarthome:items list
yamahareceiver_yamahaAV_5f9ec1b3_ed59_1900_4530_00a0de9fb104_input (Type=StringItem, State=NULL, Label=null, Category=null)
yamahareceiver_yamahaAV_5f9ec1b3_ed59_1900_4530_00a0de9fb104_power (Type=SwitchItem, State=NULL, Label=Power, Category=switch)
network_device_192_168_10_46_online (Type=SwitchItem, State=ON, Label=Online, Category=null)
yamahareceiver_yamahaAV_5f9ec1b3_ed59_1900_4530_00a0de9fb104_volume (Type=DimmerItem, State=NULL, Label=Volume, Category=SoundVolume)
yamahareceiver_yamahaAV_5f9ec1b3_ed59_1900_4530_00a0de9fb104_surroundProgram (Type=StringItem, State=NULL, Label=Surround program, Category=null)
yamahareceiver_yamahaAV_5f9ec1b3_ed59_1900_4530_00a0de9fb104_mute (Type=SwitchItem, State=NULL, Label=Mute, Category=SoundVolume)
Sonos_Livingroom_Control (Type=PlayerItem, State=UNDEF, Label=Sonos_Control_LivingRoom, Category=Player)
SONOS_LIVINGROOM (Type=StringItem, State=NULL, Label=Sonos Wohnzimmer, Category=null)
SAMSUNGTV (Type=StringItem, State=NULL, Label=Samsung TV, Category=null)
LG_COMBO (Type=StringItem, State=NULL, Label=LG VHS/DVD Copy Dock, Category=null)
SONY_ALL (Type=StringItem, State=NULL, Label=Sony All System, Category=null)
POPCORN (Type=StringItem, State=NULL, Label=Popcorn Hour, Category=null)
MED500X (Type=StringItem, State=NULL, Label=Med8er 500X 3D, Category=null)
BDP_S4200 (Type=StringItem, State=NULL, Label=Sony Bluray BDP-S4200, Category=null)
ZAPPITI_IR (Type=StringItem, State=NULL, Label=Zappiti Mini (Infrared), Category=null)
HORIZON (Type=StringItem, State=NULL, Label=Zappiti Mini (Infrared), Category=null)
YAMAHA_RXV675 (Type=StringItem, State=NULL, Label=Yamaha RX-V675, Category=null)
ITACH_SENSOR3 (Type=StringItem, State=NULL, Label=iTach Sensor 3, Category=null)
ZAPPITI (Type=StringItem, State=NULL, Label=Zappiti Mini, Category=null)
HORIZON_POWER (Type=StringItem, State=NULL, Label=Horizon Power On Sensor, Category=null)
AIRCONTROL (Type=GroupItem, Members=0, State=NULL, Label=null, Category=null)
AIRCONTROL_SWITCH (Type=StringItem, State=NULL, Label=Lüftung, Category=null)
AIRCONTROL_STATE (Type=StringItem, State=NULL, Label=Lüftung, Category=null)
AIRCONTROL_MODE (Type=StringItem, State=NULL, Label=Lüftungsmodus, Category=null)
AIRCONTROL_TEMP_OUTDOOR (Type=NumberItem, State=NULL, Label=Aussentemperatur, Category=null)
AIRCONTROL_TEMP_INDOOR (Type=NumberItem, State=NULL, Label=Innentemperatur, Category=null)

UPDATE: After Rebooting the system it recognized the item all of a sudden. The only other error was that I had to enclose the Commands in double quotes